Class Zend_Controller_Dispatcher

Description

Implements interfaces:

  • license: New BSD License
  • copyright: Copyright (c) 2006 Zend Technologies USA Inc. (http://www.zend.com)

Located in /Controller/Dispatcher.php (line 41)


	
			
Variable Summary
 string $_directory
Method Summary
 string formatActionName (string $unformatted)
 string formatControllerName (string $unformatted)
 void setControllerDirectory (string $dir)
 boolean|Zend_Controller_Dispatcher_Token _dispatch (Zend_Controller_Dispatcher_Token $action, boolean $performDispatch)
 string _formatName (string $unformatted)
Variables
string $_directory = null (line 47)

Directory where Zend_Controller_Action files are stored.

  • access: protected
Methods
dispatch (line 132)

Dispatch to a controller/action

  • access: public

Implementation of:
Zend_Controller_Dispatcher_Interface::dispatch()
Dispatches a Zend_Controller_Dispatcher_Token object to a controller/action. If the action requests a forward to another action, a new Zend_Controller_Dispatcher_Token will be returned.
formatActionName (line 74)

Formats a string into an action name. This is used to take a raw action name, such as one that would be packaged inside a Zend_Controller_Dispatcher_Token object, and reformat into a proper method name that would be found inside a class extending Zend_Controller_Action.

  • access: public
string formatActionName (string $unformatted)
  • string $unformatted
formatControllerName (line 59)

Formats a string into a controller name. This is used to take a raw controller name, such as one that would be packaged inside a Zend_Controller_Dispatcher_Token object, and reformat it to a proper class name that a class extending Zend_Controller_Action would use.

  • access: public
string formatControllerName (string $unformatted)
  • string $unformatted
isDispatchable (line 120)

Returns TRUE if the Zend_Controller_Dispatcher_Token object can be dispatched to a controller.

This only verifies that the Zend_Controller_Action can be dispatched and does not guarantee that the action will be accepted by the Zend_Controller_Action.

  • access: public
unknown isDispatchable (Zend_Controller_Dispatcher_Token $action)

Implementation of:
Zend_Controller_Dispatcher_Interface::isDispatchable()
Returns TRUE if an action can be dispatched, or FALSE otherwise.
setControllerDirectory (line 102)

Sets the directory where the Zend_Controller_Action class files are stored.

  • access: public
void setControllerDirectory (string $dir)
  • string $dir
_dispatch (line 152)

If $performDispatch is FALSE, this method will check if a controller file exists. This still doesn't necessarily mean that it can be dispatched in the stricted sense, as file may not contain the controller class or the controller may reject the action.

If $performDispatch is TRUE, then this method will actually instantiate the controller and call its action. Calling the action is done by passing a Zend_Controller_Dispatcher_Token to the controller's constructor.

  • access: protected
boolean|Zend_Controller_Dispatcher_Token _dispatch (Zend_Controller_Dispatcher_Token $action, boolean $performDispatch)
_formatName (line 89)

Formats a string from a URI into a PHP-friendly name. Replaces words separated by "-", "_", or "." with camelCaps and removes any characters that are not alphanumeric.

  • access: protected
string _formatName (string $unformatted)
  • string $unformatted

Documentation generated on Fri, 30 Jun 2006 11:29:54 -0500 by phpDocumentor 1.3.0RC6