Excerpts from Dave Cross's message of 2016-09-16 17:08:14 +0100:
> 
> In the documentation of DBIx::Class::Schema::Loader::Base there is a  
> reference to adding "schema components"[1] to the generated classes.  
> But I can't find any documentation on how you might write such a  
> component - or any clearly-labelled examples of a schema component.
> 
> I think I have an example of something that I'd like to write as a  
> schema component. Please either tell me that I'm wrong, or gently  
> nudge me in the right direction.

I don't know if it is the right direction, but you could simple use
inheritance in this case. Creating a subclass of DBIx::Class::Schema
with your 'get_schema' method or simple overriding ->connection to search
for a sensible environment if not given explicit arguments.


-- 
Marco Arthur @ (M)arco Creatives

_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/dbix-class@lists.scsys.co.uk

Reply via email to