|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.alee.laf.tree.TreeState
@XStreamConverter(value=TreeStateConverter.class) public class TreeState
This object might contain tree selection and expand states for all loaded tree nodes. Usually this object is constructed through TreeUtils automatically and could be applied to some tree using these utilities aswell.
TreeUtils
,
Serialized FormField Summary | |
---|---|
protected java.util.Map<java.lang.String,NodeState> |
states
Tree node states. |
Constructor Summary | |
---|---|
TreeState()
Constructs new object instance with empty states. |
|
TreeState(java.util.Map<java.lang.String,NodeState> states)
Constructs new object instance with specified states. |
Method Summary | |
---|---|
void |
addState(java.lang.String nodeId,
boolean expanded,
boolean selected)
Adds node state. |
TreeState |
clone()
Returns cloned states object. |
java.util.Map<java.lang.String,NodeState> |
getStates()
Returns all node states. |
boolean |
isExpanded(java.lang.String nodeId)
Returns whether node with the specified ID is expanded or not. |
boolean |
isSelected(java.lang.String nodeId)
Returns whether node with the specified ID is selected or not. |
void |
setStates(java.util.Map<java.lang.String,NodeState> states)
Sets all node states. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.util.Map<java.lang.String,NodeState> states
Constructor Detail |
---|
public TreeState()
public TreeState(java.util.Map<java.lang.String,NodeState> states)
states
- node statesMethod Detail |
---|
public java.util.Map<java.lang.String,NodeState> getStates()
public void setStates(java.util.Map<java.lang.String,NodeState> states)
states
- all node statespublic void addState(java.lang.String nodeId, boolean expanded, boolean selected)
nodeId
- node IDexpanded
- expansion stateselected
- selection statepublic boolean isExpanded(java.lang.String nodeId)
nodeId
- node ID
public boolean isSelected(java.lang.String nodeId)
nodeId
- node ID
public TreeState clone()
clone
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |