|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.ac.starlink.datanode.tree.NodeExpander
public class NodeExpander
Object which can obtain children from a node and add them to a TreeModel as they become available. While working, members of this class will check periodically whether they are still responsible for expanding nodes by seeing whether the ModelNode on whose behalf they are working still owns them as its NodeExpander. If not, they will assume that they are no longer doing useful work and will stop working. Subclasses ought to observe the same behaviour.
Constructor Summary | |
---|---|
NodeExpander(DataNodeTreeModel treeModel,
TreeModelNode modelNode)
Constructs a new expander. |
Method Summary | |
---|---|
void |
expandNode()
Performs the actual node expansion. |
boolean |
isComplete()
Indicates whether node expansion completed successfully. |
boolean |
isStopped()
Indicates whether node expansion has stopped happening. |
void |
stop()
Interrupts the work of this expander. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public NodeExpander(DataNodeTreeModel treeModel, TreeModelNode modelNode)
modelNode
- the node to be expandedtreeModel
- the model into which children are to be addedMethod Detail |
---|
public void expandNode()
If this expander ceases to be active (is not owned by its model node) then expansion may be stopped.
This may be a slow operation, so should not be done in the event dispatch thread.
public void stop()
public boolean isStopped()
public boolean isComplete()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |