public class ContainerNode extends TreeNode implements IContainerNode
IContainerNode.ContainerType
Modifier and Type | Field and Description |
---|---|
static ContainerNode |
EMPTY_CONTAINER |
emptyNodeArray, parent
UNKNOWN
Constructor and Description |
---|
ContainerNode()
Constructor.
|
ContainerNode(int size)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addItem(NodeBase child)
Adds a node to the list of children (really just a public wrapper around
addChild)
|
void |
addItemAfterNormalization(NodeBase child)
Adds a node to the list of children (really just a public wrapper around
addChild)
|
void |
addTemporaryItem(NodeBase child)
Adds a node to the list of children WITHOUT changing their real parent.
|
protected boolean |
buildInnerString(StringBuilder sb)
For debugging only.
|
boolean |
contains(int offset)
Determine whether the offset fits within this node.
|
IContainerNode.ContainerType |
getContainerType()
Returns the type of the container that his node represents
|
ASTNodeID |
getNodeID()
Get the opcode of this node
|
boolean |
getRemovedConditionalCompileNode() |
void |
removeItem(NodeBase child)
Removes a node in the list of children (wrapper around removeChild)
|
void |
removeTemporaryItem(NodeBase child)
Removes a node from the list of children WITHOUT changing their real
parent.
|
void |
setContainerType(IContainerNode.ContainerType containerType) |
void |
setRemovedConditionalCompileNode(boolean value) |
addChild, addChild, addChildInOrder, addChildPostNormalize, addTemporaryChild, getChild, getChildCount, getInitialChildCount, normalize, optimizeChildren, removeAllChildren, removeChild, removeTemporaryChild, replaceChild, sortChildren, swapChildren
analyze, buildStringRecursive, canContinueContainmentSearch, collectImportNodes, combineAttributes, connectedToProjectScope, endAfter, endAfter, endBefore, endBefore, fillInOffsets, getAbsoluteEnd, getAbsoluteStart, getAncestorOfType, getASScope, getContainingFilePath, getContainingNode, getContainingScope, getEnd, getFileScope, getFileSpecification, getInnerString, getNodeKind, getPackageName, getParent, getScopeNode, getSpanningStart, getStart, getSucceedingNode, getWorkspace, isTerminal, isTransparent, looselyContains, runPostProcess, setChildren, setParent, span, span, span, startAfter, startAfter, startBefore, startBefore, toString, tryGetOffsetLookup, verify
getColumn, getEndColumn, getEndLine, getLine, getLineColumnString, getOffsetsString, getSourcePath, getSourcePathString, setColumn, setEnd, setEndColumn, setEndLine, setLine, setSourceLocation, setSourcePath, setStart, span, span
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getAncestorOfType, getChild, getChildCount, getContainingNode, getContainingScope, getFileSpecification, getPackageName, getParent, getSpanningStart, getSucceedingNode, isTerminal
getAbsoluteEnd, getAbsoluteStart, getColumn, getEnd, getEndColumn, getEndLine, getLine, getSourcePath, getStart
public static final ContainerNode EMPTY_CONTAINER
public ContainerNode()
public ContainerNode(int size)
size
- The initial size of the array containing the children.public ASTNodeID getNodeID()
IASNode
public boolean contains(int offset)
IASNode
protected boolean buildInnerString(StringBuilder sb)
NodeBase
buildOuterString()
.
It is overridden by subclasses to display optional node-specific
information in the middle of the string, between the node type and the
location information.buildInnerString
in class NodeBase
public IContainerNode.ContainerType getContainerType()
IContainerNode
getContainerType
in interface IContainerNode
IContainerNode.ContainerType
or nullpublic void setContainerType(IContainerNode.ContainerType containerType)
public boolean getRemovedConditionalCompileNode()
public void setRemovedConditionalCompileNode(boolean value)
public void addItem(NodeBase child)
child
- new child nodepublic void addItemAfterNormalization(NodeBase child)
child
- new child nodepublic void addTemporaryItem(NodeBase child)
child
- new child nodepublic void removeItem(NodeBase child)
public void removeTemporaryItem(NodeBase child)
child
- new child nodeCopyright © 2016 The Apache Software Foundation. All rights reserved.