Package ghidra.framework.main.datatree
Class DomainFolderNode
- java.lang.Object
- 
- docking.widgets.tree.GTreeNode
- 
- docking.widgets.tree.GTreeLazyNode
- 
- ghidra.framework.main.datatree.DomainFolderNode
 
 
 
- 
- Direct Known Subclasses:
- DomainFolderRootNode
 
 public class DomainFolderNode extends GTreeLazyNode implements Cuttable Class to represent a node in the Data tree.
- 
- 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.List<GTreeNode>children()GTreeNodeclone()Creates a clone of this node.intcompareTo(GTreeNode node)voiddispose()protected voiddoAddNode(int index, GTreeNode node)Adds a node to this node's children at the given index and notifies the tree.protected voiddoAddNode(GTreeNode node)Adds a node to this node's children.protected voiddoAddNodes(java.util.List<GTreeNode> nodes)Adds the given nodes to this node's children.protected voiddoFireNodeAdded(GTreeNode newNode)protected voiddoFireNodeChanged()protected voiddoFireNodeRemoved(GTreeNode removedNode, int index)protected voiddoFireNodeStructureChanged()protected voiddoRemoveNode(GTreeNode node)Removes the node from this node's children and notifies the tree.protected voiddoSetChildren(java.util.List<GTreeNode> childList)Sets the children of this node to the given list of child nodes, but does not notify the tree.protected voiddoSetChildrenAndFireEvent(java.util.List<GTreeNode> childList)Sets the children of this node to the given list of child nodes and fires the appropriate tree event to kick the tree to update the display.booleanequals(java.lang.Object obj)protected java.util.List<GTreeNode>generateChildren()Subclasses must be able to generate their children nodes on demand by implementing this method.DomainFileFiltergetDomainFileFilter()DomainFoldergetDomainFolder()Get the domain folder; returns null if this node represents a domain file.javax.swing.IcongetIcon(boolean expanded)Returns the Icon to be displayed for this node in the treejava.lang.StringgetName()Returns the name of the node.GTreeNodegetParent()Returns the parent of this node.java.lang.StringgetToolTip()Returns the string to be displayed as a tooltip when the user hovers the mouse on this node in the treeGTreegetTree()Returns the GTree that this node is attached tointhashCode()booleanisCut()Returns whether this node is marked as deleted.booleanisEditable()Returns true if this node is allowed to be edited in the tree.booleanisInProgress()Returns true if the node is in the process of loading its children.booleanisLeaf()Returns true if this node has no children.booleanisLoaded()True if the children for this node have been loaded yet.booleanisRoot()Returns true if this is a root node of a GTreevoidsetIsCut(boolean isCut)Set this node to be deleted so that it can be rendered as such.java.lang.StringtoString()voidvalueChanged(java.lang.Object newValue)Notification method called when a cell editor completes editing to notify this node that its value has changed.- 
Methods inherited from class docking.widgets.tree.GTreeLazyNodeaddNode, addNode, addNodes, removeAll, removeNode, unloadChildren
 - 
Methods inherited from class docking.widgets.tree.GTreeNodecollapse, expand, filter, fireNodeChanged, fireNodeStructureChanged, getChild, getChild, getChildCount, getChildren, getDisplayText, getIndexInParent, getIndexOfChild, getLeafCount, getNodeCount, getRoot, getTreePath, isAncestor, isExpanded, iterator, loadAll, setChildren, stream
 
- 
 
- 
- 
- 
Method Detail- 
getDomainFolderpublic DomainFolder getDomainFolder() Get the domain folder; returns null if this node represents a domain file.- Returns:
- DomainFolder
 
 - 
isLeafpublic boolean isLeaf() Returns true if this node has no children.
 - 
setIsCutpublic void setIsCut(boolean isCut) Set this node to be deleted so that it can be rendered as such.
 - 
isCutpublic boolean isCut() Returns whether this node is marked as deleted.
 - 
getIconpublic javax.swing.Icon getIcon(boolean expanded) Description copied from class:GTreeNodeReturns the Icon to be displayed for this node in the tree
 - 
getNamepublic java.lang.String getName() Description copied from class:GTreeNodeReturns the name of the node. IfGTreeNode.getDisplayText()is not overridden, then this is also the text that will be displayed in the tree for that node. In general, the name of a node should not change. If the text displayed in the tree changes over time, overrideGTreeNode.getDisplayText().
 - 
getToolTippublic java.lang.String getToolTip() Description copied from class:GTreeNodeReturns the string to be displayed as a tooltip when the user hovers the mouse on this node in the tree- Specified by:
- getToolTipin class- GTreeNode
- Returns:
- the tooltip to be displayed
 
 - 
