Expands URI templates. Userland implementation of PECL uri_template.

CloneableInstantiable
Methods
public expand( $template, array $variables)
Properties
private static $delims
 


  • var array Delimiters
private static $delimsPct
 


  • var array Percent encoded delimiters
private static $operatorHash
 


  • var array Hash for quick operator lookups
private $template
 


  • var string URI template
private $variables
 


  • var array Variables to use in the template expansion
Methods
private decodeReserved( $string)
 
Removes percent encoding on reserved characters (used with + and # modifiers).

  • return string
private expandMatch(array $matches)
 
Process an expansion

  • return string Returns the replacement string
private isAssoc(array $array)
 
Determines if an array is associative.

This makes the assumption that input arrays are sequences or hashes.
This assumption is a tradeoff for accuracy in favor of speed, but it
should work in almost every case where input is supplied for a URI
template.

  • return bool
private parseExpression( $expression)
 
Parse an expression into parts

  • return array Returns an associative array of parts
Properties
private static $delims
 


  • var array Delimiters
private static $delimsPct
 


  • var array Percent encoded delimiters
private static $operatorHash
 


  • var array Hash for quick operator lookups
© 2020 Bruce Wells
Search Namespaces \ Classes
ConfigurationNumbers (0-9.) only