1 | <?php |
||
8 | class TenantUser |
||
9 | { |
||
10 | const ROLE_TENANT_MANAGER = 'ROLE_TENANT_MANAGER'; |
||
11 | const ROLE_TENANT_CUSTOMER = 'ROLE_TENANT_CUSTOMER'; |
||
12 | |||
13 | /** |
||
14 | * @var Tenant $tenant |
||
15 | */ |
||
16 | protected $tenant; |
||
17 | |||
18 | /** |
||
19 | * @var User $user |
||
20 | */ |
||
21 | protected $user; |
||
22 | |||
23 | /** |
||
24 | * @var array $roles |
||
25 | */ |
||
26 | protected $roles; |
||
27 | |||
28 | public function __construct() |
||
32 | |||
33 | /** |
||
34 | * @param array $roles |
||
35 | * |
||
36 | * @return $this |
||
37 | */ |
||
38 | public function setRoles($roles) |
||
44 | |||
45 | /** |
||
46 | * @return array |
||
47 | */ |
||
48 | public function getRoles() |
||
52 | |||
53 | /** |
||
54 | * Available role constants: |
||
55 | * - TenantUser::ROLE_TENANT_MANAGER |
||
56 | * - TenantUser::ROLE_TENANT_CUSTOMER |
||
57 | * |
||
58 | * @param string $role |
||
59 | * @return $this |
||
60 | */ |
||
61 | public function addRole($role) |
||
71 | |||
72 | /** |
||
73 | * @param string $role |
||
74 | * |
||
75 | * @return $this |
||
76 | */ |
||
77 | public function removeRole($role) |
||
86 | |||
87 | /** |
||
88 | * @param string $role |
||
89 | * |
||
90 | * @return boolean |
||
91 | */ |
||
92 | public function hasRole($role) |
||
100 | |||
101 | /** |
||
102 | * @param \Tahoe\Bundle\MultiTenancyBundle\Model\MultiTenantUserInterface $user |
||
103 | * |
||
104 | * @return $this |
||
105 | */ |
||
106 | public function setUser($user) |
||
112 | |||
113 | /** |
||
114 | * @return \Tahoe\Bundle\MultiTenancyBundle\Model\MultiTenantUserInterface |
||
115 | */ |
||
116 | public function getUser() |
||
120 | |||
121 | /** |
||
122 | * @param \Tahoe\Bundle\MultiTenancyBundle\Entity\Tenant $tenant |
||
123 | * |
||
124 | * @return $this |
||
125 | */ |
||
126 | public function setTenant($tenant) |
||
132 | |||
133 | /** |
||
134 | * @return \Tahoe\Bundle\MultiTenancyBundle\Entity\Tenant |
||
135 | */ |
||
136 | public function getTenant() |
||
140 | } |
||
141 |
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..