good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: Re: Class::Classless vs. Class::Prototypedby John M. Dlugosz (Monsignor) |
on Sep 12, 2003 at 16:33 UTC ( [id://291122]=note: print w/replies, xml ) | Need Help?? |
Well, I have a number of different record types and modifier flags (http://www.dlugosz.com/ZIP2/structure.html) and I want to model them as Perl objects. They will encode/decode, as well as provide functionality specific to that record type. Notice on that page I have real binary hex-dump examples, as I wrote a simple thing initially. But last I left it, I was working on a more elaborate system of populating both values and behavior based on the initial "type" when new-ing it. On a particular species, for example, a "set" method could check for contraints based on the rules of that specific situation. The implementation concept was to have "slots" that could be values or code. That's starting to sound like what these modules do. So why re-invent it? —John
In Section
Seekers of Perl Wisdom
|
|