public abstract class UnaryOperation extends Expression implements ExpressionOwner
| Constructor and Description |
|---|
UnaryOperation() |
| Modifier and Type | Method and Description |
|---|---|
void |
callVisitors(ExpressionOwner owner,
XPathVisitor visitor)
This will traverse the heararchy, calling the visitor for
each member.
|
boolean |
canTraverseOutsideSubtree()
Tell if this expression or it's subexpressions can traverse outside
the current subtree.
|
boolean |
deepEquals(Expression expr)
Compare this object with another object and see
if they are equal, include the sub heararchy.
|
XObject |
execute(XPathContext xctxt)
Execute the operand and apply the unary operation to the result.
|
void |
fixupVariables(java.util.Vector vars,
int globalsSize)
This function is used to fixup variables from QNames to stack frame
indexes at stylesheet build time.
|
Expression |
getExpression()
Get the raw Expression object that this class wraps.
|
Expression |
getOperand() |
abstract XObject |
operate(XObject right)
Apply the operation to two operands, and return the result.
|
void |
setExpression(Expression exp)
Set the raw expression object for this object.
|
void |
setRight(Expression r)
Set the expression operand for the operation.
|
asIterator, asIteratorRaw, asNode, assertion, bool, error, execute, execute, execute, executeCharsToContentHandler, exprAddChild, exprGetChild, exprGetNumChildren, exprGetParent, exprSetParent, getColumnNumber, getExpressionOwner, getLineNumber, getPublicId, getSystemId, isNodesetExpr, isStableNumber, num, warn, xstrpublic void fixupVariables(java.util.Vector vars,
int globalsSize)
fixupVariables in class Expressionvars - List of QNames that correspond to variables. This list
should be searched backwards for the first qualified name that
corresponds to the variable reference qname. The position of the
QName in the vector from the start of the vector will be its position
in the stack frame (but variables above the globalsTop value will need
to be offset to the current stack frame).public boolean canTraverseOutsideSubtree()
canTraverseOutsideSubtree in class Expressionpublic void setRight(Expression r)
r - The expression operand to which the unary operation will be
applied.public XObject execute(XPathContext xctxt) throws TransformerException
execute in class Expressionxctxt - The runtime execution context.TransformerExceptionpublic abstract XObject operate(XObject right) throws TransformerException
right - non-null reference to the evaluated right operand.TransformerExceptionpublic Expression getOperand()
public void callVisitors(ExpressionOwner owner, XPathVisitor visitor)
XPathVisitablecallVisitors in interface XPathVisitableowner - The owner of the visitor, where that path may be
rewritten if needed.visitor - The visitor whose appropriate method will be called.XPathVisitable.callVisitors(ExpressionOwner, XPathVisitor)public Expression getExpression()
ExpressionOwnergetExpression in interface ExpressionOwnerExpressionOwner.getExpression()public void setExpression(Expression exp)
ExpressionOwnersetExpression in interface ExpressionOwnerexp - the raw Expression object, which should not normally be null.ExpressionOwner.setExpression(Expression)public boolean deepEquals(Expression expr)
ExpressiondeepEquals in class Expressionexpr - Another expression object.Expression.deepEquals(Expression)Copyright © 2014 Apache XML Project. All Rights Reserved.