org.eclipse.cdt.ui.tests.DOMAST
Class DOMASTNodeParent
java.lang.Object
org.eclipse.cdt.ui.tests.DOMAST.DOMASTNodeLeaf
org.eclipse.cdt.ui.tests.DOMAST.DOMASTNodeParent
- All Implemented Interfaces:
- org.eclipse.core.runtime.IAdaptable
public class DOMASTNodeParent
- extends DOMASTNodeLeaf
- Author:
- dsteffle
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DOMASTNodeParent
public DOMASTNodeParent()
DOMASTNodeParent
public DOMASTNodeParent(org.eclipse.cdt.core.dom.ast.IASTNode node)
getStartSearch
public int getStartSearch()
addChild
public void addChild(DOMASTNodeLeaf child)
removeChild
public void removeChild(DOMASTNodeLeaf child)
getChildren
public DOMASTNodeLeaf[] getChildren(boolean cleanupElements)
getChildren
public DOMASTNodeLeaf[] getChildren()
insert
public java.lang.Object[] insert(java.lang.Class c,
java.lang.Object[] array,
java.lang.Object obj,
int pos)
- Inserts obj into the array at position pos and if this is not possible (due to a bad offset)
then the obj is just appended to the end of the array.
- Parameters:
c
- array
- obj
- pos
-
- Returns:
cleanChildren
public void cleanChildren()
hasChildren
public boolean hasChildren()
findTreeParentForMergedNode
public DOMASTNodeParent findTreeParentForMergedNode(org.eclipse.cdt.core.dom.ast.IASTNode node)
- Returns the DOMASTNodeParent whose IASTNode is the parent of the IASTNode.
This function is an optimization function used to only search merged preprocessor nodes.
- Parameters:
node
-
- Returns:
findTreeParentForNode
public DOMASTNodeParent findTreeParentForNode(org.eclipse.cdt.core.dom.ast.IASTNode node)
- Returns the DOMASTNodeParent whose IASTNode is the parent of the IASTNode.
- Parameters:
node
-
- Returns:
relativeNodePosition
public int relativeNodePosition(org.eclipse.cdt.core.dom.ast.IASTNode n)
- Overrides:
relativeNodePosition
in class DOMASTNodeLeaf
findTreeObject
public DOMASTNodeParent findTreeObject(org.eclipse.cdt.core.dom.ast.IASTNode node,
boolean useOffset)
- Returns the DOMASTNodeParent that corresponds to the IASTNode. This is the DOMASTNodeParent
that represents the IASTNode in the DOM AST View.
- Parameters:
node
-
- Returns:
setChildren
public void setChildren(DOMASTNodeLeaf[] children)