public class MDiff extends PostfixMathCommand implements SpecialPreProcessorI
Constructor and Description |
---|
MDiff() |
Modifier and Type | Method and Description |
---|---|
MatrixNodeI |
preprocess(ASTFunNode node,
MatrixPreprocessor visitor,
MatrixJep jep,
MatrixNodeFactory nf)
Subverts the preprocessing stage.
|
checkNumberOfParameters, getNumberOfParameters, run, setCurNumberOfParameters
public MatrixNodeI preprocess(ASTFunNode node, MatrixPreprocessor visitor, MatrixJep jep, MatrixNodeFactory nf) throws ParseException
SpecialPreProcessorI
MatrixNodeI children[] = visitor.visitChildrenAsArray(node,null);The final step is to construct a node of the correct type. The MatrixNodeFactory argument has a number of methods to do this. For example
return (ASTMFunNode) nf.buildOperatorNode(node.getOperator(),children,rhsDim);Note how the dimension is specified.
preprocess
in interface SpecialPreProcessorI
node
- the top node of the tree representing the function and its arguments.visitor
- A reference to the preprocessing visitor.jep
- A reference of the MatrixJep instance.nf
- A reference to the node factory object.ParseException
- if some error occurs.Jas4pp 1.5 © Java Analysis Studio for Particle Physics