Skip to Content
Perl by Example
book

Perl by Example

by Ellie Quigley
December 2014
Beginner
888 pages
25h 23m
English
Addison-Wesley Professional
Content preview from Perl by Example

Chapter 13. Modularize It, Package It, and Send It to the Library!

Image

Upon finishing this chapter, you should have a good understanding of how to read and create a Perl procedural style module similar to this one found at http://www.perlmonks.org.

package MyModule;   # filename is myModule.pmuse strict;use warnings;use Exporter;use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);$VERSION     = 1.00;@ISA         = qw(Exporter);@EXPORT      = ();@EXPORT_OK   = qw(func1 func2);%EXPORT_TAGS = ( DEFAULT => [qw(&func1)],                 Both    => [qw(&func1 &func2)]);sub func1  { return reverse @_  }sub func2  { return ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Beginning Perl

Beginning Perl

Curtis Ovid Poe
Perl Hacks

Perl Hacks

Chromatic, Damian Conway, Curtis Ovid Poe, Curtis (Ovid) Poe
Mastering Perl

Mastering Perl

brian d foy
Learning Perl 6

Learning Perl 6

brian d foy

Publisher Resources

ISBN: 9780133593068Purchase book