Questions of OOP in Perl

2003-08-14 Thread Pablo Fischer
Hi! I have some questions about OOP in Perl. 1. In my class I have lot of methods, but some of them just parse a file or pass a string to a different format (like in C, Im thinking that they are private), In perl, whats the better way to call a private method: $state = $this->city2state("Arg1"

Re: Questions of OOP in Perl

2003-08-14 Thread R. Joseph Newton
Pablo Fischer wrote: > Thanks! > > After sending my question I found in a website the topic of 'private' methods, > and shows code like this: > > my $method_name = sub { > my $this = shift; > > _blablabla_ > }; > > And to access it : > > $this->$method_name("Arg1"); > > Now, this it really

Re: Questions of OOP in Perl

2003-08-14 Thread Tassilo von Parseval
On Fri, Aug 08, 2003 at 12:05:47AM + Pablo Fischer wrote: > I have some questions about OOP in Perl. > > 1. In my class I have lot of methods, but some of them just parse a file or > pass a string to a different format (like in C, Im thinking that they are > private), In perl, whats the bet

Re: Questions of OOP in Perl

2003-08-14 Thread James Edward Gray II
On Wednesday, August 13, 2003, at 12:34 AM, R. Joseph Newton wrote: Pablo Fischer wrote: Thanks! After sending my question I found in a website the topic of 'private' methods, and shows code like this: my $method_name = sub { my $this = shift; _blablabla_ }; And to access it : $this-

Re: Questions of OOP in Perl

2003-08-09 Thread Pablo Fischer
Thanks! After sending my question I found in a website the topic of 'private' methods, and shows code like this: my $method_name = sub { my $this = shift; _blablabla_ }; And to access it : $this->$method_name("Arg1"); Now, this it really works for 'private' methods? Thanks! -- Pa