generateChildrenprotected java.util.List<GTreeNode> generateChildren() Description copied from class:GTreeLazyNodeSubclasses must be able to generate their children nodes on demand by implementing this method.- Specified by:
- generateChildrenin class- GTreeLazyNode
- Returns:
- the list of GTreeNodes that make up the children for this node.
 
 - 
isEditablepublic boolean isEditable() Description copied from class:GTreeNodeReturns true if this node is allowed to be edited in the tree. You must override this method to allow a node to be edited. You must also overrideGTreeNode.valueChanged(Object)to handle the result of the edit.- Overrides:
- isEditablein class- GTreeNode
- Returns:
- true if this node is allowed to be edited in the tree
- See Also:
- GTreeNode.valueChanged(Object)
 
 - 
getDomainFileFilterpublic DomainFileFilter getDomainFileFilter() 
 - 
compareTopublic int compareTo(GTreeNode node) 
 - 
valueChangedpublic void valueChanged(java.lang.Object newValue) Description copied from class:GTreeNodeNotification method called when a cell editor completes editing to notify this node that its value has changed. If you override this method you must also overrideGTreeNode.isEditable().- Overrides:
- valueChangedin class- GTreeNode
- Parameters:
- newValue- the new value provided by the cell editor
- See Also:
- GTreeNode.isEditable()
 
 - 
getParentpublic final GTreeNode getParent() Returns the parent of this node. Note: this method is deliberately not synchronized (See comments above)- Returns:
- the parent of this node.
 
 - 
isRootpublic final boolean isRoot() Returns true if this is a root node of a GTree- Returns:
- true if this is a root node of a GTree
 
 - 
childrenprotected final java.util.List<GTreeNode> children() 
 - 
doSetChildrenAndFireEventprotected void doSetChildrenAndFireEvent(java.util.List<GTreeNode> childList) Sets the children of this node to the given list of child nodes and fires the appropriate tree event to kick the tree to update the display. Note: This method must be called from the swing thread because it will notify the underlying JTree.- Parameters:
- childList- the list of child nodes to assign as children to this node
- See Also:
- if calling from a background thread.
 
 - 
doSetChildrenprotected void doSetChildren(java.util.List<GTreeNode> childList) Sets the children of this node to the given list of child nodes, but does not notify the tree. This method does not have to be called from the swing thread. It is intended to be used by background threads that want to populate all or part of the tree, but wait until the bulk operations are completed before notifying the tree.- Parameters:
- childList- the list of child nodes to assign as children to this node
 
 - 
doAddNodeprotected void doAddNode(GTreeNode node) Adds a node to this node's children. Must be called from the swing thread.- Parameters:
- node- the node to add as a child to this node
 
 - 
doAddNodeprotected void doAddNode(int index, GTreeNode node)Adds a node to this node's children at the given index and notifies the tree. Must be called from the swing thread.- Parameters:
- index- the index at which to add the new node
- node- the node to add as a child to this node
 
 - 
doRemoveNodeprotected void doRemoveNode(GTreeNode node) Removes the node from this node's children and notifies the tree. Must be called from the swing thread.- Parameters:
- node- the node to remove
 
 - 
doAddNodesprotected void doAddNodes(java.util.List<GTreeNode> nodes) Adds the given nodes to this node's children. Must be called from the swing thread.- Parameters:
- nodes- the nodes to add to the children this node
 
 - 
clonepublic GTreeNode clone() throws java.lang.CloneNotSupportedException Creates a clone of this node. The clone should contain a shallow copy of all the node's attributes except that the parent and children are null.- Overrides:
- clonein class- java.lang.Object
- Returns:
- the clone of this object.
- Throws:
- java.lang.CloneNotSupportedException- if some implementation prevents itself from being cloned.
 
 - 
disposepublic void dispose() 
 - 
isInProgresspublic final boolean isInProgress() Returns true if the node is in the process of loading its children. SeeGTreeSlowLoadingNode- Returns:
- true if the node is in the process of loading its children.
 
 - 
isLoadedpublic boolean isLoaded() True if the children for this node have been loaded yet. Some GTree nodes are lazy in that they don't load their children until needed. Nodes that have the IN_PROGRESS node as it child is considered loaded if in the swing thread, otherwise they are considered not loaded.- Returns:
- true if the children for this node have been loaded.
 
 - 
getTreepublic GTree getTree() Returns the GTree that this node is attached to- Returns:
- the GTree that this node is attached to
 
 - 
doFireNodeAddedprotected void doFireNodeAdded(GTreeNode newNode) 
 - 
doFireNodeRemovedprotected void doFireNodeRemoved(GTreeNode removedNode, int index) 
 - 
doFireNodeStructureChangedprotected void doFireNodeStructureChanged() 
 - 
doFireNodeChangedprotected void doFireNodeChanged() 
 
- 
 
-