2 Generated by perlmodlib.PL -- DO NOT EDIT!
6 perlmodlib - constructing new Perl modules and finding existing ones
8 =head1 THE PERL MODULE LIBRARY
10 Many modules are included in the Perl distribution. These are described
11 below, and all end in F<.pm>. You may discover compiled library
12 files (usually ending in F<.so>) or small pieces of modules to be
13 autoloaded (ending in F<.al>); these were automatically generated
14 by the installation process. You may also discover files in the
15 library directory that end in either F<.pl> or F<.ph>. These are
16 old libraries supplied so that old programs that use them still
17 run. The F<.pl> files will all eventually be converted into standard
18 modules, and the F<.ph> files made by B<h2ph> will probably end up
19 as extension modules made by B<h2xs>. (Some F<.ph> values may
20 already be available through the POSIX, Errno, or Fcntl modules.)
21 The B<pl2pm> file in the distribution may help in your conversion,
22 but it's just a mechanical process and therefore far from bulletproof.
24 =head2 Pragmatic Modules
26 They work somewhat like compiler directives (pragmata) in that they
27 tend to affect the compilation of your program, and thus will usually
28 work well only when used within a C<use>, or C<no>. Most of these
29 are lexically scoped, so an inner BLOCK may countermand them
36 which lasts until the end of that BLOCK.
38 Some pragmas are lexically scoped--typically those that affect the
39 C<$^H> hints variable. Others affect the current package instead,
40 like C<use vars> and C<use subs>, which allow you to predeclare a
41 variables or subroutines within a particular I<file> rather than
42 just a block. Such declarations are effective for the entire file
43 for which they were declared. You cannot rescind them with C<no
46 The following pragmas are defined (and have their own documentation).
52 Select assertions in blocks of code
54 =item assertions::activate
60 Get/set subroutine or variable attributes
64 Set/get attributes of a subroutine (deprecated)
68 Postpone load of modules until a function is used
72 Establish IS-A relationship with base class at compile time
76 Transparent BigInteger support for Perl
80 Transparent BigNumber support for Perl
84 Transparent BigNumber/BigRational support for Perl
88 Use MakeMaker's uninstalled version of a package
92 Force byte semantics rather than character semantics
96 Define character names for C<\N{named}> string literal escapes
104 Produce verbose warning diagnostics
108 Allows you to write your script in non-ascii or non-utf8
112 Compile-time class fields
116 Control the filetest permission operators
120 C<use> a Perl module if a condition holds
124 Use integer arithmetic instead of floating point
128 Request less of something from the compiler
132 Manipulate @INC at compile time
136 Use and avoid POSIX locales for built-in operations
140 Set default PerlIO layers for input and output
144 Restrict unsafe operations when compiling
148 Package for overloading perl operations
152 Alter regular expression behaviour
156 Enable simple signal handling
160 Control sort() behaviour
164 Restrict unsafe constructs
172 Perl extension allowing use of interpreter based threads from perl
174 =item threads::shared
176 Perl extension for sharing data structures between threads
180 Enable/disable UTF-8 (or UTF-EBCDIC) in source code
184 Predeclare global variable names (obsolete)
188 Perl extension for Version Objects
192 Control VMS-specific language features
196 Control optional warnings
198 =item warnings::register
200 Warnings import function
204 =head2 Standard Modules
206 Standard, bundled modules are all expected to behave in a well-defined
207 manner with respect to namespace pollution because they use the
208 Exporter module. See their own documentation for details.
210 It's possible that not all modules listed below are installed on your
211 system. For example, the GDBM_File module will not be installed if you
212 don't have the gdbm library.
218 Provide framework for multiple DBMs
220 =item Attribute::Handlers
222 Simpler definition of attribute handlers
226 Load subroutines only on demand
230 Split a package for autoloading
238 Autogenerated data about Perl ops, used to generate bytecode
242 Assemble Perl bytecode
250 Perl compiler's bytecode backend
254 Perl compiler's C backend
258 Perl compiler's optimized C translation backend
262 Walk Perl syntax tree, printing concise info about ops
266 Walk Perl syntax tree, printing debug info about ops
270 Perl compiler backend to produce perl code
272 =item B::Disassembler
274 Disassemble Perl bytecode
282 Show lexical variables used in functions or files
286 Helper module for CC backend
290 Show what stashes are loaded
294 Walk Perl syntax tree, printing terse info about ops
298 Generates cross reference reports for Perl programs
302 Benchmark running times of Perl code
306 Load byte compiled perl code
310 Simple Common Gateway Interface Class
314 Backward compatibility module for CGI.pm
318 CGI routines for writing to the HTTPD (or other) error log
322 Interface to Netscape Cookies
326 CGI Interface for Fast CGI
330 Module to produce nicely formatted HTML code
334 Simple Interface to Server Push
338 Backward compatibility module for defunct CGI::Switch
342 Internal utilities used by CGI module
346 Query, download and build perl modules from CPAN sites
348 =item CPAN::FirstTime
350 Utility for CPAN::Config file Initialization
354 Wrapper around CPAN.pm without using any XS module
358 Warn of errors (from perspective of caller)
362 No user serviceable parts inside
366 Report the search path for a class's ISA tree
370 Declare struct-like datatypes as Perl classes
374 Access Perl configuration information
378 Get pathname of current working directory
382 Programmatic interface to the Perl debugging API (draft, subject to
386 Perl5 access to Berkeley DB version 1.x
390 Stringified perl data structures, suitable for both printing and C<eval>
398 Perl/Pollution/Portability
402 A data debugging tool for the XS programmer
404 =item Devel::SelfStubber
406 Generate stubs for a SelfLoading module
410 Modules that calculate message digests
414 Perl interface to the MD5 Algorithm
422 Supply object methods for directory handles
426 Provides screen dump of Perl data.
430 Dynamically load C libraries into Perl code
438 Alias definitions to encodings
442 Single Byte Encodings
444 =item Encode::CJKConstants
446 Internally used by Encode::??::ISO_2022_*
450 China-based Chinese Encodings
454 Internally used by Encode::CN
458 Internally used by Encode
464 =item Encode::Encoder
466 Object Oriented Encoder
468 =item Encode::Encoding
470 Encode Implementation Base Class
474 Guesses encoding from data
480 =item Encode::JP::H2Z
482 Internally used by Encode::JP::2022_JP*
484 =item Encode::JP::JIS7
486 Internally used by Encode::JP
492 =item Encode::KR::2022_KR
494 Internally used by Encode::KR
496 =item Encode::MIME::Header
498 MIME 'B' and 'Q' header encoding
502 A detailed document on Encode and PerlIO
504 =item Encode::Supported
506 Encodings supported by Encode
514 Taiwan-based Chinese Encodings
516 =item Encode::Unicode
518 Various Unicode Transformation Formats
520 =item Encode::Unicode::UTF7
526 Use nice English (or awk) names for ugly punctuation variables
530 Perl module that imports environment variables as scalars or arrays
534 System errno constants
538 Implements default import method for modules
540 =item Exporter::Heavy
544 =item ExtUtils::Command
546 Utilities to replace common UNIX commands in Makefiles etc.
548 =item ExtUtils::Command::MM
550 Commands for the MM's to use in Makefiles
552 =item ExtUtils::Constant
554 Generate XS code to import C header constants
556 =item ExtUtils::Embed
558 Utilities for embedding Perl in C/C++ applications
560 =item ExtUtils::Install
562 Install files from here to there
564 =item ExtUtils::Installed
566 Inventory management of installed modules
568 =item ExtUtils::Liblist
570 Determine libraries to use and how to use them
574 OS adjusted ExtUtils::MakeMaker subclass
576 =item ExtUtils::MM_Any
578 Platform-agnostic MM methods
580 =item ExtUtils::MM_BeOS
582 Methods to override UN*X behaviour in ExtUtils::MakeMaker
584 =item ExtUtils::MM_Cygwin
586 Methods to override UN*X behaviour in ExtUtils::MakeMaker
588 =item ExtUtils::MM_DOS
590 DOS specific subclass of ExtUtils::MM_Unix
592 =item ExtUtils::MM_MacOS
594 Methods to override UN*X behaviour in ExtUtils::MakeMaker
596 =item ExtUtils::MM_NW5
598 Methods to override UN*X behaviour in ExtUtils::MakeMaker
600 =item ExtUtils::MM_OS2
602 Methods to override UN*X behaviour in ExtUtils::MakeMaker
604 =item ExtUtils::MM_UWIN
606 U/WIN specific subclass of ExtUtils::MM_Unix
608 =item ExtUtils::MM_Unix
610 Methods used by ExtUtils::MakeMaker
612 =item ExtUtils::MM_VMS
614 Methods to override UN*X behaviour in ExtUtils::MakeMaker
616 =item ExtUtils::MM_Win32
618 Methods to override UN*X behaviour in ExtUtils::MakeMaker
620 =item ExtUtils::MM_Win95
622 Method to customize MakeMaker for Win9X
626 ExtUtils::MakeMaker subclass for customization
628 =item ExtUtils::MakeMaker
630 Create a module Makefile
632 =item ExtUtils::MakeMaker::FAQ
634 Frequently Asked Questions About MakeMaker
636 =item ExtUtils::MakeMaker::Tutorial
638 Writing a module with MakeMaker
640 =item ExtUtils::MakeMaker::bytes
642 Version-agnostic bytes.pm
644 =item ExtUtils::MakeMaker::vmsish
646 Platform-agnostic vmsish.pm
648 =item ExtUtils::Manifest
650 Utilities to write and check a MANIFEST file
652 =item ExtUtils::Mkbootstrap
654 Make a bootstrap file for use by DynaLoader
656 =item ExtUtils::Mksymlists
658 Write linker options files for dynamic extension
660 =item ExtUtils::Packlist
662 Manage .packlist files
664 =item ExtUtils::testlib
666 Add blib/* directories to @INC
670 Replace functions with equivalents which succeed or die
674 Load the C Fcntl.h defines
678 Split a pathname into pieces
680 =item File::CheckTree
682 Run many filetest checks on a tree
686 Compare files or filehandles
690 Copy files or filehandles
694 DOS like globbing and then some
698 Traverse a directory tree.
702 Perl extension for BSD glob routine
706 Create or remove directory trees
710 Portably perform operations on file names
712 =item File::Spec::Cygwin
714 Methods for Cygwin file specs
716 =item File::Spec::Epoc
718 Methods for Epoc file specs
720 =item File::Spec::Functions
722 Portably perform operations on file names
724 =item File::Spec::Mac
726 File::Spec for Mac OS (Classic)
728 =item File::Spec::OS2
730 Methods for OS/2 file specs
732 =item File::Spec::Unix
734 File::Spec for Unix, base for other File::Spec modules
736 =item File::Spec::VMS
738 Methods for VMS file specs
740 =item File::Spec::Win32
742 Methods for Win32 file specs
746 Return name and handle of a temporary file safely
750 By-name interface to Perl's built-in stat() functions
754 Keep more files open than the system permits
758 Supply object methods for filehandles
762 Simplified source filtering
764 =item Filter::Util::Call
766 Perl Source Filter Utility Module
770 Locate directory of original perl script
774 Perl5 access to the gdbm library.
778 Extended processing of command line options
782 Process single-character switches with switch clustering
786 A selection of general-utility hash subroutines
790 Compare 8-bit scalar data according to the current locale
794 Functions for dealing with RFC3066-style language tags
796 =item I18N::LangTags::List
798 Tags and names for human languages
802 Query locale information
806 Load various IO modules
810 Supply object methods for directory handles
814 Supply object methods for filehandles
818 Supply object methods for I/O handles
822 Supply object methods for pipes
826 Object interface to system poll call
830 Supply seek based methods for I/O objects
834 OO interface to the select system call
838 Object interface to socket communications
840 =item IO::Socket::INET
842 Object interface for AF_INET domain sockets
844 =item IO::Socket::UNIX
846 Object interface for AF_UNIX domain sockets
850 Open a process for both reading and writing
854 Open a process for reading, writing, and error handling
862 SysV Msg IPC object class
864 =item IPC::SysV::Semaphore
866 SysV Semaphore IPC object class
870 A selection of general-utility list subroutines
872 =item Locale::Constants
874 Constants for Locale codes
876 =item Locale::Country
878 ISO codes for country identification (ISO 3166)
880 =item Locale::Currency
882 ISO three letter codes for currency identification (ISO 4217)
884 =item Locale::Language
886 ISO two letter codes for language identification (ISO 639)
888 =item Locale::Maketext
890 Framework for localization
892 =item Locale::Maketext::TPJ13
894 Article about software localization
898 ISO codes for script identification (ISO 15924)
902 Encoding and decoding of base64 strings
904 =item MIME::Base64::QuotedPrint
906 Encoding and decoding of quoted-printable strings
910 Arbitrary size floating point math package
914 Arbitrary size integer math package
916 =item Math::BigInt::Calc
918 Pure Perl module to support Math::BigInt
922 Arbitrarily big rationals
926 Complex numbers and associated mathematical functions
930 Trigonometric functions
934 Make functions faster by trading space for time
936 =item Memoize::AnyDBM_File
938 Glue to provide EXISTS for AnyDBM_File for Storable use
940 =item Memoize::Expire
942 Plug-in module for automatic expiration of memoized values
944 =item Memoize::ExpireFile
946 Test for Memoize expiration semantics
948 =item Memoize::ExpireTest
950 Test for Memoize expiration semantics
952 =item Memoize::NDBM_File
954 Glue to provide EXISTS for NDBM_File for Storable use
956 =item Memoize::SDBM_File
958 Glue to provide EXISTS for SDBM_File for Storable use
960 =item Memoize::Storable
962 Store Memoized data in Storable database
966 Tied access to ndbm files
970 Provide a pseudo-class NEXT (et al) that allows method redispatch
974 Network Command class (as used by FTP, SMTP etc)
978 Local configuration data for libnet
982 Attempt to evaluate the current host's internet name and domain
994 OO interface to users netrc file
998 Post Office Protocol 3 Client class (RFC1939)
1002 Check a remote host for reachability
1006 Simple Mail Transfer Protocol Client
1010 Time and daytime network client interface
1014 By-name interface to Perl's built-in gethost*() functions
1016 =item Net::libnetFAQ
1018 Libnet Frequently Asked Questions
1022 By-name interface to Perl's built-in getnet*() functions
1026 By-name interface to Perl's built-in getproto*() functions
1030 By-name interface to Perl's built-in getserv*() functions
1034 Generic interface to Perl Compiler backends
1038 Tied access to odbm files
1042 Disable named opcodes when compiling perl code
1046 Perl interface to IEEE Std 1003.1
1050 On demand loader for PerlIO layers and root of PerlIO::* name space
1052 =item PerlIO::encoding
1056 =item PerlIO::scalar
1058 In-memory IO, scalar IO
1062 Helper class for PerlIO layers implemented in perl
1064 =item PerlIO::via::QuotedPrint
1066 PerlIO layer for quoted-printable strings
1070 Check pod documents for syntax errors
1074 Find POD documents in directory trees
1076 =item Pod::Functions
1078 Group Perl's functions a la perlfunc.pod
1082 Module to convert pod files to HTML
1084 =item Pod::InputObjects
1086 Objects representing POD input paragraphs, commands, etc.
1090 Convert Pod data to formatted Latex
1094 Convert POD data to formatted *roff input
1096 =item Pod::ParseLink
1098 Parse an LE<lt>E<gt> formatting code in POD text
1100 =item Pod::ParseUtils
1102 Helpers for POD parsing and conversion
1106 Base class for creating POD filters and translators
1108 =item Pod::Perldoc::ToChecker
1110 Let Perldoc check Pod for errors
1112 =item Pod::Perldoc::ToMan
1114 Let Perldoc render Pod as man pages
1116 =item Pod::Perldoc::ToNroff
1118 Let Perldoc convert Pod to nroff
1120 =item Pod::Perldoc::ToPod
1122 Let Perldoc render Pod as ... Pod!
1124 =item Pod::Perldoc::ToRtf
1126 Let Perldoc render Pod as RTF
1128 =item Pod::Perldoc::ToText
1130 Let Perldoc render Pod as plaintext
1132 =item Pod::Perldoc::ToTk
1134 Let Perldoc use Tk::Pod to render Pod
1136 =item Pod::Perldoc::ToXml
1138 Let Perldoc render Pod as XML
1140 =item Pod::PlainText
1142 Convert POD data to formatted ASCII text
1146 Perl extension for converting Pod to old style Pod.
1150 Extract selected sections of POD from input
1154 Convert POD data to formatted ASCII text
1156 =item Pod::Text::Color
1158 Convert POD data to formatted color ASCII text
1160 =item Pod::Text::Overstrike
1162 Convert POD data to formatted overstrike text
1164 =item Pod::Text::Termcap
1166 Convert POD data to ASCII text with format escapes
1170 Print a usage message from embedded pod documentation
1174 Tied access to sdbm files
1178 Compile and execute code in restricted compartments
1182 A selection of general-utility scalar subroutines
1186 Search for key in dictionary file
1190 Save and restore selected file handle
1194 Load functions only on demand
1198 Run shell commands transparently within perl
1202 Load the C socket.h defines and structure manipulators
1206 Persistence for Perl data structures
1210 A switch statement for Perl
1214 Manipulate Perl symbols and their names
1218 Try every conceivable way to get hostname
1222 Perl interface to the UNIX syslog(3) calls
1224 =item Term::ANSIColor
1226 Color screen output using ANSI escape sequences
1230 Perl termcap interface
1232 =item Term::Complete
1234 Perl word completion module
1236 =item Term::ReadLine
1238 Perl interface to various C<readline> packages.
1242 Provides a simple framework for writing test scripts
1246 Backend for building test libraries
1250 Run Perl standard test scripts with statistics
1252 =item Test::Harness::Assert
1256 =item Test::Harness::Iterator
1258 Internal Test::Harness Iterator
1260 =item Test::Harness::Straps
1262 Detailed analysis of test results
1266 Yet another framework for writing test scripts
1270 Basic utilities for writing tests.
1272 =item Test::Tutorial
1274 A tutorial about writing really basic tests
1278 Create an abbreviation table from a list
1280 =item Text::Balanced
1282 Extract delimited text sequences from strings.
1284 =item Text::ParseWords
1286 Parse text into an array of tokens or array of arrays
1290 Implementation of the Soundex Algorithm as Described by Knuth
1294 Expand and unexpand tabs per the unix expand(1) and unexpand(1)
1298 Line wrapping to form simple paragraphs
1302 Manipulate threads in Perl (for old code only)
1308 =item Thread::Semaphore
1310 Thread-safe semaphores
1312 =item Thread::Signal
1314 Start a thread which runs signal handlers reliably (for old code)
1316 =item Thread::Specific
1318 Thread-specific keys
1322 Base class for tied arrays
1326 Access the lines of a disk file via a Perl array
1330 Base class definitions for tied handles
1334 Base class definitions for tied hashes
1338 Add data to hash when needed
1342 Use references as hash keys
1346 Base class definitions for tied scalars
1348 =item Tie::SubstrHash
1350 Fixed-table-size, fixed-key-length hashing
1354 High resolution alarm, sleep, gettimeofday, interval timers
1358 Efficiently compute time from local and GMT time
1362 By-name interface to Perl's built-in gmtime() function
1364 =item Time::localtime
1366 By-name interface to Perl's built-in localtime() function
1370 Internal object used by Time::gmtime and Time::localtime
1374 Base class for ALL classes (blessed references)
1376 =item Unicode::Collate
1378 Unicode Collation Algorithm
1380 =item Unicode::Normalize
1382 Unicode Normalization Forms
1386 Unicode character database
1390 By-name interface to Perl's built-in getgr*() functions
1394 By-name interface to Perl's built-in getpw*() functions
1398 Interfaces to some Win32 API Functions
1406 Module to test the XS typemaps distributed with perl
1410 Dynamically load C libraries into Perl code
1414 To find out I<all> modules installed on your system, including
1415 those without documentation or outside the standard release,
1416 just use the following command (under the default win32 shell,
1417 double quotes should be used instead of single quotes).
1419 % perl -MFile::Find=find -MFile::Spec::Functions -Tlwe \
1420 'find { wanted => sub { print canonpath $_ if /\.pm\z/ },
1421 no_chdir => 1 }, @INC'
1423 (The -T is here to prevent '.' from being listed in @INC.)
1424 They should all have their own documentation installed and accessible
1425 via your system man(1) command. If you do not have a B<find>
1426 program, you can use the Perl B<find2perl> program instead, which
1427 generates Perl code as output you can run through perl. If you
1428 have a B<man> program but it doesn't find your modules, you'll have
1429 to fix your manpath. See L<perl> for details. If you have no
1430 system B<man> command, you might try the B<perldoc> program.
1432 Note also that the command C<perldoc perllocal> gives you a (possibly
1433 incomplete) list of the modules that have been further installed on
1434 your system. (The perllocal.pod file is updated by the standard MakeMaker
1437 =head2 Extension Modules
1439 Extension modules are written in C (or a mix of Perl and C). They
1440 are usually dynamically loaded into Perl if and when you need them,
1441 but may also be linked in statically. Supported extension modules
1442 include Socket, Fcntl, and POSIX.
1444 Many popular C extension modules do not come bundled (at least, not
1445 completely) due to their sizes, volatility, or simply lack of time
1446 for adequate testing and configuration across the multitude of
1447 platforms on which Perl was beta-tested. You are encouraged to
1448 look for them on CPAN (described below), or using web search engines
1449 like Alta Vista or Google.
1453 CPAN stands for Comprehensive Perl Archive Network; it's a globally
1454 replicated trove of Perl materials, including documentation, style
1455 guides, tricks and traps, alternate ports to non-Unix systems and
1456 occasional binary distributions for these. Search engines for
1457 CPAN can be found at http://www.cpan.org/
1459 Most importantly, CPAN includes around a thousand unbundled modules,
1460 some of which require a C compiler to build. Major categories of
1467 Language Extensions and Documentation Tools
1475 Operating System Interfaces
1479 Networking, Device Control (modems) and InterProcess Communication
1483 Data Types and Data Type Utilities
1495 Interfaces to / Emulations of Other Programming Languages
1499 File Names, File Systems and File Locking (see also File Handles)
1503 String Processing, Language Text Processing, Parsing, and Searching
1507 Option, Argument, Parameter, and Configuration File Processing
1511 Internationalization and Locale
1515 Authentication, Security, and Encryption
1519 World Wide Web, HTML, HTTP, CGI, MIME
1523 Server and Daemon Utilities
1527 Archiving and Compression
1531 Images, Pixmap and Bitmap Manipulation, Drawing, and Graphing
1535 Mail and Usenet News
1539 Control Flow Utilities (callbacks and exceptions etc)
1543 File Handle and Input/Output Stream Utilities
1547 Miscellaneous Modules
1551 The list of the registered CPAN sites as of this writing follows.
1552 Please note that the sorting order is alphabetical on fields:
1558 |-->[state/province]
1564 and thus the North American servers happen to be listed between the
1565 European and the South American sites.
1567 You should try to choose one close to you.
1575 http://ftp.rucus.ru.ac.za/pub/perl/CPAN/
1576 ftp://ftp.rucus.ru.ac.za/pub/perl/CPAN/
1577 ftp://ftp.is.co.za/programming/perl/CPAN/
1578 ftp://ftp.saix.net/pub/CPAN/
1579 ftp://ftp.sun.ac.za/CPAN/CPAN/
1589 http://cpan.linuxforum.net/
1590 http://cpan.shellhung.org/
1591 ftp://ftp.shellhung.org/pub/CPAN
1592 ftp://mirrors.hknet.com/CPAN
1596 http://mirrors.tf.itb.ac.id/cpan/
1597 http://cpan.cbn.net.id/
1598 ftp://ftp.cbn.net.id/mirror/CPAN
1602 ftp://ftp.iglu.org.il/pub/CPAN/
1603 http://cpan.lerner.co.il/
1604 http://bioinfo.weizmann.ac.il/pub/software/perl/CPAN/
1605 ftp://bioinfo.weizmann.ac.il/pub/software/perl/CPAN/
1609 ftp://ftp.u-aizu.ac.jp/pub/CPAN
1610 ftp://ftp.kddlabs.co.jp/CPAN/
1611 ftp://ftp.ayamura.org/pub/CPAN/
1612 ftp://ftp.jaist.ac.jp/pub/lang/perl/CPAN/
1614 ftp://ftp.cpan.jp/CPAN/
1615 ftp://ftp.dti.ad.jp/pub/lang/CPAN/
1616 ftp://ftp.ring.gr.jp/pub/lang/perl/CPAN/
1620 http://cpan.MyBSD.org.my
1621 http://mirror.leafbug.org/pub/CPAN
1622 http://ossig.mncc.com.my/mirror/pub/CPAN
1624 =item Russian Federation
1626 http://cpan.tomsk.ru
1627 ftp://cpan.tomsk.ru/
1631 ftp://ftp.isu.net.sa/pub/CPAN/
1635 http://CPAN.en.com.sg/
1636 ftp://cpan.en.com.sg/
1637 http://mirror.averse.net/pub/CPAN
1638 ftp://mirror.averse.net/pub/CPAN
1639 http://cpan.oss.eznetsols.org
1640 ftp://ftp.oss.eznetsols.org/cpan
1644 http://CPAN.bora.net/
1645 ftp://ftp.bora.net/pub/CPAN/
1646 http://mirror.kr.FreeBSD.org/CPAN
1647 ftp://ftp.kr.FreeBSD.org/pub/CPAN
1651 ftp://ftp.nctu.edu.tw/UNIX/perl/CPAN
1652 http://cpan.cdpa.nsysu.edu.tw/
1653 ftp://cpan.cdpa.nsysu.edu.tw/pub/CPAN
1654 http://ftp.isu.edu.tw/pub/CPAN
1655 ftp://ftp.isu.edu.tw/pub/CPAN
1656 ftp://ftp1.sinica.edu.tw/pub1/perl/CPAN/
1657 http://ftp.tku.edu.tw/pub/CPAN/
1658 ftp://ftp.tku.edu.tw/pub/CPAN/
1662 ftp://ftp.loxinfo.co.th/pub/cpan/
1663 ftp://ftp.cs.riubon.ac.th/pub/mirrors/CPAN/
1667 =head2 Central America
1673 http://ftp.ucr.ac.cr/Unix/CPAN/
1674 ftp://ftp.ucr.ac.cr/pub/Unix/CPAN/
1684 http://cpan.inode.at/
1686 ftp://ftp.tuwien.ac.at/pub/CPAN/
1690 http://ftp.easynet.be/pub/CPAN/
1691 ftp://ftp.easynet.be/pub/CPAN/
1692 http://cpan.skynet.be
1693 ftp://ftp.cpan.skynet.be/pub/CPAN
1694 ftp://ftp.kulnet.kuleuven.ac.be/pub/mirror/CPAN/
1696 =item Bosnia and Herzegovina
1698 http://cpan.blic.net/
1702 http://cpan.online.bg
1703 ftp://cpan.online.bg/cpan
1704 http://cpan.zadnik.org
1705 ftp://ftp.zadnik.org/mirrors/CPAN/
1706 http://cpan.lirex.net/
1707 ftp://ftp.lirex.net/pub/mirrors/CPAN
1711 http://ftp.linux.hr/pub/CPAN/
1712 ftp://ftp.linux.hr/pub/CPAN/
1714 =item Czech Republic
1716 ftp://ftp.fi.muni.cz/pub/CPAN/
1717 ftp://sunsite.mff.cuni.cz/MIRRORS/ftp.funet.fi/pub/languages/perl/CPAN/
1721 http://mirrors.sunsite.dk/cpan/
1722 ftp://sunsite.dk/mirrors/cpan/
1723 http://cpan.cybercity.dk
1724 http://www.cpan.dk/CPAN/
1725 ftp://www.cpan.dk/ftp.cpan.org/CPAN/
1729 ftp://ftp.ut.ee/pub/languages/perl/CPAN/
1733 ftp://ftp.funet.fi/pub/languages/perl/CPAN/
1734 http://mirror.eunet.fi/CPAN
1738 http://www.enstimac.fr/Perl/CPAN
1739 http://ftp.u-paris10.fr/perl/CPAN
1740 ftp://ftp.u-paris10.fr/perl/CPAN
1741 http://cpan.mirrors.easynet.fr/
1742 ftp://cpan.mirrors.easynet.fr/pub/ftp.cpan.org/
1743 ftp://ftp.club-internet.fr/pub/perl/CPAN/
1745 ftp://ftp.lip6.fr/pub/perl/CPAN/
1746 ftp://ftp.oleane.net/pub/mirrors/CPAN/
1747 ftp://ftp.pasteur.fr/pub/computing/CPAN/
1748 http://mir2.ovh.net/ftp.cpan.org
1749 ftp://mir1.ovh.net/ftp.cpan.org
1750 http://ftp.crihan.fr/mirrors/ftp.cpan.org/
1751 ftp://ftp.crihan.fr/mirrors/ftp.cpan.org/
1752 http://ftp.u-strasbg.fr/CPAN
1753 ftp://ftp.u-strasbg.fr/CPAN
1754 ftp://cpan.cict.fr/pub/CPAN/
1755 ftp://ftp.uvsq.fr/pub/perl/CPAN/
1759 ftp://ftp.rub.de/pub/CPAN/
1760 ftp://ftp.freenet.de/pub/ftp.cpan.org/pub/CPAN/
1761 ftp://ftp.uni-erlangen.de/pub/source/CPAN/
1762 ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/CPAN
1763 http://pandemonium.tiscali.de/pub/CPAN/
1764 ftp://pandemonium.tiscali.de/pub/CPAN/
1765 http://ftp.gwdg.de/pub/languages/perl/CPAN/
1766 ftp://ftp.gwdg.de/pub/languages/perl/CPAN/
1767 ftp://ftp.uni-hamburg.de/pub/soft/lang/perl/CPAN/
1768 ftp://ftp.leo.org/pub/CPAN/
1769 http://cpan.noris.de/
1770 ftp://cpan.noris.de/pub/CPAN/
1771 ftp://ftp.mpi-sb.mpg.de/pub/perl/CPAN/
1772 ftp://ftp.gmd.de/mirrors/CPAN/
1776 ftp://ftp.acn.gr/pub/lang/perl
1777 ftp://ftp.forthnet.gr/pub/languages/perl/CPAN
1778 ftp://ftp.ntua.gr/pub/lang/perl/
1782 http://ftp.kfki.hu/packages/perl/CPAN/
1783 ftp://ftp.kfki.hu/pub/packages/perl/CPAN/
1787 http://ftp.rhnet.is/pub/CPAN/
1788 ftp://ftp.rhnet.is/pub/CPAN/
1792 http://cpan.indigo.ie/
1793 ftp://cpan.indigo.ie/pub/CPAN/
1794 http://ftp.heanet.ie/mirrors/ftp.perl.org/pub/CPAN
1795 ftp://ftp.heanet.ie/mirrors/ftp.perl.org/pub/CPAN
1796 http://sunsite.compapp.dcu.ie/pub/perl/
1797 ftp://sunsite.compapp.dcu.ie/pub/perl/
1801 http://cpan.nettuno.it/
1802 http://gusp.dyndns.org/CPAN/
1803 ftp://gusp.dyndns.org/pub/CPAN
1804 http://softcity.iol.it/cpan
1805 ftp://softcity.iol.it/pub/cpan
1806 ftp://ftp.unina.it/pub/Other/CPAN/CPAN/
1807 ftp://ftp.unipi.it/pub/mirror/perl/CPAN/
1808 ftp://cis.uniRoma2.it/CPAN/
1809 ftp://ftp.edisontel.it/pub/CPAN_Mirror/
1810 http://cpan.flashnet.it/
1811 ftp://ftp.flashnet.it/pub/CPAN/
1815 http://kvin.lv/pub/CPAN/
1819 ftp://ftp.unix.lt/pub/CPAN/
1823 ftp://download.xs4all.nl/pub/mirror/CPAN/
1824 ftp://ftp.nl.uu.net/pub/CPAN/
1825 ftp://ftp.nluug.nl/pub/languages/perl/CPAN/
1826 http://cpan.cybercomm.nl/
1827 ftp://mirror.cybercomm.nl/pub/CPAN
1828 ftp://mirror.vuurwerk.nl/pub/CPAN/
1829 ftp://ftp.cpan.nl/pub/CPAN/
1830 http://ftp.easynet.nl/mirror/CPAN
1831 ftp://ftp.easynet.nl/mirror/CPAN
1832 http://archive.cs.uu.nl/mirror/CPAN/
1833 ftp://ftp.cs.uu.nl/mirror/CPAN/
1837 ftp://ftp.uninett.no/pub/languages/perl/CPAN
1838 ftp://ftp.uit.no/pub/languages/perl/cpan/
1842 ftp://ftp.mega.net.pl/CPAN
1843 ftp://ftp.man.torun.pl/pub/doc/CPAN/
1844 ftp://sunsite.icm.edu.pl/pub/CPAN/
1848 ftp://ftp.ua.pt/pub/CPAN/
1849 ftp://perl.di.uminho.pt/pub/CPAN/
1850 http://cpan.dei.uc.pt/
1851 ftp://ftp.dei.uc.pt/pub/CPAN
1852 ftp://ftp.nfsi.pt/pub/CPAN
1853 http://ftp.linux.pt/pub/mirrors/CPAN
1854 ftp://ftp.linux.pt/pub/mirrors/CPAN
1856 ftp://cpan.ip.pt/pub/cpan/
1857 http://cpan.telepac.pt/
1858 ftp://ftp.telepac.pt/pub/cpan/
1862 ftp://ftp.bio-net.ro/pub/CPAN
1863 ftp://ftp.kappa.ro/pub/mirrors/ftp.perl.org/pub/CPAN/
1864 ftp://ftp.lug.ro/CPAN
1865 ftp://ftp.roedu.net/pub/CPAN/
1866 ftp://ftp.dntis.ro/pub/cpan/
1867 ftp://ftp.iasi.roedu.net/pub/mirrors/ftp.cpan.org/
1868 http://cpan.ambra.ro/
1869 ftp://ftp.ambra.ro/pub/CPAN
1870 ftp://ftp.dnttm.ro/pub/CPAN/
1871 ftp://ftp.lasting.ro/pub/CPAN
1872 ftp://ftp.timisoara.roedu.net/mirrors/CPAN/
1876 ftp://ftp.chg.ru/pub/lang/perl/CPAN/
1877 http://cpan.rinet.ru/
1878 ftp://cpan.rinet.ru/pub/mirror/CPAN/
1879 ftp://ftp.aha.ru/pub/CPAN/
1880 ftp://ftp.corbina.ru/pub/CPAN/
1881 http://cpan.sai.msu.ru/
1882 ftp://ftp.sai.msu.su/pub/lang/perl/CPAN/
1886 ftp://ftp.cvt.stuba.sk/pub/CPAN/
1890 ftp://ftp.arnes.si/software/perl/CPAN/
1894 http://cpan.imasd.elmundo.es/
1895 ftp://ftp.rediris.es/mirror/CPAN/
1896 ftp://ftp.ri.telefonica-data.net/CPAN
1897 ftp://ftp.etse.urv.es/pub/perl/
1901 http://ftp.du.se/CPAN/
1902 ftp://ftp.du.se/pub/CPAN/
1903 http://mirror.dataphone.se/CPAN
1904 ftp://mirror.dataphone.se/pub/CPAN
1905 ftp://ftp.sunet.se/pub/lang/perl/CPAN/
1909 http://cpan.mirror.solnet.ch/
1910 ftp://ftp.solnet.ch/mirror/CPAN/
1911 ftp://ftp.danyk.ch/CPAN/
1912 ftp://sunsite.cnlab-switch.ch/mirror/CPAN/
1916 http://ftp.ulak.net.tr/perl/CPAN/
1917 ftp://ftp.ulak.net.tr/perl/CPAN
1918 ftp://sunsite.bilkent.edu.tr/pub/languages/CPAN/
1924 ftp://ftp.perl.org.ua/pub/CPAN/
1925 http://no-more.kiev.ua/CPAN/
1926 ftp://no-more.kiev.ua/pub/CPAN/
1928 =item United Kingdom
1930 http://www.mirror.ac.uk/sites/ftp.funet.fi/pub/languages/perl/CPAN
1931 ftp://ftp.mirror.ac.uk/sites/ftp.funet.fi/pub/languages/perl/CPAN/
1932 http://cpan.teleglobe.net/
1933 ftp://cpan.teleglobe.net/pub/CPAN
1934 http://cpan.mirror.anlx.net/
1935 ftp://ftp.mirror.anlx.net/CPAN/
1936 http://cpan.etla.org/
1937 ftp://cpan.etla.org/pub/CPAN
1938 ftp://ftp.demon.co.uk/pub/CPAN/
1939 http://cpan.m.flirble.org/
1940 ftp://ftp.flirble.org/pub/languages/perl/CPAN/
1941 ftp://ftp.plig.org/pub/CPAN/
1942 http://cpan.hambule.co.uk/
1943 http://cpan.mirrors.clockerz.net/
1944 ftp://ftp.clockerz.net/pub/CPAN/
1945 ftp://usit.shef.ac.uk/pub/packages/CPAN/
1949 =head2 North America
1959 http://cpan.sunsite.ualberta.ca/
1960 ftp://cpan.sunsite.ualberta.ca/pub/CPAN/
1964 http://theoryx5.uwinnipeg.ca/pub/CPAN/
1965 ftp://theoryx5.uwinnipeg.ca/pub/CPAN/
1969 ftp://cpan.chebucto.ns.ca/pub/CPAN/
1973 ftp://ftp.nrc.ca/pub/CPAN/
1979 http://cpan.azc.uam.mx
1980 ftp://cpan.azc.uam.mx/mirrors/CPAN
1981 http://www.cpan.unam.mx/
1982 ftp://ftp.unam.mx/pub/CPAN
1983 http://www.msg.com.mx/CPAN/
1984 ftp://ftp.msg.com.mx/pub/CPAN/
1992 http://mirror.hiwaay.net/CPAN/
1993 ftp://mirror.hiwaay.net/CPAN/
1997 http://cpan.develooper.com/
1998 http://www.cpan.org/
1999 ftp://cpan.valueclick.com/pub/CPAN/
2000 http://www.mednor.net/ftp/pub/mirrors/CPAN/
2001 ftp://ftp.mednor.net/pub/mirrors/CPAN/
2002 http://mirrors.gossamer-threads.com/CPAN
2003 ftp://cpan.nas.nasa.gov/pub/perl/CPAN/
2004 http://mirrors.kernel.org/cpan/
2005 ftp://mirrors.kernel.org/pub/CPAN
2006 http://cpan-sj.viaverio.com/
2007 ftp://cpan-sj.viaverio.com/pub/CPAN/
2008 http://cpan.digisle.net/
2009 ftp://cpan.digisle.net/pub/CPAN
2010 http://www.perl.com/CPAN/
2011 http://www.uberlan.net/CPAN
2015 ftp://ftp.cs.colorado.edu/pub/perl/CPAN/
2016 http://cpan.four10.com
2020 http://ftp.lug.udel.edu/pub/CPAN
2021 ftp://ftp.lug.udel.edu/pub/CPAN
2023 =item District of Columbia
2025 ftp://ftp.dc.aleron.net/pub/CPAN/
2029 ftp://ftp.cise.ufl.edu/pub/mirrors/CPAN/
2030 http://mirror.csit.fsu.edu/pub/CPAN/
2031 ftp://mirror.csit.fsu.edu/pub/CPAN/
2032 http://cpan.mirrors.nks.net/
2036 ftp://ftp.uwsg.iu.edu/pub/perl/CPAN/
2037 http://cpan.netnitco.net/
2038 ftp://cpan.netnitco.net/pub/mirrors/CPAN/
2039 http://archive.progeny.com/CPAN/
2040 ftp://archive.progeny.com/CPAN/
2041 http://fx.saintjoe.edu/pub/CPAN
2042 ftp://ftp.saintjoe.edu/pub/CPAN
2043 http://csociety-ftp.ecn.purdue.edu/pub/CPAN
2044 ftp://csociety-ftp.ecn.purdue.edu/pub/CPAN
2048 http://cpan.uky.edu/
2049 ftp://cpan.uky.edu/pub/CPAN/
2050 http://slugsite.louisville.edu/cpan
2051 ftp://slugsite.louisville.edu/CPAN
2055 http://mirrors.towardex.com/CPAN
2056 ftp://mirrors.towardex.com/pub/CPAN
2057 ftp://ftp.ccs.neu.edu/net/mirrors/ftp.funet.fi/pub/languages/perl/CPAN/
2061 ftp://cpan.cse.msu.edu/
2062 http://cpan.calvin.edu/pub/CPAN
2063 ftp://cpan.calvin.edu/pub/CPAN
2067 http://www.oss.redundant.com/pub/CPAN
2068 ftp://www.oss.redundant.com/pub/CPAN
2072 http://ftp.cpanel.net/pub/CPAN/
2073 ftp://ftp.cpanel.net/pub/CPAN/
2074 http://cpan.teleglobe.net/
2075 ftp://cpan.teleglobe.net/pub/CPAN
2079 http://cpan.belfry.net/
2080 http://cpan.erlbaum.net/
2081 ftp://cpan.erlbaum.net/
2082 http://cpan.thepirtgroup.com/
2083 ftp://cpan.thepirtgroup.com/
2084 ftp://ftp.stealth.net/pub/CPAN/
2085 http://www.rge.com/pub/languages/perl/
2086 ftp://ftp.rge.com/pub/languages/perl/
2088 =item North Carolina
2090 http://www.ibiblio.org/pub/languages/perl/CPAN
2091 ftp://ftp.ibiblio.org/pub/languages/perl/CPAN
2092 ftp://ftp.duke.edu/pub/perl/
2093 ftp://ftp.ncsu.edu/pub/mirror/CPAN/
2097 ftp://ftp.ou.edu/mirrors/CPAN/
2101 ftp://ftp.orst.edu/pub/CPAN
2105 http://ftp.epix.net/CPAN/
2106 ftp://ftp.epix.net/pub/languages/perl/
2107 http://mirrors.phenominet.com/pub/CPAN/
2108 ftp://mirrors.phenominet.com/pub/CPAN/
2109 http://cpan.pair.com/
2110 ftp://cpan.pair.com/pub/CPAN/
2111 ftp://carroll.cac.psu.edu/pub/CPAN/
2115 ftp://ftp.sunsite.utk.edu/pub/CPAN/
2119 http://ftp.sedl.org/pub/mirrors/CPAN/
2120 http://www.binarycode.org/cpan
2121 ftp://mirror.telentente.com/pub/CPAN
2122 http://mirrors.theonlinerecordstore.com/CPAN
2126 ftp://mirror.xmission.com/CPAN/
2130 http://cpan-du.viaverio.com/
2131 ftp://cpan-du.viaverio.com/pub/CPAN/
2132 http://mirrors.rcn.net/pub/lang/CPAN/
2133 ftp://mirrors.rcn.net/pub/lang/CPAN/
2134 http://perl.secsup.org/
2135 ftp://perl.secsup.org/pub/perl/
2136 http://noc.cvaix.com/mirrors/CPAN/
2140 http://cpan.llarian.net/
2141 ftp://cpan.llarian.net/pub/CPAN/
2142 http://cpan.mirrorcentral.com/
2143 ftp://ftp.mirrorcentral.com/pub/CPAN/
2144 ftp://ftp-mirror.internap.com/pub/CPAN/
2148 http://mirror.sit.wisc.edu/pub/CPAN/
2149 ftp://mirror.sit.wisc.edu/pub/CPAN/
2150 http://mirror.aphix.com/CPAN
2151 ftp://mirror.aphix.com/pub/CPAN
2163 http://ftp.planetmirror.com/pub/CPAN/
2164 ftp://ftp.planetmirror.com/pub/CPAN/
2165 ftp://mirror.aarnet.edu.au/pub/perl/CPAN/
2166 ftp://cpan.topend.com.au/pub/CPAN/
2167 http://cpan.mirrors.ilisys.com.au
2171 ftp://ftp.auckland.ac.nz/pub/perl/CPAN/
2175 http://aniani.ifa.hawaii.edu/CPAN/
2176 ftp://aniani.ifa.hawaii.edu/CPAN/
2180 =head2 South America
2186 ftp://mirrors.bannerlandia.com.ar/mirrors/CPAN/
2187 http://www.linux.org.ar/mirrors/cpan
2188 ftp://ftp.linux.org.ar/mirrors/cpan
2192 ftp://cpan.pop-mg.com.br/pub/CPAN/
2193 ftp://ftp.matrix.com.br/pub/perl/CPAN/
2194 http://cpan.hostsul.com.br/
2195 ftp://cpan.hostsul.com.br/
2199 http://cpan.netglobalis.net/
2200 ftp://cpan.netglobalis.net/pub/CPAN/
2204 =head2 RSYNC Mirrors
2206 www.linux.org.ar::cpan
2207 theoryx5.uwinnipeg.ca::CPAN
2208 ftp.shellhung.org::CPAN
2209 rsync.nic.funet.fi::CPAN
2210 ftp.u-paris10.fr::CPAN
2212 rsync://ftp.crihan.fr::CPAN
2213 ftp.gwdg.de::FTP/languages/perl/CPAN/
2215 ftp.cbn.net.id::CPAN
2216 rsync://ftp.heanet.ie/mirrors/ftp.perl.org/pub/CPAN
2217 ftp.iglu.org.il::CPAN
2218 gusp.dyndns.org::cpan
2219 ftp.kddlabs.co.jp::cpan
2220 ftp.ayamura.org::pub/CPAN/
2221 mirror.leafbug.org::CPAN
2222 rsync.en.com.sg::CPAN
2223 mirror.averse.net::cpan
2224 rsync.oss.eznetsols.org
2225 ftp.kr.FreeBSD.org::CPAN
2227 cpan.cdpa.nsysu.edu.tw::CPAN
2228 cpan.teleglobe.net::CPAN
2229 rsync://rsync.mirror.anlx.net::CPAN
2232 cpan-du.viaverio.com::CPAN
2233 aniani.ifa.hawaii.edu::CPAN
2234 archive.progeny.com::CPAN
2235 rsync://slugsite.louisville.edu::CPAN
2236 mirror.aphix.com::CPAN
2237 cpan.teleglobe.net::CPAN
2238 ftp.lug.udel.edu::cpan
2239 mirrors.kernel.org::mirrors/CPAN
2240 mirrors.phenominet.com::CPAN
2242 cpan-sj.viaverio.com::CPAN
2243 mirror.csit.fsu.edu::CPAN
2244 csociety-ftp.ecn.purdue.edu::CPAN
2246 For an up-to-date listing of CPAN sites,
2247 see http://www.cpan.org/SITES or ftp://www.cpan.org/SITES .
2249 =head1 Modules: Creation, Use, and Abuse
2251 (The following section is borrowed directly from Tim Bunce's modules
2252 file, available at your nearest CPAN site.)
2254 Perl implements a class using a package, but the presence of a
2255 package doesn't imply the presence of a class. A package is just a
2256 namespace. A class is a package that provides subroutines that can be
2257 used as methods. A method is just a subroutine that expects, as its
2258 first argument, either the name of a package (for "static" methods),
2259 or a reference to something (for "virtual" methods).
2261 A module is a file that (by convention) provides a class of the same
2262 name (sans the .pm), plus an import method in that class that can be
2263 called to fetch exported symbols. This module may implement some of
2264 its methods by loading dynamic C or C++ objects, but that should be
2265 totally transparent to the user of the module. Likewise, the module
2266 might set up an AUTOLOAD function to slurp in subroutine definitions on
2267 demand, but this is also transparent. Only the F<.pm> file is required to
2268 exist. See L<perlsub>, L<perltoot>, and L<AutoLoader> for details about
2269 the AUTOLOAD mechanism.
2271 =head2 Guidelines for Module Creation
2277 Do similar modules already exist in some form?
2279 If so, please try to reuse the existing modules either in whole or
2280 by inheriting useful features into a new class. If this is not
2281 practical try to get together with the module authors to work on
2282 extending or enhancing the functionality of the existing modules.
2283 A perfect example is the plethora of packages in perl4 for dealing
2284 with command line options.
2286 If you are writing a module to expand an already existing set of
2287 modules, please coordinate with the author of the package. It
2288 helps if you follow the same naming scheme and module interaction
2289 scheme as the original author.
2293 Try to design the new module to be easy to extend and reuse.
2295 Try to C<use warnings;> (or C<use warnings qw(...);>).
2296 Remember that you can add C<no warnings qw(...);> to individual blocks
2297 of code that need less warnings.
2299 Use blessed references. Use the two argument form of bless to bless
2300 into the class name given as the first parameter of the constructor,
2305 return bless {}, $class;
2308 or even this if you'd like it to be used as either a static
2309 or a virtual method.
2313 my $class = ref($self) || $self;
2314 return bless {}, $class;
2317 Pass arrays as references so more parameters can be added later
2318 (it's also faster). Convert functions into methods where
2319 appropriate. Split large methods into smaller more flexible ones.
2320 Inherit methods from other modules if appropriate.
2322 Avoid class name tests like: C<die "Invalid" unless ref $ref eq 'FOO'>.
2323 Generally you can delete the C<eq 'FOO'> part with no harm at all.
2324 Let the objects look after themselves! Generally, avoid hard-wired
2325 class names as far as possible.
2327 Avoid C<< $r->Class::func() >> where using C<@ISA=qw(... Class ...)> and
2328 C<< $r->func() >> would work (see L<perlbot> for more details).
2330 Use autosplit so little used or newly added functions won't be a
2331 burden to programs that don't use them. Add test functions to
2332 the module after __END__ either using AutoSplit or by saying:
2334 eval join('',<main::DATA>) || die $@ unless caller();
2336 Does your module pass the 'empty subclass' test? If you say
2337 C<@SUBCLASS::ISA = qw(YOURCLASS);> your applications should be able
2338 to use SUBCLASS in exactly the same way as YOURCLASS. For example,
2339 does your application still work if you change: C<$obj = new YOURCLASS;>
2340 into: C<$obj = new SUBCLASS;> ?
2342 Avoid keeping any state information in your packages. It makes it
2343 difficult for multiple other packages to use yours. Keep state
2344 information in objects.
2348 Try to C<use strict;> (or C<use strict qw(...);>).
2349 Remember that you can add C<no strict qw(...);> to individual blocks
2350 of code that need less strictness.
2354 Follow the guidelines in the perlstyle(1) manual.
2360 Some simple style guidelines
2362 The perlstyle manual supplied with Perl has many helpful points.
2364 Coding style is a matter of personal taste. Many people evolve their
2365 style over several years as they learn what helps them write and
2366 maintain good code. Here's one set of assorted suggestions that
2367 seem to be widely used by experienced developers:
2369 Use underscores to separate words. It is generally easier to read
2370 $var_names_like_this than $VarNamesLikeThis, especially for
2371 non-native speakers of English. It's also a simple rule that works
2372 consistently with VAR_NAMES_LIKE_THIS.
2374 Package/Module names are an exception to this rule. Perl informally
2375 reserves lowercase module names for 'pragma' modules like integer
2376 and strict. Other modules normally begin with a capital letter and
2377 use mixed case with no underscores (need to be short and portable).
2379 You may find it helpful to use letter case to indicate the scope
2380 or nature of a variable. For example:
2382 $ALL_CAPS_HERE constants only (beware clashes with Perl vars)
2383 $Some_Caps_Here package-wide global/static
2384 $no_caps_here function scope my() or local() variables
2386 Function and method names seem to work best as all lowercase.
2387 e.g., C<< $obj->as_string() >>.
2389 You can use a leading underscore to indicate that a variable or
2390 function should not be used outside the package that defined it.
2394 Select what to export.
2396 Do NOT export method names!
2398 Do NOT export anything else by default without a good reason!
2400 Exports pollute the namespace of the module user. If you must
2401 export try to use @EXPORT_OK in preference to @EXPORT and avoid
2402 short or common names to reduce the risk of name clashes.
2404 Generally anything not exported is still accessible from outside the
2405 module using the ModuleName::item_name (or C<< $blessed_ref->method >>)
2406 syntax. By convention you can use a leading underscore on names to
2407 indicate informally that they are 'internal' and not for public use.
2409 (It is actually possible to get private functions by saying:
2410 C<my $subref = sub { ... }; &$subref;>. But there's no way to call that
2411 directly as a method, because a method must have a name in the symbol
2414 As a general rule, if the module is trying to be object oriented
2415 then export nothing. If it's just a collection of functions then
2416 @EXPORT_OK anything but use @EXPORT with caution.
2420 Select a name for the module.
2422 This name should be as descriptive, accurate, and complete as
2423 possible. Avoid any risk of ambiguity. Always try to use two or
2424 more whole words. Generally the name should reflect what is special
2425 about what the module does rather than how it does it. Please use
2426 nested module names to group informally or categorize a module.
2427 There should be a very good reason for a module not to have a nested name.
2428 Module names should begin with a capital letter.
2430 Having 57 modules all called Sort will not make life easy for anyone
2431 (though having 23 called Sort::Quick is only marginally better :-).
2432 Imagine someone trying to install your module alongside many others.
2433 If in any doubt ask for suggestions in comp.lang.perl.misc.
2435 If you are developing a suite of related modules/classes it's good
2436 practice to use nested classes with a common prefix as this will
2437 avoid namespace clashes. For example: Xyz::Control, Xyz::View,
2438 Xyz::Model etc. Use the modules in this list as a naming guide.
2440 If adding a new module to a set, follow the original author's
2441 standards for naming modules and the interface to methods in
2444 If developing modules for private internal or project specific use,
2445 that will never be released to the public, then you should ensure
2446 that their names will not clash with any future public module. You
2447 can do this either by using the reserved Local::* category or by
2448 using a category name that includes an underscore like Foo_Corp::*.
2450 To be portable each component of a module name should be limited to
2451 11 characters. If it might be used on MS-DOS then try to ensure each is
2452 unique in the first 8 characters. Nested modules make this easier.
2456 Have you got it right?
2458 How do you know that you've made the right decisions? Have you
2459 picked an interface design that will cause problems later? Have
2460 you picked the most appropriate name? Do you have any questions?
2462 The best way to know for sure, and pick up many helpful suggestions,
2463 is to ask someone who knows. Comp.lang.perl.misc is read by just about
2464 all the people who develop modules and it's the best place to ask.
2466 All you need to do is post a short summary of the module, its
2467 purpose and interfaces. A few lines on each of the main methods is
2468 probably enough. (If you post the whole module it might be ignored
2469 by busy people - generally the very people you want to read it!)
2471 Don't worry about posting if you can't say when the module will be
2472 ready - just say so in the message. It might be worth inviting
2473 others to help you, they may be able to complete it for you!
2477 README and other Additional Files.
2479 It's well known that software developers usually fully document the
2480 software they write. If, however, the world is in urgent need of
2481 your software and there is not enough time to write the full
2482 documentation please at least provide a README file containing:
2488 A description of the module/package/extension etc.
2492 A copyright notice - see below.
2496 Prerequisites - what else you may need to have.
2500 How to build it - possible changes to Makefile.PL etc.
2508 Recent changes in this release, especially incompatibilities
2512 Changes / enhancements you plan to make in the future.
2516 If the README file seems to be getting too large you may wish to
2517 split out some of the sections into separate files: INSTALL,
2524 Adding a Copyright Notice.
2526 How you choose to license your work is a personal decision.
2527 The general mechanism is to assert your Copyright and then make
2528 a declaration of how others may copy/use/modify your work.
2530 Perl, for example, is supplied with two types of licence: The GNU GPL
2531 and The Artistic Licence (see the files README, Copying, and Artistic,
2532 or L<perlgpl> and L<perlartistic>). Larry has good reasons for NOT
2533 just using the GNU GPL.
2535 My personal recommendation, out of respect for Larry, Perl, and the
2536 Perl community at large is to state something simply like:
2538 Copyright (c) 1995 Your Name. All rights reserved.
2539 This program is free software; you can redistribute it and/or
2540 modify it under the same terms as Perl itself.
2542 This statement should at least appear in the README file. You may
2543 also wish to include it in a Copying file and your source files.
2544 Remember to include the other words in addition to the Copyright.
2548 Give the module a version/issue/release number.
2550 To be fully compatible with the Exporter and MakeMaker modules you
2551 should store your module's version number in a non-my package
2552 variable called $VERSION. This should be a floating point
2553 number with at least two digits after the decimal (i.e., hundredths,
2554 e.g, C<$VERSION = "0.01">). Don't use a "1.3.2" style version.
2555 See L<Exporter> for details.
2557 It may be handy to add a function or method to retrieve the number.
2558 Use the number in announcements and archive file names when
2559 releasing the module (ModuleName-1.02.tar.Z).
2560 See perldoc ExtUtils::MakeMaker.pm for details.
2564 How to release and distribute a module.
2566 It's good idea to post an announcement of the availability of your
2567 module (or the module itself if small) to the comp.lang.perl.announce
2568 Usenet newsgroup. This will at least ensure very wide once-off
2571 If possible, register the module with CPAN. You should
2572 include details of its location in your announcement.
2574 Some notes about ftp archives: Please use a long descriptive file
2575 name that includes the version number. Most incoming directories
2576 will not be readable/listable, i.e., you won't be able to see your
2577 file after uploading it. Remember to send your email notification
2578 message as soon as possible after uploading else your file may get
2579 deleted automatically. Allow time for the file to be processed
2580 and/or check the file has been processed before announcing its
2583 FTP Archives for Perl Modules:
2585 Follow the instructions and links on:
2587 http://www.cpan.org/modules/00modlist.long.html
2588 http://www.cpan.org/modules/04pause.html
2590 or upload to one of these sites:
2592 https://pause.kbx.de/pause/
2593 http://pause.perl.org/pause/
2595 and notify <modules@perl.org>.
2597 By using the WWW interface you can ask the Upload Server to mirror
2598 your modules from your ftp or WWW site into your own directory on
2601 Please remember to send me an updated entry for the Module list!
2605 Take care when changing a released module.
2607 Always strive to remain compatible with previous released versions.
2608 Otherwise try to add a mechanism to revert to the
2609 old behavior if people rely on it. Document incompatible changes.
2615 =head2 Guidelines for Converting Perl 4 Library Scripts into Modules
2621 There is no requirement to convert anything.
2623 If it ain't broke, don't fix it! Perl 4 library scripts should
2624 continue to work with no problems. You may need to make some minor
2625 changes (like escaping non-array @'s in double quoted strings) but
2626 there is no need to convert a .pl file into a Module for just that.
2630 Consider the implications.
2632 All Perl applications that make use of the script will need to
2633 be changed (slightly) if the script is converted into a module. Is
2634 it worth it unless you plan to make other changes at the same time?
2638 Make the most of the opportunity.
2640 If you are going to convert the script to a module you can use the
2641 opportunity to redesign the interface. The guidelines for module
2642 creation above include many of the issues you should consider.
2646 The pl2pm utility will get you started.
2648 This utility will read *.pl files (given as parameters) and write
2649 corresponding *.pm files. The pl2pm utilities does the following:
2655 Adds the standard Module prologue lines
2659 Converts package specifiers from ' to ::
2663 Converts die(...) to croak(...)
2667 Several other minor changes
2671 Being a mechanical process pl2pm is not bullet proof. The converted
2672 code will need careful checking, especially any package statements.
2673 Don't delete the original .pl file till the new .pm one works!
2677 =head2 Guidelines for Reusing Application Code
2683 Complete applications rarely belong in the Perl Module Library.
2687 Many applications contain some Perl code that could be reused.
2689 Help save the world! Share your code in a form that makes it easy
2694 Break-out the reusable code into one or more separate module files.
2698 Take the opportunity to reconsider and redesign the interfaces.
2702 In some cases the 'application' can then be reduced to a small
2704 fragment of code built on top of the reusable modules. In these cases
2705 the application could invoked as:
2707 % perl -e 'use Module::Name; method(@ARGV)' ...
2709 % perl -mModule::Name ... (in perl5.002 or higher)
2715 Perl does not enforce private and public parts of its modules as you may
2716 have been used to in other languages like C++, Ada, or Modula-17. Perl
2717 doesn't have an infatuation with enforced privacy. It would prefer
2718 that you stayed out of its living room because you weren't invited, not
2719 because it has a shotgun.
2721 The module and its user have a contract, part of which is common law,
2722 and part of which is "written". Part of the common law contract is
2723 that a module doesn't pollute any namespace it wasn't asked to. The
2724 written contract for the module (A.K.A. documentation) may make other
2725 provisions. But then you know when you C<use RedefineTheWorld> that
2726 you're redefining the world and willing to take the consequences.