Class Dispatcher
A Dispatcher
is responsible for delegating control to the controller
action as specified by the request.
- Core\Object implements Core\Chainable
- Core\Set implements Core\Accessor
- Core\Dispatcher
Package: Core\Dispatcher
Since: 3.0
Requires: PHP 5.3
Version: 1.0
Located at Dispatcher.inc.php
Methods summary
public
|
|
protected
string|array
|
#
_translateName( string $name, string $delimiter = null )
Transforms a request action string into an action name. |
public static
|
|
public
|
#
dispatch( string $controllerString, string $actionString )
Dispatches control to the given controller and action strings. Also sets the internal controller and action properties to the translated controller and action names. |
public
|
#
execute( )
Parses the initial query, propagates |
public
|
#
setArgs( array $arguments )
Overwrites arguments. This is useful to overwrite standard parameters that do not change often, such as the current language in use. Other uses are strongly discouraged. |
Methods inherited from Core\Object
__autocreateFactory()
,
__call()
,
__processParameters()
,
__toString()
,
attachMethod()
,
chain()
,
getValueForKey()
,
getValueForKeyPath()
,
getValueForUndefinedKey()
,
hash()
,
issetValueForKey()
,
setValueForKey()
,
setValueForKeyPath()
,
setValueForUndefinedKey()
,
uuid()
Constants summary
string |
FallbackParameter
Sets the name of a standard fallback controller. Defaults to |
#
'fallback'
|
string |
TargetGroupParameter
Defines the target group for dispatcher commands. Defaults to "Application\Controller". |
#
'target-group'
|
Constants inherited from Core\Object
AnyParameterType
,
AutochainParameterType
,
AutocreateParameterType
,
BooleanParameterType
,
CharParameterType
,
EnumParameterType
,
IntegerParameterType
,
RealParameterType
,
StringParameterType
,
UserParameterType
Properties summary
protected
array
|
$_v_args
Associative array of command arguments. |
|
protected
string
|
$_v_currentAction
Current action name. |
|
protected
string
|
$_v_currentController
Current controller name. |
|
protected
array
|
$_v_parameters
Parsed configuration parameters. |
Magic properties
public read-only
array
|
$args
Associative array of execution arguments. |
public read-only
string
|
$currentAction
Name of current action. |
public read-only
string
|
$currentController
Name of current controller. |
public read-only
array
|
$parameters
Associative array of parsed configuration parameters. |