Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^3: OO - best way to have protected methods

by astroboy (Chaplain)
on Aug 18, 2005 at 09:11 UTC ( [id://484708]=note: print w/replies, xml ) Need Help??


in reply to Re^2: OO - best way to have protected methods
in thread OO - best way to have protected methods

Well, you'd best benchmark it. If you're calling methods in a tight loop it might be a problem, but if you look at the code - say of Attribute::Protected - you're simply calling one other explict method and one anonymous sub for an attribute that you assign to your methods. That slight penalty is offset by the readability conferred IMHO
  • Comment on Re^3: OO - best way to have protected methods

Log In?
Username:
Password:

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

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

    No recent polls found