[Catalyst] creating action classes for chained actions,
trouble with overriding ->match
John Napiorkowski
jjn1056 at yahoo.com
Tue Mar 20 20:15:48 GMT 2007
----- Original Message ----
From: John Napiorkowski <jjn1056 at yahoo.com>
To: catalyst at lists.rawmode.org
Sent: Tuesday, March 20, 2007 4:07:29 PM
Subject: [Catalyst] creating action classes for chained actions, trouble with overriding ->match
Hi,
I've been working on some action classes that are primarily used by chained actions (although they could be used otherwise) and running into some confusion about overriding the ->match method.
It seems like if you have an action chain with several actions that have action classes, the ->match method of the terminal action is the only one that gets run. For example:
Does anyone know if this is correct? Or am I just doing something wrong? Seems strange that I can hook into execute but not match but that just might be me.
Thanks!
--John
I may have answered my own question. A peer pointed me to:
http://search.cpan.org/src/MRAMBERG/Catalyst-Runtime-5.7007/lib/Catalyst/DispatchType/Chained.pm
and down in a method called 'recurse_match' it does indeed seem like match is only called against the endpoint in a chain. So I guess I'd like to find out if anyone knows the reasoning behind this. I think ideally if an action class can over ride match, this should be allowed for all types of actions. Or I am just not smart enough to know why not :)
Thanks!
John
____________________________________________________________________________________
We won't tell. Get more on shows you hate to love
(and love to hate): Yahoo! TV's Guilty Pleasures list.
http://tv.yahoo.com/collections/265
_______________________________________________
List: Catalyst at lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/
____________________________________________________________________________________
Bored stiff? Loosen up...
Download and play hundreds of games for free on Yahoo! Games.
http://games.yahoo.com/games/front
More information about the Catalyst
mailing list