ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
FastRoute\RouteParser Interface Reference
+ Inheritance diagram for FastRoute\RouteParser:
+ Collaboration diagram for FastRoute\RouteParser:

Data Structures

class  StdTest
 

Public Member Functions

 parse ($route)
 Parses a route string into multiple route data arrays. More...
 

Detailed Description

Definition at line 5 of file RouteParser.php.

Member Function Documentation

◆ parse()

FastRoute\RouteParser::parse (   $route)

Parses a route string into multiple route data arrays.

The expected output is defined using an example:

For the route string "/fixedRoutePart/{varName}[/moreFixed/{varName2:\d+}]", if {varName} is interpreted as a placeholder and [...] is interpreted as an optional route part, the expected result is:

[ // first route: without optional part [ "/fixedRoutePart/", ["varName", "[^/]+"], ], // second route: with optional part [ "/fixedRoutePart/", ["varName", "[^/]+"], "/moreFixed/", ["varName2", [0-9]+"], ], ]

Here one route string was converted into two route data arrays.

Parameters
string$routeRoute string to parse
Returns
mixed[][] Array of route data arrays

Implemented in FastRoute\RouteParser\Std.


The documentation for this interface was generated from the following file: