NAME
Perldoc - Perl Documentation Tools
SYNOPSIS
my $doc = Perldoc->new( type => "POD", input => "source.pod" );
# simple conversions;
my $html = $doc->to_html;
# DOM-style interface; see Perldoc::DOM for more;
my $dom = $doc->to_dom;
# event-style interface;
my $filter = Perldoc::Filter->new();
$doc->add_filter($filter);
my $writer = Perldoc::Writer::XML->new( output => "out.xml" );
$doc->final_sender->receiver($writer);
# run conversion!
$doc->send_all;
DESCRIPTION
Perldoc
is a set of tools that define and work with the Perldoc Information Model. The tools will eventally provide parsers for various Perldoc Dialects (including Pod and Kwid), and formatters for various output formats.
The Perldoc
class, on the other hand, is an object which simultaneously can behave like a:
Perldoc::Reader
- it can, minimally, be passed a specification of a stream source to read and pass you pack characters or blocks or whatever.Perldoc::Parser
- it can also perform the task of converting said characters or blocks into a parsed tree, which might involve loading a seperate dialect parser, or any of the other weird and wonderful things thatPerldoc::Parser
is capable of.Perldoc::DOM
- you can call all of the parsed-state DOM methods on it, and it will parse the entire document and then call the methodPerldoc::Sender
- you can get Perldoc serial events out of a Perldoc object, before or after parsing!Perldoc::Receiver
- you can use thePerldoc
object as a target for events, and let it pass them through to a destination and/or build a DOM tree.
For more details about what each component involves, and the calling convention, see the relevant documentation for the module.
= AUTHORS
* Brian Ingerson <ingy@cpan.org> * Sam Vilain <samv@cpan.org>
= COPYRIGHT
Copyright (c) 2005, Brian Ingerson, Sam Vilain. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See http://www.perl.com/perl/misc/Artistic.html