1 | <?php |
||
20 | class Permission extends AbstractModel implements CategorizableInterface |
||
21 | { |
||
22 | use CategorizableTrait; |
||
23 | |||
24 | /** |
||
25 | * @var string $ident |
||
26 | */ |
||
27 | private $ident; |
||
28 | |||
29 | /** |
||
30 | * @var TranslationString $name |
||
31 | */ |
||
32 | private $name; |
||
33 | |||
34 | /** |
||
35 | * Permission can be used as a string (ident). |
||
36 | * |
||
37 | * @return string |
||
38 | */ |
||
39 | public function __toString() |
||
43 | |||
44 | /** |
||
45 | * @param string $ident The permission identifier. |
||
46 | * @throws InvalidArgumentException If the ident is not a string. |
||
47 | * @return Permission Chainable |
||
48 | */ |
||
49 | public function setIdent($ident) |
||
59 | |||
60 | /** |
||
61 | * @return string |
||
62 | */ |
||
63 | public function ident() |
||
67 | |||
68 | /** |
||
69 | * @param mixed $name The permission name / label. |
||
70 | * @return Permission Chainable |
||
71 | */ |
||
72 | public function setName($name) |
||
77 | |||
78 | /** |
||
79 | * @return TranslationString |
||
80 | */ |
||
81 | public function name() |
||
85 | } |
||
86 |