[ticket/13421] Always require the interface when possible

PHPBB3-13421
This commit is contained in:
Joas Schilling 2014-11-22 02:15:06 +01:00
parent 536bdf036b
commit d78bb2865b
4 changed files with 7 additions and 7 deletions

View file

@ -28,7 +28,7 @@ abstract class migration
/** @var \phpbb\db\driver\driver_interface */ /** @var \phpbb\db\driver\driver_interface */
protected $db; protected $db;
/** @var \phpbb\db\tools */ /** @var \phpbb\db\tools_interface */
protected $db_tools; protected $db_tools;
/** @var string */ /** @var string */
@ -51,12 +51,12 @@ abstract class migration
* *
* @param \phpbb\config\config $config * @param \phpbb\config\config $config
* @param \phpbb\db\driver\driver_interface $db * @param \phpbb\db\driver\driver_interface $db
* @param \phpbb\db\tools $db_tools * @param \phpbb\db\tools_interface $db_tools
* @param string $phpbb_root_path * @param string $phpbb_root_path
* @param string $php_ext * @param string $php_ext
* @param string $table_prefix * @param string $table_prefix
*/ */
public function __construct(\phpbb\config\config $config, \phpbb\db\driver\driver_interface $db, \phpbb\db\tools $db_tools, $phpbb_root_path, $php_ext, $table_prefix) public function __construct(\phpbb\config\config $config, \phpbb\db\driver\driver_interface $db, \phpbb\db\tools_interface $db_tools, $phpbb_root_path, $php_ext, $table_prefix)
{ {
$this->config = $config; $this->config = $config;
$this->db = $db; $this->db = $db;

View file

@ -24,7 +24,7 @@ class migrator
/** @var \phpbb\db\driver\driver_interface */ /** @var \phpbb\db\driver\driver_interface */
protected $db; protected $db;
/** @var \phpbb\db\tools */ /** @var \phpbb\db\tools_interface */
protected $db_tools; protected $db_tools;
/** @var \phpbb\db\migration\helper */ /** @var \phpbb\db\migration\helper */
@ -84,7 +84,7 @@ class migrator
/** /**
* Constructor of the database migrator * Constructor of the database migrator
*/ */
public function __construct(\phpbb\config\config $config, \phpbb\db\driver\driver_interface $db, \phpbb\db\tools $db_tools, $migrations_table, $phpbb_root_path, $php_ext, $table_prefix, $tools, \phpbb\db\migration\helper $helper) public function __construct(\phpbb\config\config $config, \phpbb\db\driver\driver_interface $db, \phpbb\db\tools_interface $db_tools, $migrations_table, $phpbb_root_path, $php_ext, $table_prefix, $tools, \phpbb\db\migration\helper $helper)
{ {
$this->config = $config; $this->config = $config;
$this->db = $db; $this->db = $db;

View file

@ -85,7 +85,7 @@ class fulltext_sphinx
/** /**
* Database Tools object * Database Tools object
* @var \phpbb\db\tools * @var \phpbb\db\tools_interface
*/ */
protected $db_tools; protected $db_tools;

View file

@ -17,7 +17,7 @@ class phpbb_dbal_db_tools_test extends phpbb_database_test_case
{ {
/** @var \phpbb\db\driver\driver_interface */ /** @var \phpbb\db\driver\driver_interface */
protected $db; protected $db;
/** @var \phpbb\db\tools */ /** @var \phpbb\db\tools_interface */
protected $tools; protected $tools;
protected $table_exists; protected $table_exists;
protected $table_data; protected $table_data;