|
NAMEGantry::State::Default - Default state handler for GantrySYNOPSISThis module implements the default handler to control the execution context within GantryXs handler() method.DESCRIPTIONWhen a request comes into Gantry a preXdetermined set of steps are executed. These preXdetermined steps can be termed "states", and the process can be called a "state machine". There are many ways to implement a "state machine", so this document will not get into the semantics of the term.What this module does, is take Gantry's default handling of a request, and places it into a loadable module. With these "states" now in a loadable module, you can change the execution order to suit your applications needs. Why is this desirable? LetXs say you have an application the loads some plugins, those plugins must do a relocation for proper initialization and this relocation must be done before the controllers can execute properly. Or you want "hook" processing, using per and post "hook" plugins. With the default handler, this is not possible, with a loadable "state machine" this is now quite easy to do. This module also moves the methods relocate() and relocate_permanently() from Gantry.pm into this module. CONFIGURATIONTo load a differant state machine you need to do the following:use MyApp qw{ XStateMachine=Machine };
METHODS
sub state_run { my ($self, $r_or_cgi, $plugin_callbacks) = @_; # your code goes here }
SEE ALSOGantryAUTHORKevin L. Esteb <kesteb@wsipc.org>COPYRIGHT AND LICENSECopyright (C) 2008 Kevin L. EstebThis library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available. POD ERRORSHey! The above document had some coding errors, which are explained below:
Visit the GSP FreeBSD Man Page Interface. |