Some people prefer to construct their objects using blessed array references. They feel it makes the object a little more opaque - unlike hash keys there is nothing in an array to indicate which variable has which meaning, thus making it harder to bypass accessor methods to get at data.Is this really a reason that people use blessed arrayrefs? I always thought that it was for speed. Every object that I've ever seen structured this way got at the entries of the arrays by using named constants as indices, which would remove any “benefit” of opacity.
In reply to Re^2: Trying to understand Perl Objects
by JadeNB
in thread Trying to understand Perl Objects
by tamaguchi
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |