- java.lang.Object
-
- editor.AbstractTree<T,N>
-
- All Implemented Interfaces:
MutableTreeNode,TreeNode
- Direct Known Subclasses:
MessageTree,SearchTree
public abstract class AbstractTree<T extends AbstractTree<T,N>,N extends ITreeNode> extends Object implements MutableTreeNode
-
-
Constructor Summary
Constructors Constructor Description AbstractTree(NodeKind kind, N node)AbstractTree(String text, NodeKind kind, N node)AbstractTree(JTree tree)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidaddViaModel(MutableTreeNode child)Enumerationchildren()intdepth()booleangetAllowsChildren()TgetChildAt(int childIndex)intgetChildCount()List<T>getChildren()abstract IcongetIcon()intgetIndex(TreeNode node)NodeKindgetKind()NgetNode()TgetParent()TreePathgetPath()TgetRoot()StringgetText()JTreegetTree()ObjectgetUserData(String name)booleanhasErrors()booleanhasFailures()booleanhasWarnings()voidinsert(MutableTreeNode child, int index)voidinsertViaModel(MutableTreeNode child, int index)booleanisLeaf()booleanisTerminal()voidputUserData(String name, Object value)voidremove(int index)voidremove(MutableTreeNode node)voidremoveFromParent()voidselect()voidsetParent(MutableTreeNode newParent)voidsetText(String text)voidsetUserObject(Object object)StringtoString()
-
-
-
Field Detail
-
_text
protected String _text
-
-
Method Detail
-
getIcon
public abstract Icon getIcon()
-
getTree
public JTree getTree()
-
getRoot
public T getRoot()
-
getText
public String getText()
-
setText
public void setText(String text)
-
getKind
public NodeKind getKind()
-
getNode
public N getNode()
-
isTerminal
public boolean isTerminal()
-
insert
public void insert(MutableTreeNode child, int index)
- Specified by:
insertin interfaceMutableTreeNode
-
addViaModel
public void addViaModel(MutableTreeNode child)
-
insertViaModel
public void insertViaModel(MutableTreeNode child, int index)
-
remove
public void remove(int index)
- Specified by:
removein interfaceMutableTreeNode
-
remove
public void remove(MutableTreeNode node)
- Specified by:
removein interfaceMutableTreeNode
-
setUserObject
public void setUserObject(Object object)
- Specified by:
setUserObjectin interfaceMutableTreeNode
-
removeFromParent
public void removeFromParent()
- Specified by:
removeFromParentin interfaceMutableTreeNode
-
setParent
public void setParent(MutableTreeNode newParent)
- Specified by:
setParentin interfaceMutableTreeNode
-
getChildAt
public T getChildAt(int childIndex)
- Specified by:
getChildAtin interfaceTreeNode
-
getChildCount
public int getChildCount()
- Specified by:
getChildCountin interfaceTreeNode
-
getAllowsChildren
public boolean getAllowsChildren()
- Specified by:
getAllowsChildrenin interfaceTreeNode
-
children
public Enumeration children()
-
select
public void select()
-
getPath
public TreePath getPath()
-
hasFailures
public boolean hasFailures()
-
hasErrors
public boolean hasErrors()
-
hasWarnings
public boolean hasWarnings()
-
depth
public int depth()
-
-