jd.xml.xslt.expr
Class TextContentExpression

java.lang.Object
  extended byjd.xml.xpath.expr.ExpressionImpl
      extended byjd.xml.xpath.expr.NodeSetExpression
          extended byjd.xml.xslt.expr.TextContentExpression
All Implemented Interfaces:
Expression

public class TextContentExpression
extends NodeSetExpression

A NodeSet constructed by the template of a variable binding element. It consists of a single root node having a single text node as child.


Field Summary
 
Fields inherited from interface jd.xml.xpath.expr.Expression
DEP_CONTEXT_NODE, DEP_CONTEXT_POSITION, DEP_CONTEXT_SIZE, DEP_CONTEXT_STATIC, DEP_NONE, DEP_UNKNOWN
 
Constructor Summary
TextContentExpression(String text)
           
 
Method Summary
 void accept(ExpressionVisitor visitor)
          Accept a ExpressionVisitor.
 int getContextDependencies()
          Return a bitfield indicating the expression dependencies on the XPath context.
 int getMaxResultSize()
          Return the maximum size of the returned NodeSet or 0 if not known.
 int getMinResultSize()
          Return the minimum size of the returned NodeSet or 0 if not known.
 boolean toBooleanValue(XPathContext context)
          Evaluate the Expression to a boolean.
 XNodeSet toNodeSet(XPathContext context, int nodeSetOrdering)
          Evaluate the Expression to a XObject and convert to a XNodeSet.
 double toNumberValue(XPathContext context)
          Evaluate the Expression to a number.
 String toStringValue(XPathContext context)
          Evaluate the Expression to a String.
 
Methods inherited from class jd.xml.xpath.expr.NodeSetExpression
canCreateModelWalker, getMaxResultSize, getMinResultSize, getModelWalker, getResultType, toXObject
 
Methods inherited from class jd.xml.xpath.expr.ExpressionImpl
hasContextDependencies, isUniqueFilter, matchesFilter, toNode, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TextContentExpression

public TextContentExpression(String text)
Method Detail

toNumberValue

public double toNumberValue(XPathContext context)
Description copied from class: NodeSetExpression
Evaluate the Expression to a number.

Specified by:
toNumberValue in interface Expression
Overrides:
toNumberValue in class NodeSetExpression

toStringValue

public String toStringValue(XPathContext context)
Description copied from class: NodeSetExpression
Evaluate the Expression to a String.

Specified by:
toStringValue in interface Expression
Overrides:
toStringValue in class NodeSetExpression

toBooleanValue

public boolean toBooleanValue(XPathContext context)
Description copied from class: NodeSetExpression
Evaluate the Expression to a boolean.

Specified by:
toBooleanValue in interface Expression
Overrides:
toBooleanValue in class NodeSetExpression

toNodeSet

public XNodeSet toNodeSet(XPathContext context,
                          int nodeSetOrdering)
Description copied from class: ExpressionImpl
Evaluate the Expression to a XObject and convert to a XNodeSet.

Specified by:
toNodeSet in interface Expression
Overrides:
toNodeSet in class ExpressionImpl

getMaxResultSize

public int getMaxResultSize()
Description copied from class: NodeSetExpression
Return the maximum size of the returned NodeSet or 0 if not known. The default implementation returns 0.

Overrides:
getMaxResultSize in class NodeSetExpression

getMinResultSize

public int getMinResultSize()
Description copied from class: NodeSetExpression
Return the minimum size of the returned NodeSet or 0 if not known. The default implementation returns 0.

Overrides:
getMinResultSize in class NodeSetExpression

getContextDependencies

public int getContextDependencies()
Description copied from interface: Expression
Return a bitfield indicating the expression dependencies on the XPath context.


accept

public void accept(ExpressionVisitor visitor)
Description copied from interface: Expression
Accept a ExpressionVisitor.