| 1 | <?php |
||
| 5 | class Mixed { |
||
| 6 | /** |
||
| 7 | * Converts a value to an array containing this value unless it's an array |
||
| 8 | * |
||
| 9 | * @param mixed $argument |
||
| 10 | * @return array |
||
| 11 | */ |
||
| 12 | public static function toArray( $argument ) { |
||
| 19 | |||
| 20 | /** |
||
| 21 | * Executes a value depending on what type it is and returns the result |
||
| 22 | * Callable: call |
||
| 23 | * Instance: call method |
||
| 24 | * Class: instantiate and call method |
||
| 25 | * Other: return it |
||
| 26 | * |
||
| 27 | * @param mixed $entity |
||
| 28 | * @param array $arguments |
||
| 29 | * @param string $method |
||
| 30 | * @return mixed |
||
| 31 | */ |
||
| 32 | public static function value( $entity, $arguments = [], $method = '__invoke' ) { |
||
| 44 | } |
||
| 45 |