org.lsmp.djep.xjep
Class DeepCopyVisitor
java.lang.Object
org.lsmp.djep.xjep.DoNothingVisitor
org.lsmp.djep.xjep.DeepCopyVisitor
- All Implemented Interfaces:
- ParserVisitor
- Direct Known Subclasses:
- DifferentiationVisitor
public class DeepCopyVisitor
- extends DoNothingVisitor
- implements ParserVisitor
A Visitor which returns an exact copy of the tree.
This class should be extended by visitors which
modify trees and creates a new tree.
- Author:
- Rich Morris
Created on 16-Nov-2003
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DeepCopyVisitor
public DeepCopyVisitor()
deepCopy
public Node deepCopy(Node node,
XJep xj)
throws ParseException
- Creates a deepCopy of a Node
- Throws:
ParseException
visit
public java.lang.Object visit(ASTConstant node,
java.lang.Object data)
throws ParseException
- Specified by:
visit
in interface ParserVisitor
- Overrides:
visit
in class DoNothingVisitor
- Throws:
ParseException
visit
public java.lang.Object visit(ASTVarNode node,
java.lang.Object data)
throws ParseException
- Specified by:
visit
in interface ParserVisitor
- Overrides:
visit
in class DoNothingVisitor
- Throws:
ParseException
visit
public java.lang.Object visit(ASTFunNode node,
java.lang.Object data)
throws ParseException
- Specified by:
visit
in interface ParserVisitor
- Overrides:
visit
in class DoNothingVisitor
- Throws:
ParseException
http://www.singularsys.com/jep Copyright © 2007 Singular Systems