[Dbix-class] Set a resultset_class for a result_class from within a component loaded by the result_class

Ashley apv at sedition.com
Thu Mar 5 07:11:44 GMT 2009


I'm trying to do a custom component which requires an elaborate  
result set. This is a component which might be of benefit to many  
projects if I can get it together.

I am writing it with its accompanying resultset_class but I cannot  
seem to work out how to get the resultset_class loaded without  
manually putting it into the "user" schema/row/table file/code. I  
have played around with about 100 permutations of loading components  
or raw parent classes in the component class to expose things like  
_source_handle and resultset_class public and private friends, and  
things like __PACKAGE__->set_component_class("resultset_class",  
"DBICx::ResultSet::MyRS"). I can't seem to nail it down and when I  
thought I might have something with the ::DB component, I got a big  
ol'deprecation notice.

So, how do I set the resultset_class for a result_class from within a  
component which is loaded from the result_class? I'm sure I'm missing  
something.

Thanks!
-Ashley





More information about the DBIx-Class mailing list