1 | <?php namespace BuildR\Utils\Enumeration; |
||
8 | class EnumerationBase implements StringConvertibleInterface, Countable { |
||
9 | |||
10 | public $value; |
||
11 | |||
12 | private static $cache = []; |
||
13 | |||
14 | public function __construct($value) { |
||
21 | |||
22 | public function isValid($value) { |
||
25 | |||
26 | public function getValue() { |
||
29 | |||
30 | public static function toArray() { |
||
40 | |||
41 | public static function getKeys() { |
||
44 | |||
45 | public static function isValidKey($key) { |
||
52 | |||
53 | public static function __callStatic($name, $arguments) { |
||
67 | |||
68 | // ========================================== |
||
69 | // StringConvertibleInterface implementation |
||
70 | // ========================================== |
||
71 | |||
72 | /** |
||
73 | * {@inheritdoc} |
||
74 | */ |
||
75 | public function __toString() { |
||
78 | |||
79 | /** |
||
80 | * {@inheritdoc} |
||
81 | */ |
||
82 | public function toString() { |
||
85 | |||
86 | // =================================== |
||
87 | // Countable interface implementation |
||
88 | // =================================== |
||
89 | |||
90 | /** |
||
91 | * {@inheritdoc} |
||
92 | */ |
||
93 | public function count() { |
||
96 | |||
97 | } |
||
98 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.