Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine

Re: My first attempt to design a module

by phaylon (Curate)
on Oct 04, 2010 at 20:43 UTC ( #863429=note: print w/replies, xml ) Need Help??

in reply to My first attempt to design a module

You might want to take a peek at Moose as an OO framework. It already takes care of many things you'd otherwise might end up reinventing.

Other than that, I'd include the $! variable in your error messages for open and close, since that will contain the actual error message. You might also like autodie since it'll take care of this for you. It's in core since 5.10.1.

Ordinary morality is for ordinary people. -- Aleister Crowley
  • Comment on Re: My first attempt to design a module

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (9)
As of 2016-10-25 20:56 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (330 votes). Check out past polls.