1 | <?php |
||
10 | class Definition |
||
11 | { |
||
12 | /** |
||
13 | * @var ClassName |
||
14 | */ |
||
15 | private $className; |
||
16 | |||
17 | /** |
||
18 | * @var LazyProperty[]|array $lazyProperties |
||
19 | */ |
||
20 | private $lazyProperties; |
||
21 | |||
22 | /** |
||
23 | * @var array |
||
24 | */ |
||
25 | private $methodReplacements; |
||
26 | |||
27 | /** |
||
28 | * @param ClassName $className |
||
29 | * @param array|LazyProperty[] $lazyProperties |
||
30 | * @param array|MethodReplacement[] $methodReplacements |
||
31 | * @throws InvalidArgumentException |
||
32 | */ |
||
33 | public function __construct(ClassName $className, array $lazyProperties = [], array $methodReplacements = []) |
||
42 | |||
43 | /** |
||
44 | * @return ClassName |
||
45 | * |
||
46 | * @api |
||
47 | */ |
||
48 | public function getClassName() |
||
52 | |||
53 | /** |
||
54 | * @param $object |
||
55 | * @return bool |
||
56 | * |
||
57 | * @api |
||
58 | */ |
||
59 | public function describeProxyFor($object) |
||
63 | |||
64 | /** |
||
65 | * @return array|LazyProperty[] |
||
66 | * |
||
67 | * @api |
||
68 | */ |
||
69 | public function getLazyProperties() |
||
73 | |||
74 | /** |
||
75 | * @return array |
||
76 | * |
||
77 | * @api |
||
78 | */ |
||
79 | public function getMethodReplacements() |
||
83 | |||
84 | /** |
||
85 | * @param array $lazyProperties |
||
86 | * @throws InvalidArgumentException |
||
87 | */ |
||
88 | private function validateLazyPropertiesDefinitions(array $lazyProperties) |
||
96 | |||
97 | /** |
||
98 | * @param array $methodReplacements |
||
99 | * @throws InvalidArgumentException |
||
100 | */ |
||
101 | private function validateMethodReplacementsDefinitions(array $methodReplacements) |
||
109 | } |
||
110 |