From: Ilya M. <m_...@us...> - 2003-03-26 16:19:49
|
Update of /cvsroot/perl-xml/XML-LibXML-XPathContext In directory sc8-pr-cvs1:/tmp/cvs-serv4701 Modified Files: XPathContext.pm Log Message: Fix links in POD Index: XPathContext.pm =================================================================== RCS file: /cvsroot/perl-xml/XML-LibXML-XPathContext/XPathContext.pm,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- XPathContext.pm 26 Mar 2003 15:26:48 -0000 1.11 +++ XPathContext.pm 26 Mar 2003 16:19:42 -0000 1.12 @@ -144,10 +144,11 @@ =head1 DESCRIPTION -This module augments XML::LibXML by providing Perl interface to -libxml2's xmlXPathContext structure. Besides just performing xpath -statements on XML::LibXML's node trees it allows redefining certaint -aspects of XPath engine. This modules allows +This module augments L<XML::LibXML|XML::LibXML> by providing Perl +interface to libxml2's xmlXPathContext structure. Besides just +performing xpath statements on L<XML::LibXML|XML::LibXML>'s node trees +it allows redefining certaint aspects of XPath engine. This modules +allows =over 4 @@ -229,8 +230,8 @@ =item B<new($node)> -Creates a new XML::LibXML::XPathContext object with current node set -to I<$node>. +Creates a new XML::LibXML::XPathContext object with current node +set to I<$node>. =item B<registerNs($prefix, $namespace_uri)> @@ -242,11 +243,11 @@ is executed by the XPath engine each time an XPath variable is evaluated. It takes three arguments: I<$data>, variable name, and variable ns-URI and must return one value: a number or string or any -XML::LibXML object that can be a result of findnodes: Boolean, -Literal, Number, Node (e.g. Document, Element, etc.), or NodeList. -For convenience, simple (non-blessed) array references containing only -XML::LibXML::Node objects can be used instead of a -XML::LibXML::NodeList. +L<XML::LibXML|XML::LibXML> object that can be a result of findnodes: +Boolean, Literal, Number, Node (e.g. Document, Element, etc.), or +NodeList. For convenience, simple (non-blessed) array references +containing only L<XML::LibXML::Node|XML::LibXML::Node> objects can be +used instead of a L<XML::LibXML::NodeList|XML::LibXML::NodeList>. =item B<getVarLookupData()> @@ -261,17 +262,19 @@ Registers an extension function I<$name> in I<$uri> namespace. I<$callback> must be a CODE reference. The arguments of the -callback function are either simple scalars or XML::LibXML::NodeList -objects depending on the XPath argument types. The function is -responsible for checking the argument number and types. Result of the -callback code must be a single value of the following types: a simple -scalar (number,string) or an arbitrary XML::LibXML object that can be -a result of findnodes: Boolean, Literal, Number, Node (e.g. Document, -Element, etc.), or NodeList. For convenience, simple (non-blessed) -array references containing only XML::LibXML::Node objects can be used -instead of a XML::LibXML::NodeList. +callback function are either simple scalars or +L<XML::LibXML::NodeList|XML::LibXML::NodeList> objects depending on +the XPath argument types. The function is responsible for checking the +argument number and types. Result of the callback code must be a +single value of the following types: a simple scalar (number,string) +or an arbitrary L<XML::LibXML|XML::LibXML> object that can be a result +of findnodes: Boolean, Literal, Number, Node (e.g. Document, Element, +etc.), or NodeList. For convenience, simple (non-blessed) array +references containing only L<XML::LibXML::Node|XML::LibXML::Node> +objects can be used instead of a +L<XML::LibXML::NodeList|XML::LibXML::NodeList>. -=item B<registerFunctionNS($name, $uri)> +=item B<unregisterFunctionNS($name, $uri)> Unregisters extension function I<$name> in I<$uri> namespace. Has the same effect as passing C<undef> as I<$callback> to registerFunctionNS. @@ -289,17 +292,19 @@ Performs the xpath statement on the current node and returns the result as an array. In scalar context returns a -L<XML::LibXML::NodeList> object. +L<XML::LibXML::NodeList|XML::LibXML::NodeList> object. =item B<find($xpath)> Performs the xpath expression using the current node as the context of the expression, and returns the result depending on what type of result the XPath expression had. For example, the XPath C<1 * 3 + 52> -results in a L<XML::LibXML::Number> object being returned. Other -expressions might return a L<XML::LibXML::Boolean> object, or a -L<XML::LibXML::Literal> object (a string). Each of those objects uses -Perl's overload feature to "do the right thing" in different contexts. +results in a L<XML::LibXML::Number|XML::LibXML::Number> object being +returned. Other expressions might return a +L<XML::LibXML::Boolean|XML::LibXML::Boolean> object, or a +L<XML::LibXML::Literal|XML::LibXML::Literal> object (a string). Each +of those objects uses Perl's overload feature to "do the right thing" +in different contexts. =item B<findvalue($xpath)> @@ -324,10 +329,10 @@ =head1 BUGS AND CAVEATS -L<XML::LibXML::XPathContext> objects are not reentrant. It means you -cannot register a Perl function with a L<XML::LibXML::XPathContext> +XML::LibXML::XPathContext objects are not reentrant. It means you +cannot register a Perl function with a XML::LibXML::XPathContext object if this Perl function uses itself the same -L<XML::LibXML::XPathContext> object internally. +XML::LibXML::XPathContext object internally. For example, the following code will not work: @@ -337,8 +342,8 @@ =head1 AUTHORS -Based on L<XML::LibXML> and L<XML::XSLT> code by Matt Sergeant and -Christian Glahn. +Based on L<XML::LibXML|XML::LibXML> and L<XML::XSLT|XML::XSLT> code by +Matt Sergeant and Christian Glahn. Maintained by Ilya Martynov and Petr Pajas. @@ -354,6 +359,6 @@ =head1 SEE ALSO -L<XML::LibXML>, L<XML::XSLT> +L<XML::LibXML|XML::LibXML>, L<XML::XSLT|XML::XSLT> =cut |