| 1 | <?php |
||
| 21 | final class BindingState |
||
| 22 | { |
||
| 23 | /** |
||
| 24 | * State: The binding is enabled. |
||
| 25 | */ |
||
| 26 | const ENABLED = 1; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * State: The binding is disabled. |
||
| 30 | */ |
||
| 31 | const DISABLED = 2; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * State: The binding's type does not exist. |
||
| 35 | */ |
||
| 36 | const TYPE_NOT_FOUND = 3; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * State: The binding's type does not exist. |
||
| 40 | */ |
||
| 41 | const TYPE_NOT_ENABLED = 4; |
||
| 42 | |||
| 43 | /** |
||
| 44 | * State: The binding does not match the constraints of the binding type. |
||
| 45 | */ |
||
| 46 | const INVALID = 5; |
||
| 47 | |||
| 48 | /** |
||
| 49 | * Returns all binding states. |
||
| 50 | * |
||
| 51 | * @return int[] The binding states. |
||
| 52 | */ |
||
| 53 | public static function all() |
||
| 54 | { |
||
| 55 | return array( |
||
| 56 | self::ENABLED, |
||
| 57 | self::DISABLED, |
||
| 58 | self::TYPE_NOT_FOUND, |
||
| 59 | self::TYPE_NOT_ENABLED, |
||
| 60 | self::INVALID, |
||
| 61 | ); |
||
| 62 | } |
||
| 63 | |||
| 64 | /** |
||
| 65 | * Must not be instantiated. |
||
| 66 | */ |
||
| 67 | private function __construct() |
||
| 70 | } |
||
| 71 |