Property | Type | Description | |
---|---|---|---|
$_extensions | array | Route extensions | |
$_named | The hash map of named routes that are in this collection. | ||
$_paths | array | Routes indexed by path prefix. | |
$_routeTable | array | The routes connected to this collection. | |
$_routes | The routes connected to this collection. |
Method | Description | |
---|---|---|
add ( |
Add a route to the collection. | |
extensions ( null | string | array $extensions = null, boolean $merge = true ) : array | Get/set the extensions that the route collection could handle. | |
match ( array $url, array $context ) : string | false | Reverse route or match a $url array with the defined routes. | |
named ( ) : |
Get the connected named routes. | |
parse ( string $url, string $method = '' ) : array | Takes the URL string and iterates the routes until one is able to parse the route. | |
routes ( ) : |
Get all the connected routes as a flat list. |
Method | Description | |
---|---|---|
_getNames ( array $url ) : array | Get the set of names from the $url. Accepts both older style array urls, and newer style urls containing '_name' |
public extensions ( null | string | array $extensions = null, boolean $merge = true ) : array | ||
$extensions | null | string | array | Either the list of extensions to set, or null to get. |
$merge | boolean | Whether to merge with or override existing extensions. Defaults to `true`. |
return | array | The valid extensions. |
public named ( ) : |
||
return |
public routes ( ) : |
||
return |
protected Route[],Cake\Routing\Route $_named | ||
return |
protected array $_routeTable | ||
return | array |