[Catalyst-dev] Moose + Catalyst port
Matt S Trout
dbix-class at trout.me.uk
Sun Mar 16 17:34:56 GMT 2008
On Sat, Mar 15, 2008 at 01:54:27AM -0400, Guillermo Roditi wrote:
> > > COMPONENT calls $self->NEXT::COMPONENT. why? We have no superclasses.
> > > I figure this is a MI thing. Are we sticking with NEXT for the Moose
> > > port? I was thinking of moving to just using method modifiers. I have
> > > no clue what to replace this call with. I could use some help here.
> > > COMPONENT, in the case of not being able to build a new instance via
> > > new just blesses the config + args. Uhm. do we need to keep compat for
> > > this? The Moose port will always return an object on new because
> > > Moose::Object will do that for us.
> >
> > One thing you'll need to do is look for uses of this sort of stuff in
> > plugins, which is what COMPONENT is used for, AFAICT. Same goes for
> > ACCEPT_CONTEXT.
>
> After 6 hours of hacking on this I am still so fucking lost. i guess i
> just do not grok NEXT or something. I just can't explain to myself why
> a class with no superclasses would ever call NEXT.
It's so you can do
use base qw(Catalyst::Component SomethingElse::WithA::ComponentMethod);
and both classes' COMPONENT method get called.
remember NEXT::COMPONENT is equivalent to maybe::next::method from C3,
not next::method.
--
Matt S Trout Need help with your Catalyst or DBIx::Class project?
Technical Director http://www.shadowcat.co.uk/catalyst/
Shadowcat Systems Ltd. Want a managed development or deployment platform?
http://chainsawblues.vox.com/ http://www.shadowcat.co.uk/servers/
More information about the Catalyst-dev
mailing list