1 | <?php |
||
13 | class DebugDBALCommand extends Command |
||
14 | { |
||
15 | private $connection; |
||
16 | |||
17 | 3 | public function __construct(Loader $loader) |
|
23 | |||
24 | /** |
||
25 | * {@inheritdoc} |
||
26 | */ |
||
27 | 3 | protected function configure() |
|
34 | |||
35 | /** |
||
36 | * {@inheritdoc} |
||
37 | */ |
||
38 | protected function execute(InputInterface $input, OutputInterface $output) |
||
48 | } |
||
49 |
In PHP it is possible to write to properties without declaring them. For example, the following is perfectly valid PHP code:
Generally, it is a good practice to explictly declare properties to avoid accidental typos and provide IDE auto-completion: