AbstractRoutePart
abstract class AbstractRoutePart implements RoutePartInterface (View source)
abstract Route Part
Properties
protected string | $name | Name of the Route Part |
|
protected mixed | $value | Value of the Route Part after decoding. |
|
protected mixed | $defaultValue | Default value of the Route Part. |
|
protected bool | $isOptional | Specifies whether this Route Part is optional. Which means it's put in parentheses in the routes URI pattern. |
|
protected bool | $lowerCase | Specifies whether this Route Part should be converted to lower case when resolved. |
|
protected array | $options | Contains options for this Route Part. |
Methods
Sets name of the Route Part.
Returns name of the Route Part.
Returns true if a value is set for this Route Part, otherwise false.
Returns value of the Route Part. Before match() is called this returns NULL.
Returns true if a default value is set for this Route Part, otherwise false.
Sets default value of the Route Part.
Gets default value of the Route Part.
Specifies whether this Route part is optional.
Getter for $this->isOptional.
Specifies whether this Route part should be converted to lower case when resolved.
Getter for $this->lowerCase.
Defines options for this Route Part.
No description
Details
void
setName(string $partName)
Sets name of the Route Part.
string
getName()
Returns name of the Route Part.
bool
hasValue()
Returns true if a value is set for this Route Part, otherwise false.
mixed
getValue()
Returns value of the Route Part. Before match() is called this returns NULL.
bool
hasDefaultValue()
Returns true if a default value is set for this Route Part, otherwise false.
void
setDefaultValue(mixed $defaultValue)
Sets default value of the Route Part.
mixed
getDefaultValue()
Gets default value of the Route Part.
void
setOptional(bool $isOptional)
Specifies whether this Route part is optional.
bool
isOptional()
Getter for $this->isOptional.
void
setLowerCase(bool $lowerCase)
Specifies whether this Route part should be converted to lower case when resolved.
bool
isLowerCase()
Getter for $this->lowerCase.
void
setOptions(array $options)
Defines options for this Route Part.
Options can be used to enrich a route part with parameters or settings like case sensivity.
array
getOptions()
No description