Class UriTemplate
Expands URI templates using an array of variables
- Guzzle\Parser\UriTemplate\UriTemplate implements Guzzle\Parser\UriTemplate\UriTemplateInterface
Namespace: Guzzle\Parser\UriTemplate
Link: http://tools.ietf.org/html/draft-gregorio-uritemplate-08
Located at Guzzle/Parser/UriTemplate/UriTemplate.php
Link: http://tools.ietf.org/html/draft-gregorio-uritemplate-08
Located at Guzzle/Parser/UriTemplate/UriTemplate.php
Methods summary
-
publicexpand ( string $template, array $variables )Expand the URI template using the supplied variables
-
publicsetRegex ( string $regexPattern )Set the regex patten used to expand URI templates
Methods detail
Expand the URI template using the supplied variables
Parameters
- $template
string
$template URI Template to expand- $variables
array
$variables Variables to use with the expansion
Returns
stringReturns the expanded template
Implementation of
Set the regex patten used to expand URI templates
Parameters
- $regexPattern
string
$regexPattern
Magic methods summary
Constants summary
string |
DEFAULT_PATTERN |
'/\{([^\}]+)\}/' |