Drew Taylor wrote: > I have always operated under the assumption that within a module/object > it's OK to access members directly. Outside the module I always use > accessors/mutators. What do others think?
I dont mean to go on a rant here, but... I think its more a reflection of the limitations of perl's object oriented approach that the answer isn't intuitively obvious to the most casual observer. to put another way, there is no one way that is considered the OK/good/best way to write OO perl, because OO perl has so many tradeoffs. since a perl class must know what data type is used to store the instance data, you're first step into OO Perl already saddles you with problems. You have to write your own accessors, and direct access is always faster to execute (and less methods to write). "good" OOP is more work and runs slower. though, I haven't seen ANY language do a good OO approach such that it becomes second nature to program good OO code. so its not like its a problem particular to perl. <\DennisLeary mode> Greg _______________________________________________ Boston-pm mailing list [EMAIL PROTECTED] http://mail.pm.org/mailman/listinfo/boston-pm