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