in reply to Re: Generally accepted style in Perl objects
in thread Generally accepted style in Perl objects

You can always use AUTOLOAD to generate accessor methods on the fly: grab the name of the method and create (through eval) a method with that name that accesses the field in the object. If one day you want to change the implementation and write the method it will be found and AUTOLOAD won't be called anymore. CGI.pm uses this method, you should have a look at its code.

  • Comment on Re: Re: Generally accepted style in Perl objects