interface RouterInterface

Component routing interface

Methods

array
preprocess( array $query)

Prepare-method for URLs This method is meant to validate and complete the URL parameters.

array
build( array $query)

Build method for URLs This method is meant to transform the query parameters into a more human readable form. It is only executed when SEF mode is switched on.

array
parse( array $segments)

Parse method for URLs This method is meant to transform the human readable URL back into query parameters. It is only executed when SEF mode is switched on.

Details

array preprocess( array $query)

Prepare-method for URLs This method is meant to validate and complete the URL parameters.

For example it can add the Itemid or set a language parameter. This method is executed on each URL, regardless of SEF mode switched on or not.

Parameters

array $query An associative array of URL arguments

Return Value

array The URL arguments to use to assemble the subsequent URL.

array build( array $query)

Build method for URLs This method is meant to transform the query parameters into a more human readable form. It is only executed when SEF mode is switched on.

Parameters

array $query &$query An array of URL arguments

Return Value

array The URL arguments to use to assemble the subsequent URL.

array parse( array $segments)

Parse method for URLs This method is meant to transform the human readable URL back into query parameters. It is only executed when SEF mode is switched on.

Parameters

array $segments &$segments The segments of the URL to parse.

Return Value

array The URL attributes to be used by the application.