95 lines
2.0 KiB
HTML
95 lines
2.0 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of XML::XPathEngine::Literal</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>XML::XPathEngine::Literal</H1>
|
|
Section: User Contributed Perl Documentation (3pm)<BR>Updated: 2018-01-01<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
XML::XPathEngine::Literal - Simple string values.
|
|
<A NAME="lbAC"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
|
|
|
|
In XPath terms a Literal is what we know as a string.
|
|
<A NAME="lbAD"> </A>
|
|
<H2>API</H2>
|
|
|
|
|
|
|
|
<A NAME="lbAE"> </A>
|
|
<H3>new($string)</H3>
|
|
|
|
|
|
|
|
Create a new Literal object with the value in <TT>$string</TT>. Note that &quot; and
|
|
&apos; will be converted to " and ' respectively. That is not part of the XPath
|
|
specification, but I consider it useful. Note though that you have to go
|
|
to extraordinary lengths in an <FONT SIZE="-1">XML</FONT> template file (be it <FONT SIZE="-1">XSLT</FONT> or whatever) to
|
|
make use of this:
|
|
<P>
|
|
|
|
|
|
|
|
<PRE>
|
|
<xsl:value-of select="&quot;I'm feeling &amp;quot;sad&amp;quot;&quot;"/>
|
|
|
|
</PRE>
|
|
|
|
|
|
<P>
|
|
|
|
Which produces a Literal of:
|
|
<P>
|
|
|
|
|
|
|
|
<PRE>
|
|
I'm feeling "sad"
|
|
|
|
</PRE>
|
|
|
|
|
|
<A NAME="lbAF"> </A>
|
|
<H3><I>value()</I></H3>
|
|
|
|
|
|
|
|
Also overloaded as stringification, simply returns the literal string value.
|
|
<A NAME="lbAG"> </A>
|
|
<H3>cmp($literal)</H3>
|
|
|
|
|
|
|
|
Returns the equivalent of perl's cmp operator against the given <TT>$literal</TT>.
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="1"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="2"><A HREF="#lbAC">DESCRIPTION</A><DD>
|
|
<DT id="3"><A HREF="#lbAD">API</A><DD>
|
|
<DL>
|
|
<DT id="4"><A HREF="#lbAE">new($string)</A><DD>
|
|
<DT id="5"><A HREF="#lbAF"><I>value()</I></A><DD>
|
|
<DT id="6"><A HREF="#lbAG">cmp($literal)</A><DD>
|
|
</DL>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:06:01 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|