URL name parser that uses the topic structure

package midcom

 Methods

__construct ()

get_current_object ()

Return current object pointed to by the parse URL

get_object ()

Return next object in URL path

get_objects ()

Return parsed objects

get_url ()

Return full URL that was given to the parser

get_variable (string $namespace)

Try to fetch a URL variable.

Try to decode an -- pair at the current URL position. Namespace must be a valid MidCOM Path, Key must match the RegEx [a-zA-Z0-9]* and value must not contain a "/".

On success it returns an associative array containing the key and value which hold that have been parsed. $this->argv[0] will be dropped and $this->argc will be reduced by one.

On failure it returns false.

Parameters

$namespace

stringThe namespace for which to search a variable

Returns

ArrayThe key and value pair of the URL parameter, or false on failure.

parse ($argv)

Set the URL path to be parsed

Parameters

$argv

tokenize ($url)

Parameters

$url

check_style_inheritance ($topic)

Check topic style inheritance rules for style loader
todo refactor style loader so this isn't needed

Parameters

$topic

 Properties

 

mixed $argc

 

mixed $argv

 

mixed $argv_original

 

mixed $current_object

 

mixed $objects

 

mixed $root_topic

 

mixed $url