Perl Diver 2.31
Main Environment Variables Perl Default Values Perl Config - Summary Perl Config - Full Installed Modules List Directory uptime Docs

Module Documentation
Details and documentation about a specific module, including version and documentation (if available). Note that while links to perldoc.com and search.cpan.org are provided, the module may be part of a larger distribution. If you reach a File Not Found page on either site, please try the parent module.

XML::SAX::ParserFactory

Name XML::SAX::ParserFactory
Version 1.01
Located at /usr/share/perl5/vendor_perl
File /usr/share/perl5/vendor_perl/XML/SAX/ParserFactory.pm
Is Core No
Search CPAN for this module XML::SAX::ParserFactory
Documentation XML::SAX::ParserFactory
Module Details XML::SAX::ParserFactory

NAME

XML::SAX::ParserFactory - Obtain a SAX parser


SYNOPSIS

  use XML::SAX::ParserFactory;
  use XML::SAX::XYZHandler;
  my $handler = XML::SAX::XYZHandler->new();
  my $p = XML::SAX::ParserFactory->parser(Handler => $handler);
  $p->parse_uri("foo.xml");
  # or $p->parse_string("<foo/>") or $p->parse_file($fh);


DESCRIPTION

XML::SAX::ParserFactory is a factory class for providing an application with a Perl SAX2 XML parser. It is akin to DBI - a front end for other parser classes. Each new SAX2 parser installed will register itself with XML::SAX, and then it will become available to all applications that use XML::SAX::ParserFactory to obtain a SAX parser.

Unlike DBI however, XML/SAX parsers almost all work alike (especially if they subclass XML::SAX::Base, as they should), so rather than specifying the parser you want in the call to parser(), XML::SAX has several ways to automatically choose which parser to use:


AUTHOR

Matt Sergeant, matt@sergeant.org


LICENSE

This is free software, you may use it and distribute it under the same terms as Perl itself.

Perl Diver brought to you by ScriptSolutions.com © 1997- 2024