1 | <?php |
||
5 | class Data |
||
6 | { |
||
7 | /** |
||
8 | * Current user instance |
||
9 | * @var \Psecio\Invoke\UserInterface |
||
10 | */ |
||
11 | private $user; |
||
12 | |||
13 | /** |
||
14 | * Current resource being accessed |
||
15 | * @var \Psecio\Invoke\Resource |
||
16 | */ |
||
17 | private $resource; |
||
18 | |||
19 | /** |
||
20 | * Current route match for the request |
||
21 | * @var \Psecio\Invoke\RouteContainer |
||
22 | */ |
||
23 | private $route; |
||
24 | |||
25 | /** |
||
26 | * Current enforcer object |
||
27 | * @var array |
||
28 | */ |
||
29 | private $enforcer; |
||
30 | |||
31 | public function __construct(UserInterface $user, $resource, $route = null) |
||
40 | |||
41 | public function __get($name) |
||
49 | |||
50 | /** |
||
51 | * Get the current user instance |
||
52 | * |
||
53 | * @return \Psecio\Invoke\InvokeUser instance |
||
54 | */ |
||
55 | public function getUser() |
||
59 | |||
60 | /** |
||
61 | * Get the current route information |
||
62 | * |
||
63 | * @return \Psecio\Invoke\RouteContainer instance |
||
64 | */ |
||
65 | public function getRoute() |
||
69 | |||
70 | /** |
||
71 | * Get the current resource instance |
||
72 | * |
||
73 | * @return \Psecio\Invoke\Resource instance |
||
74 | */ |
||
75 | public function getResource() |
||
79 | |||
80 | /** |
||
81 | * Set the current route instance |
||
82 | * |
||
83 | * @param \Psecio\Invoke\RouteContaine $route Instance |
||
84 | */ |
||
85 | public function setRoute(RouteContainer $route) |
||
89 | |||
90 | /** |
||
91 | * Set the current enforcer object |
||
92 | * |
||
93 | * @param \Psecio\Invoke\Enforcer $enforcer Enforcer object |
||
94 | */ |
||
95 | public function setEnforcer(\Psecio\Invoke\Enforcer &$enforcer) |
||
99 | |||
100 | /** |
||
101 | * Get the current enforcer object |
||
102 | * |
||
103 | * @return object Enforder object |
||
104 | */ |
||
105 | public function getEnforcer() |
||
109 | } |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..