[Dbix-class] adding methods to result class

Tobias Kremer t at funkreich.de
Thu Jan 4 14:25:23 GMT 2007


Zitat von Daniel McBrearty <danielmcbrearty at gmail.com>:
> I want to add a new find method to one of my result classes ...
> now what can I call 'find' on in this class? How can I get at the resultset?

I suppose the correct way is to use the ResultSetManager component of
DBIx::Class and tag your method as a ResultSet. You can then call this method
on your ResultSet object. The POD has an example in thje Synopsis:

http://search.cpan.org/dist/DBIx-Class/lib/DBIx/Class/ResultSetManager.pm

HTH,
--Tobias



More information about the Dbix-class mailing list