Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

(dws)Re: Re: simple OO constructor

by dws (Chancellor)
on Sep 23, 2001 at 22:07 UTC ( #114190=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
      sub new {
          my $proto = shift;
          my $self = bless { @_ }, ref($proto) || $proto;
    ...
          my $self = shift;
          ... initialization for the base class ...
      }
    
  2. or download this
      sub initialize {
        my $self = shift;
        # First initialize our inherited aspects
        $self->SUPER::initialize();
        ... initialization specific to the subclass ...
      }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://114190]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2014-11-21 02:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (104 votes), past polls