Chapter 3
The best way to learn POD is by example it's just too simple to be worth a lot 
of complicated explanation. Here's the start of some POD docs for BOA::Logger, 
the example module in the last chapter:
=pod
=head1 NAME
BOA::Logger   provides logging for the Big Ol  Application
=head1 SYNOPSIS
    my $logger = BOA::Logger >new("log_file");  # get new logger object
    $logger >level(10);                         # set log level to 10
    $logger >write(1, "Hello log!");            # write a line at log level 1
=head1 DESCRIPTION
BOA::Logger is an object oriented class that provides access to a log file
with an associated log level.  Users of the module create a new BOA::Logger
object with the new() method.  The level() method is used to set the log level
and the write() method is used to write lines to the log file.
=head1 AUTHOR
Sam Tregar 
=head1 SEE ALSO
L
=cut
As you can see in this example, the =head1 command declares a top level heading 
(=head2 is also available to create subheadings). Also notice the indenting for the 
code example in the SYNOPSIS section. This creates a verbatim paragraph without 
the indenting the POD formatter would wreck the spacing and render the code 
unreadable. See Figure 3 1 for the output from running pod2html on the POD.
68






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

web hosting perl

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved