xml::sax::documentlocator(3) suse man page | unix.com

Man Page: xml::sax::documentlocator

Operating Environment: suse

Section: 3

SAX::DocumentLocator(3) 				User Contributed Perl Documentation				   SAX::DocumentLocator(3)

NAME
XML::SAX::DocumentLocator - Helper class for document locators
SYNOPSIS
my $locator = XML::SAX::DocumentLocator->new( sub { $object->get_public_id }, sub { $object->get_system_id }, sub { $reader->current_line }, sub { $reader->current_column }, sub { $reader->get_encoding }, sub { $reader->get_xml_version }, );
DESCRIPTION
This module gives you a tied hash reference that calls the specified closures when asked for PublicId, SystemId, LineNumber and ColumnNumber. It is useful for writing SAX Parsers so that you don't have to constantly update the line numbers in a hash reference on the object you pass to set_document_locator(). See the source code for XML::SAX::PurePerl for a usage example.
API
There is only 1 method: "new". Simply pass it a list of closures that when called will return the PublicId, the SystemId, the LineNumber, the ColumnNumber, the Encoding and the XMLVersion respectively. The closures are passed a single parameter, the key being requested. But you're free to ignore that. perl v5.12.1 2005-10-14 SAX::DocumentLocator(3)
Related Man Pages
xml::sax::exception5.18(3) - mojave
xml::sax2perl(3) - suse
xml::sax2perl(3) - redhat
xml::libxml::sax::builder(3) - mojave
xml::sax::exception5.16(3) - osx
Similar Topics in the Unix Linux Community
Getting command output to putty window title.
Migrating to UNIX
Update kernel Linux without reboot?!
SOCKS proxy & PAM configuration exposure
A (ksh) Library For and From UNIX.com