| 1 | <?php |
||
| 10 | class CachedRouteDetector extends RouteDetector |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * Array of cached routes. |
||
| 14 | * |
||
| 15 | * @var array |
||
| 16 | */ |
||
| 17 | private $cachedRoutes = array(); |
||
| 18 | |||
| 19 | /** |
||
| 20 | * {@inheritdoc} |
||
| 21 | */ |
||
| 22 | 12 | public function detect($className) |
|
| 31 | |||
| 32 | /** |
||
| 33 | * {@inheritdoc} |
||
| 34 | */ |
||
| 35 | 8 | public function addRoute($expression, $poolName) |
|
| 44 | |||
| 45 | /** |
||
| 46 | * {@inheritdoc} |
||
| 47 | */ |
||
| 48 | 12 | public function setDefault($route) |
|
| 56 | |||
| 57 | /** |
||
| 58 | * Clear route cache. |
||
| 59 | */ |
||
| 60 | 11 | private function clearCache() |
|
| 64 | } |
||
| 65 |
Our type inference engine in quite powerful, but sometimes the code does not provide enough clues to go by. In these cases we request you to add a
@returnannotation as described here.