CatalystX::ComponentsFromConfig - create models / views at load time
version 1.002
This distribution provides 2 Catalyst plugins (CatalystX::ComponentsFromConfig::ModelPlugin and CatalystX::ComponentsFromConfig::ViewPlugin) and 2 adaptor classes (CatalystX::ComponentsFromConfig::ModelAdaptor and CatalystX::ComponentsFromConfig::ViewAdaptor).
In your application:
use Catalyst qw( ConfigLoader +CatalystX::ComponentsFromConfig::ModelPlugin );
In your configuration:
<Model::MyClass> class My::Class <args> some param </args> </Model::MyClass>
Now, $c->model('MyClass') will contain an object built just like:
$c->model('MyClass')
My::Class->new({some=>'param'});
Tomas Doran (t0m) <bobtfish@bobtfish.net>
Gianni Ceccarelli <gianni.ceccarelli@net-a-porter.com>
This software is copyright (c) 2012 by Net-a-porter.com.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install CatalystX::ComponentsFromConfig, copy and paste the appropriate command in to your terminal.
cpanm
cpanm CatalystX::ComponentsFromConfig
CPAN shell
perl -MCPAN -e shell install CatalystX::ComponentsFromConfig
For more information on module installation, please visit the detailed CPAN module installation guide.