Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: object oriented Perl advice / constructor creation in child class

by Anonymous Monk
on Jul 10, 2018 at 12:17 UTC ( #1218239=note: print w/replies, xml ) Need Help??


in reply to object oriented Perl advice / constructor creation in child class

If you want a module C to give you access to methods of objects A, B, and D, all under one roof which seems strange to me then your object C would instantiate instances of A, B, and D as private properties, then expose methods (of C) which under-the-hood "reflected" those calls to the various objects that it is stashing. Callers would not perceive this: they would only call methods of C, not knowing exactly how they are implemented. But this seems to contradict the "DRY" principle, since in every method of C you would be "repeating yourself."
  • Comment on Re: object oriented Perl advice / constructor creation in child class

Replies are listed 'Best First'.
Re^2: object oriented Perl advice / constructor creation in child class
by Anonymous Monk on Jul 11, 2018 at 13:58 UTC

    More useless drivel from something called "sundial".

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (3)
As of 2019-07-24 03:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If you were the first to set foot on the Moon, what would be your epigram?






    Results (32 votes). Check out past polls.

    Notices?