CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
Search Posts SEARCH
Who's Online WHO'S
Log in LOG

Home: Perl Programming Help: Beginner: Re: [ChopperCharles] private and protected methods: Edit Log


Mar 30, 2012, 5:50 PM

Views: 18871
Re: [ChopperCharles] private and protected methods

Anytime we need access to the object, we make sure to call the method with $self-> this way Perl will pass the first arg for us. This is because $self was blessed. If you do use Data::Dumper; then run print Dumper($self) you will see how the hash is blessed.


Now we have access to any of the object vars.

The $self->run( ) is the same as run($self, @_); (try not to do this)

(This post was edited by budman on Mar 30, 2012, 5:52 PM)

Edit Log:
Post edited by budman (User) on Mar 30, 2012, 5:52 PM

Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives