Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Re: OO design: abstract class or can()?

by adrianh (Chancellor)
on Mar 23, 2007 at 13:20 UTC ( #606225=note: print w/replies, xml ) Need Help??

in reply to OO design: abstract class or can()?

Still leaning toward the first way, but I'm curious which of these sounds better to other OO coders. Does the can() approach sound evil?

Not evil, but I'd still prefer the null method option myself. Removes a conditional (which makes the code simpler in my eyes), and gives an explicit sub in the base module to document.

  • Comment on Re: OO design: abstract class or can()?

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (6)
As of 2016-10-24 12:46 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (305 votes). Check out past polls.