1 | <?php |
||
15 | class DynamicStub extends Stub |
||
16 | { |
||
17 | /** |
||
18 | * Construct the stub with the specified details |
||
19 | * |
||
20 | * @param \Phar $phar |
||
21 | * @param string $appName |
||
22 | * @param string $appVersion |
||
23 | * @param string $configFileName |
||
24 | */ |
||
25 | public function __construct(\Phar $phar, $appName, $appVersion, $configFileName) |
||
30 | |||
31 | |||
32 | /** |
||
33 | * Writes the initialization code for a dynamic build |
||
34 | * |
||
35 | * @param \Zicht\Tool\Script\Buffer $buffer |
||
36 | * @return void |
||
37 | */ |
||
38 | protected function compileInitialization(Buffer $buffer) |
||
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: