1 | <?php |
||
5 | class Arr |
||
6 | { |
||
7 | /** |
||
8 | * @param mixed $input |
||
9 | * @param mixed $key |
||
10 | * @param string|null $default |
||
11 | * |
||
12 | * @return mixed |
||
13 | */ |
||
14 | 2 | public static function get($input, $key, $default = null) |
|
22 | |||
23 | /** |
||
24 | * Unwraps a single item array into the item. If the array contains more than one item, it will be returned as-is. |
||
25 | * A default value can be provided, and will be used when an empty array is given. |
||
26 | * |
||
27 | * @param array $input |
||
28 | * @param mixed|null $default |
||
29 | * |
||
30 | * @return mixed |
||
31 | */ |
||
32 | 3 | public static function unwrap(array $input, $default = null) |
|
40 | } |
||
41 |