public class ASTLinkedList extends java.lang.Object implements ASTIterator
Modifier and Type | Field and Description |
---|---|
private ASTNode |
current |
private ASTNode |
firstASTNode |
private ASTNode |
last |
private int |
size |
Constructor and Description |
---|
ASTLinkedList() |
ASTLinkedList(ASTIterator iter) |
ASTLinkedList(ASTNode firstASTNode) |
ASTLinkedList(ASTNode firstASTNode,
int size) |
Modifier and Type | Method and Description |
---|---|
void |
addTokenNode(ASTNode astNode) |
void |
addTokenNode(ASTNode astNode,
ASTNode token2) |
void |
back() |
void |
finish() |
ASTNode |
firstNode() |
ASTNode |
firstNonSymbol() |
boolean |
hasMoreNodes() |
int |
index() |
boolean |
isSingleNode() |
ASTNode |
nextNode() |
ASTNode |
nodesAhead(int offset) |
ASTNode |
nodesBack(int offset) |
ASTNode |
peekLast() |
ASTNode |
peekNext() |
ASTNode |
peekNode() |
void |
removeToken() |
void |
reset() |
void |
setCurrentNode(ASTNode node) |
java.lang.String |
showNodeChain() |
int |
size() |
void |
skipNode() |
private ASTNode firstASTNode
private ASTNode current
private ASTNode last
private int size
public ASTLinkedList()
public ASTLinkedList(ASTIterator iter)
public ASTLinkedList(ASTNode firstASTNode)
public ASTLinkedList(ASTNode firstASTNode, int size)
public void addTokenNode(ASTNode astNode)
addTokenNode
in interface ASTIterator
public void addTokenNode(ASTNode astNode, ASTNode token2)
addTokenNode
in interface ASTIterator
public ASTNode firstNode()
firstNode
in interface ASTIterator
public boolean isSingleNode()
public ASTNode firstNonSymbol()
public void reset()
reset
in interface ASTIterator
public boolean hasMoreNodes()
hasMoreNodes
in interface ASTIterator
public ASTNode nextNode()
nextNode
in interface ASTIterator
public void skipNode()
skipNode
in interface ASTIterator
public ASTNode peekNext()
peekNext
in interface ASTIterator
public ASTNode peekNode()
peekNode
in interface ASTIterator
public void removeToken()
public ASTNode peekLast()
peekLast
in interface ASTIterator
public ASTNode nodesBack(int offset)
nodesBack
in interface ASTIterator
public ASTNode nodesAhead(int offset)
nodesAhead
in interface ASTIterator
public void back()
back
in interface ASTIterator
public java.lang.String showNodeChain()
showNodeChain
in interface ASTIterator
public int size()
size
in interface ASTIterator
public int index()
index
in interface ASTIterator
public void setCurrentNode(ASTNode node)
public void finish()
finish
in interface ASTIterator