1 | <?php |
||
8 | class Config { |
||
9 | private $properties = []; |
||
10 | private $pseudo = []; |
||
11 | private $functionSet; |
||
12 | private $headers; |
||
13 | private $formatter; |
||
14 | private $baseDir; |
||
15 | |||
16 | public function __construct(Functionset $functionSet, Hook\ElementData $elementData, Hook\Formatter $formatter, &$headers, &$baseDir) { |
||
23 | |||
24 | public function getFormatter() { |
||
27 | |||
28 | public function &getHeaders() { |
||
31 | |||
32 | public function &getBaseDir() { |
||
35 | |||
36 | public function registerFormatter($formatter) { |
||
39 | |||
40 | public function getFunctionSet() { |
||
43 | |||
44 | public function getElementData() { |
||
47 | |||
48 | public function registerProperty($name, Property $property) { |
||
51 | |||
52 | public function registerPseudo(Pseudo $pseudo) { |
||
55 | |||
56 | public function loadProperties(Hook\PropertyHook $hook) { |
||
59 | |||
60 | public function createPseudoMatcher($pseudo) { |
||
65 | } |
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: