Package com.pixelmed.database
Class DatabaseTreeModel
java.lang.Object
com.pixelmed.database.DatabaseTreeModel
- All Implemented Interfaces:
TreeModel
The DatabaseTreeModel
class implements a
TreeModel
to abstract the contents of a database as
a tree in order to provide support for a DatabaseTreeBrowser
.
For details of some of the methods implemented here see javax.swing.tree.TreeModel
.
-
Constructor Summary
ConstructorsConstructorDescriptionConstruct a tree model of the supplied database. -
Method Summary
Modifier and TypeMethodDescriptionvoid
int
getChildCount
(Object parent) int
getIndexOfChild
(Object parent, Object child) getRoot()
boolean
void
toString()
Dump the entire tree to a string.void
valueForPathChanged
(TreePath path, Object newValue)
-
Constructor Details
-
DatabaseTreeModel
Construct a tree model of the supplied database.
- Parameters:
d
- the database information model to build the tree from- Throws:
DicomException
- thrown if there are problems accessing the database
-
-
Method Details
-
getChild
-
getIndexOfChild
- Specified by:
getIndexOfChild
in interfaceTreeModel
- Parameters:
parent
-child
-
-
getRoot
-
getChildCount
- Specified by:
getChildCount
in interfaceTreeModel
- Parameters:
parent
-
-
isLeaf
-
valueForPathChanged
- Specified by:
valueForPathChanged
in interfaceTreeModel
- Parameters:
path
-newValue
-
-
addTreeModelListener
- Specified by:
addTreeModelListener
in interfaceTreeModel
- Parameters:
tml
-
-
removeTreeModelListener
- Specified by:
removeTreeModelListener
in interfaceTreeModel
- Parameters:
tml
-
-
toString
Dump the entire tree to a string.
Performs a top-down traversal.
-