NAME
Mango::Catalyst::Controller - Base controller for Catalyst controllers in Mango
SYNOPSIS
package MyApp::Controller::Foo;
use base 'Mango::Catalyst::Controller';
DESCRIPTION
Mango::Catalyst::Controller is the base controller class used by all Catalyst controllers in Mango. It inherits the Form and REST controllers and provides some generic methods used by all Mango controllers.
CONFIGURATION
The following configuration options are used directly by this controller:
- resource_name
-
If specified, this name will be sent to
register_as_resource
when the component is loaded.
METHODS
current_page
Returns the current page number from params or 1 if no page is specified.
enable_feeds
Generates links to atom/rss feeds for the current action uri and adds them to the stash, where the default wrapper adds them to the <head> section as alternate content.
enable_atom_feed
Generates a link to an atom feed for the current action uri and adds it to the stash, where the default wrapper adds it to the <head> section as alternate content.
This method is automatically called for any action that has the Feed('Atom') attribute applied to it.
enable_rss_feed
Generates a link to an rss feed for the current action uri and adds it to the stash, where the default wrapper adds it to the <head> section as alternate content.
This method is automatically called for any action that has the Feed('RSS') attribute applied to it.
entries_per_page
Returns the number of entries par page to be displayed from params or 10 if no param is specified.
register_as_resource
Registers the current class name as a resource associated with the specified name.
SEE ALSO
Mango::Catalyst::Controller::Form, Mango::Catalyst::Controller::REST
AUTHOR
Christopher H. Laco
CPAN ID: CLACO
claco@chrislaco.com
http://today.icantfocus.com/blog/