Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: How do I report an error back to the user of my object?

by thargas (Deacon)
on Jun 05, 2012 at 12:23 UTC ( [id://974441]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    package CoolObject;
    sub new {
    ...
      my $self = { name => 'new' }, $class;
      $self->loaddata() or die 'Error loading data';
      return $self;
    
  2. or download this
    my $co = CoolObject->new();
    # or if you want to trap the error...
    ...
    if ($@) {
      # do something about the error
    }
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (5)
As of 2024-04-19 20:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found