1Tree::XPathEngine::LiteUrsaelr(3C)ontributed Perl DocumeTnrteaet:i:oXnPathEngine::Literal(3)
2
3
4

NAME

6       Tree::XPathEngine::Literal - Simple string values.
7

DESCRIPTION

9       In XPath terms a Literal is what we know as a string.
10

API

12   new($string)
13       Create a new Literal object with the value in $string. Note that "
14       and ' will be converted to " and ' respectively. That is not part
15       of the XPath specification, but I consider it useful. Note though that
16       you have to go to extraordinary lengths in an XML template file (be it
17       XSLT or whatever) to make use of this:
18
19               <xsl:value-of select="&quot;I'm feeling &amp;quot;sad&amp;quot;&quot;"/>
20
21       Which produces a Literal of:
22
23               I'm feeling "sad"
24
25   value()
26       Also overloaded as stringification, simply returns the literal string
27       value.
28
29   xpath_cmp($literal)
30       Returns the equivalent of perl's cmp operator against the given
31       $literal.
32
33   Other Methods
34       Those are needed so the objects can be properly processed in various
35       contexts
36
37       as_string
38       as_xml
39       value
40       evaluate
41       xpath_to_boolean
42       xpath_to_literal
43       xpath_to_number
44       xpath_string_value
45
46
47
48perl v5.36.0                      2023-01-20     Tree::XPathEngine::Literal(3)
Impressum