Gianni Ceccarelli > CatalystX-ComponentsFromConfig > CatalystX::ComponentsFromConfig

Download:
CatalystX-ComponentsFromConfig-1.006.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Module Version: 1.006   Source  

NAME ^

CatalystX::ComponentsFromConfig - create models / views at load time

VERSION ^

version 1.006

DESCRIPTION ^

This distribution provides 2 Catalyst plugins (CatalystX::ComponentsFromConfig::ModelPlugin and CatalystX::ComponentsFromConfig::ViewPlugin) and 2 adaptor classes (CatalystX::ComponentsFromConfig::ModelAdaptor and CatalystX::ComponentsFromConfig::ViewAdaptor).

SYNOPSYS ^

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:

  My::Class->new({some=>'param'});

AUTHORS ^

COPYRIGHT AND LICENSE ^

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.

syntax highlighting: