public class OperandArray extends Object
Constructor and Description |
---|
OperandArray(Expression parent,
Expression[] args) |
OperandArray(Expression parent,
Expression[] args,
OperandRole role) |
OperandArray(Expression parent,
Expression[] args,
OperandRole[] roles) |
Modifier and Type | Method and Description |
---|---|
int |
getNumberOfOperands()
Get the number of operands in the operand array
|
Operand |
getOperand(int n)
Get the operand whose identifying number is n.
|
Expression |
getOperandExpression(int n)
Get the child expression associated with the operand whose identifying number is n.
|
OperandRole[] |
getRoles()
Get the operand roles
|
Iterable<Expression> |
operandExpressions() |
Iterable<Operand> |
operands()
Return a collection containing all the operands.
|
void |
setOperand(int n,
Expression child)
Set the value of the operand with integer n.
|
public OperandArray(Expression parent, Expression[] args)
public OperandArray(Expression parent, Expression[] args, OperandRole[] roles)
public OperandArray(Expression parent, Expression[] args, OperandRole role)
public OperandRole[] getRoles()
public Operand getOperand(int n)
n
- the identifier of the operandIllegalArgumentException
- if there cannot be an operand at this positionpublic Expression getOperandExpression(int n)
n
- the identifier of the operandIllegalArgumentException
- if there cannot be an operand at this positionpublic Iterable<Operand> operands()
public Iterable<Expression> operandExpressions()
public void setOperand(int n, Expression child)
n
- identifies the expression to be set/replacedchild
- the new subexpressionIllegalArgumentException
- if the value of n identifies no operandpublic int getNumberOfOperands()
Copyright (c) 2004-2014 Saxonica Limited. All rights reserved.