Perl module
A Perl module is a discrete component of software for the Perl programming language. A modulea is distinguished by a unique namespace, e.g. "CGI" or "Net::FTP" or "XML::Parser". By conventions, there is typically one module per file with a .pm extension. A collection of one or more modules, with accompanying documentation and build scripts, compose a package. The Perl community has a sizable library of packages available for search and download via CPAN.
It is common for Perl modules to have embedded documentation. Many modules favor an object-oriented style, but many are procedural instead, especially old modules.
Below is an example of a very simple object-oriented Perl module and a short program which makes use of the module.
Hello/World.pm
package Hello::World; our $VERSION = "1.0"; sub new { my $pkg = shift; my $self = bless({ message => "Hello, world!", }, $pkg); return $self; } sub