Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Catalyst begin/end methods

by Your Mother (Archbishop)
on Feb 12, 2015 at 00:19 UTC ( [id://1116415]=note: print w/replies, xml ) Need Help??


in reply to Catalyst begin/end methods

http://dev.catalystframework.org/old-wiki/wiki/FlowChart/—try that. It’s old but I believe it’s still accurate. I think your understanding of begin is closer to what auto is. You get one begin and one end unless you specifically code around it. The resolution would also be easy to test in any specific cases, I think, by looking at the debug output of the test server. FWIW, I can’t remember ever needing begin. It is probably an indication of design mistake that could be better handled with an attribute attached to the class.

Replies are listed 'Best First'.
Re^2: Catalyst begin/end methods
by Anonymous Monk on Feb 12, 2015 at 01:04 UTC

      thank you!

      I have ended up moving everything to auto, begin ( I was checking user permission to enter controller ) is better there anyhow - just return 0 to break flow,

      end ( preparing things for templates specific to that controller ) did not have to be in end, it was just a matter of taste I guess, and no logical reason to do it there.

      After reading the chart: my expectation was off, only the most specific match for begin and end is run. Auto does what I need here.

      Thank you for the information, I did not find the part on begin/end ( or overlooked it ) in the docs for some reason.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1116415]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (3)
As of 2024-04-19 21:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found