| Conditions | 5 |
| Paths | 5 |
| Total Lines | 24 |
| Code Lines | 16 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 37 | private static function exploreAtPath(array &$arr, $path, callable $callback, array &$prosArr = null) |
||
| 38 | { |
||
| 39 | if ($prosArr === null) { |
||
| 40 | $prosArr = &$arr; |
||
| 41 | if (is_string($path) && $path == '') { |
||
| 42 | $callback($prosArr); |
||
| 43 | return; |
||
| 44 | } |
||
| 45 | } |
||
| 46 | |||
| 47 | $explodedPath = explode(self::$pathSeparator, $path); |
||
| 48 | $nextPath = array_shift($explodedPath); |
||
| 49 | |||
| 50 | if (count($explodedPath) > 0) { |
||
| 51 | self::exploreAtPath( |
||
| 52 | $arr, |
||
| 53 | implode(self::$pathSeparator, $explodedPath), |
||
| 54 | $callback, |
||
| 55 | $prosArr[$nextPath] |
||
| 56 | ); |
||
| 57 | } else { |
||
| 58 | $callback($prosArr[$nextPath]); |
||
| 59 | } |
||
| 60 | } |
||
| 61 | |||
| 85 |