Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
go ahead... be a heretic
 
PerlMonks  

Re: How to NOT load a Catalyst Model?

by kyle (Abbot)
on Apr 02, 2009 at 20:15 UTC ( #755095=note: print w/ replies, xml ) Need Help??


in reply to How to NOT load a Catalyst Model?

It's a good idea to break it out into an external module anyway. That way you can test it more easily (in isolation, away from the rest of the application). There's Catalyst::Model::Adaptor to make this easier. From its description:

The idea is that you don't want your Catalyst model to be anything other than a line or two of glue. Using this module ensures that your Model classes are separate from your application and therefore are well-abstracted, reusable, and easily testable.

Right now there are too many modules on CPAN that are Catalyst-specific. Most of the models would be better written as a class that handles most of the functionality with just a bit of glue to make it work nicely with Catalyst. This module aims to make integrating your class with Catalyst trivial, so you won't have to do any extra work to make your model generic.


Comment on Re: How to NOT load a Catalyst Model?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://755095]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2014-04-20 09:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (485 votes), past polls