MvcLite\Dispatcher
Base Dispatcher
- Author: Cory Collier <corycollier@corycollier.com>
Synopsis
- // Inherited constants from ObjectAbstract
- const MSG_ERR_IDENTIFY = 'Descendents must implement the identify method';
- // methods
- public Dispatcher init()
- public void dispatch()
- protected void handleDispatchException()
- protected string translateControllerName()
- protected string translateActionName()
- // Inherited methods from ObjectAbstract
- public final void __get()
- public final void __set()
- public final void __call()
- public void __toString()
- public string identify()
- // Inherited methods from Config
- public Config getConfig()
- // Inherited methods from Request
- public Request getRequest()
- // Inherited methods from Response
- public Response getResponse()
- // Inherited methods from Session
- public Session getSession()
- // Inherited methods from Singleton
- public static Singleton getInstance()
- // Inherited methods from Filepath
- public Request filepath()
- // Inherited methods from FilterChain
- public Request getFilterChain()
Hierarchy
Extends
Uses
Coverage
Methods | 100% | 5 / 5 |
Lines | 100% | 48 / 48 |
Constants
Name | Value |
---|---|
MSG_ERR_IDENTIFY | 'Descendents must implement the identify method' |
Members
protected
- $config
—
MvcLite\Traits\MvcLite\Config
Config instance variable. - $instance
—
MvcLite\Traits\Singleton
Static instance variable - $loader
—
\Composer\Autoload\ClassLoader
Loader instance variable. - $request
—
MvcLite\Traits\MvcLite\Request
Request instance variable. - $response
—
MvcLite\Traits\MvcLite\Response
Response instance variable. - $session
—
MvcLite\Traits\MvcLite\Session
Session instance variable.
Methods
protected
- handleDispatchException() — Handle exceptions that occur during dispatch.
- translateActionName() — Translates a raw request param for an action into an action name.
- translateControllerName() — Translates a raw request param for a controller into a class name.
public
- dispatch() — dispatch
- init() — Initialize the dispatcher.
Inherited from MvcLite\ObjectAbstract
public
- __call() — Overriding the __call magic method
- __get() — Overriding the __get magic method
- __set() — Overriding the __set magic method
- __toString() — returns a string representation of the object
- identify() — method used to identify the object instance
Inherited from MvcLite\Traits\Config
public
- getConfig() — Getter for the config.
Inherited from MvcLite\Traits\Request
public
- getRequest() — Getter for the Request instance.
Inherited from MvcLite\Traits\Response
public
- getResponse() — Getter for the response instance variable.
Inherited from MvcLite\Traits\Session
public
- getSession() — Getter for the session instance variable.
Inherited from MvcLite\Traits\Singleton
public
- getInstance() — Getter for the instance variable.
Inherited from MvcLite\Traits\Filepath
public
- filepath() — Getter for the Request instance.
Inherited from MvcLite\Traits\Loader
public
- getLoader() — Getter for the Loader instance.
- setLoader() — Setter for the Loader instance.
Inherited from MvcLite\Traits\FilterChain
public
- getFilterChain() — Getter for the Request instance.
History
-
2015-12-21T13:08:25-05:00 (commit #5617538)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Updating the response class to allow for setting/getting of content type. Updating the request to read the content type, allowing for semicolon separated values, implementing the content-type acknowledgement in the dispatcher
-
2015-12-17T11:21:34-05:00 (commit #b93b112)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Adding support for section reading from the Config object. Setting default values to the view from the configuration. Adding the autoloader to the View, and using it to check for helper classes. Updating unit tests for the Request object. Implementation of Bootstrap in the default views created by the mvc script
-
2015-12-17T00:04:48-05:00 (commit #afe5446)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Adding text as a recognized content type. This is to accomodate cli requests
-
2015-12-16T21:16:45-05:00 (commit #56c2c5b)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
First commit of the 3.2.0 release branch. Adding format changing for the response
-
2015-12-15T09:42:10-05:00 (commit #0bcf089)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
A lot of code minor code cleanup. Updating some methods to split up code a bit
-
2015-12-14T22:01:17-05:00 (commit #3ca33f8)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
General code cleanup. Also getting unit test coverage for the Dispatcher up to 100%
-
2015-12-14T07:03:35-05:00 (commit #ca452e0)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Removing the Database class, trait, and associated tests. Cleaning up some of the declarations on the filter and view helper classes
-
2015-12-12T09:52:25-05:00 (commit #bf398f5)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Updates to the controller, and dispatcher
-
2015-12-12T09:41:11-05:00 (commit #65b9adc)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Implementing the Loader trait on the dispatcher, updating unit tests to skip if no database is present
-
2015-12-04T11:19:13-05:00 (commit #0b688e9)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
Introducing mocking into the DispatcherTest::testDispatch() test
-
2015-12-04T10:17:55-05:00 (commit #4a3dc2e)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
Updating the travis-ci configuration, fixing a case-sensitivity issue with the dispatcher
-
2015-12-02T17:01:03-05:00 (commit #e7a04a5)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
More array cleanup
-
2015-12-02T16:43:15-05:00 (commit #55a67b0)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
BIG commit. Leveraging php5.4 shorthand for arrays, updating the skeleton app, Adding the Filepath trait, implementing the filepath trait, new Filters, Moved the registry to a new config class, created a new config trait, implemented new config trait, updated a TON of unit tests
-
2015-11-30T18:03:08-05:00 (commit #edb2b58)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
LOTS of code cleanup here. Fixing unit tests for those cleanups as well
-
2015-11-29T16:46:01-05:00 (commit #846ee53)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
Adding traits, implementing them on Cache, Database, Dispatcher, Error, and Request classes. Adding a TestCase class, to simplify unit test writing. Updating unit tests
-
2015-11-29T13:59:13-05:00 (commit #5ca1372)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
,
-
2015-11-27T22:46:57-05:00 (commit #3067c88)
Author: Cory Collier (ccollier@redhat.com) / Commiter: Cory Collier (ccollier@redhat.com)
Provisional commit - Not done moving things around to be namespace compliant. This commit is completely not functional
-
2015-11-11T08:14:50-05:00 (commit #ad28461)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
More moving things around
-
2015-11-11T08:07:21-05:00 (commit #3838504)
Author: Cory Collier (corycollier@corycollier.com) / Commiter: Cory Collier (corycollier@corycollier.com)
Re-introducing the library components as first class items