Mango::Catalyst::Model::Provider - Catalyst model for Mango::Provider classes
package MyApp::Model::Provider; use base 'Mango::Catalyst::Model::Provider';
Mango::Catalyst::Model::Provider provides glue between Mango::Providers and Catalyst models
The following configuration options are used directly by this model:
See "provider_class" for more information.
All other configuration options are passed directly into "setup" in Mango::Provider for use by the providers themselves.
Creates an instance of the specified provider class, configures it and returns the new model.
Forwards all method calls to the underlying provider instance.
my $it = $model->search; ## same as this, but don't do that my $it = $model->provider->search;
Gets/sets the provider class to be used by the current model.
$model->provider_class('Mango::Provider::Carts'); print ref $model->provider; # Mango::Provider::Carts
Gets/sets the provider instance to used by the current model.
my $provider = $model->provider;
If the provider class is specified and no provider instance exists, one will be created automatically using the available configuration.
Mango::Provider, Mango::Provider::DBIC
Christopher H. Laco CPAN ID: CLACO claco@chrislaco.com http://today.icantfocus.com/blog/
To install Mango, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mango
CPAN shell
perl -MCPAN -e shell install Mango
For more information on module installation, please visit the detailed CPAN module installation guide.