Pickles::WebApp - Pickles WebApp base class.
package MyApp; use strict; use warnings; use parent 'Pickles::WebApp'; 1; __END__
MyApp.psgi
use strict; use MyApp; use Plack::Builder; my $app = MyApp->new->handler; builder { $app; };
returns a new WebApp object.
returns a PSGI application sub-ref.
returns a application name.
returns a config object. if you'd like to use custom config object, override this method.
returns a dispatcher object. if you'd like to use custom dispatcher object, override this method.
returns a routes file which is used by dispatcher. the default value is $config->path_to('etc/routes.pl').
returns a container object if you'd like to use custom container object, override this method.
returns a profile file which is used by container. the default value is $config->path_to('etc/container.pl').
The following class variables specify component classes. Omit the $self->appname prefix from the class name.
# MyApp::Config MyApp->config_class('Config'); # MyApp::Config::JSON MyApp->config_class('Config::JSON');
if you want to use fully qualified class name, use plus sign prefix.
# Foo::Config MyApp->config_class('+Foo::Config');
default value is Context
Context
default value is Config
Config
default value is Dispatcher
Dispatcher
default value is Container
Container
Tomohiro Ikebe <ikebe {at} livedoor.jp>
Pickles::Context
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Pickles, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Pickles
CPAN shell
perl -MCPAN -e shell install Pickles
For more information on module installation, please visit the detailed CPAN module installation guide.