General information
Category:
Object Oriented Programming
David-
>Even if you are using hook patterns, you should still issue DODEFAULT(). Just because there isn't code in the methods today doesn't mean there won't be code there tomorrow. DODEFAULT in this case is very nearly a "zero cost" item to empty class methods. It's a "huge cost" to go back and retrofit them in if you ever put code in the class methods.
But, you have to know where to put the DODEFAULT(), which means you have to walk up the inheritance tree, which (IMO) breaks encapsulation. You wouldn't agree that it is better to clearly delineate which class or object in the hierarchy *owns* the method?
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only