There's more than one way to do things | |
PerlMonks |
Re^2: Best Practices for creating an OO version of an existing CPAN module?by topher (Scribe) |
on Feb 25, 2013 at 20:25 UTC ( [id://1020561]=note: print w/replies, xml ) | Need Help?? |
This biggest issue comes from the use of package variables to maintain state. I have a need for the equivalent of multiple instances, and I'd rather not have to write wrapper code to continually update the package state variables every time I call a module function. An OO interface where I could more cleanly have multiple instances, each with it's own object state, seems like the best solution.
In Section
Seekers of Perl Wisdom
|
|