Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: What is Wrapper in Perl

by jZed (Prior)
on Aug 15, 2007 at 18:36 UTC ( [id://632826]=note: print w/replies, xml ) Need Help??


in reply to What is Wrapper in Perl

Usually this means that the wrapper uses the underlying module to do all of the work but provides a different interface. For example DBIx::Simple uses DBI to do all of the actual database interaction but allows you to use its own simplified methods rather than directly using DBI methods. To get a list of columns from a statement handle in DBI, you'd need to do something like:
my @columns = @{$sth->{NAME}};
whereas in DBIx::Simple, you can just do:
my @columns = $result->columns;
If you look at the code for columns() method in DBIx::Simple, you will see that it actually does the DBI $sth->{NAME} call, but saves you the trouble of typing the more complex syntax.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (7)
As of 2024-04-23 13:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found