i am trying to do something along the lines of:
sub foo : Local HelloWorld {
my ($self, $c) = @_;
$c-res-body( $c-stash-{hello} ); # was already set to 'world'
because of attribute HelloWorld
}
is this possible? any tutorials around that deal with such things?
thanks to phaylon, i got this figured out.
[ in a controller base class ]
sub _parse_Hello_attr { ActionClass = 'MyApp::Action::Hello' }
[ and elsewhere... ]
package MyApp::Action::Hello;
use base 'Catalyst::Action';
sub execute {
my $self = shift;
my ($controller, $c) = @_;