|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.tensegrity.gui.UIItemEvaluationList
UIItemEvaluationList is a helper class to apply the GUIItem ID's
to components. This class holds the list of uiObjects and their id's. It
should be used within Components which want to benefit from the dynamic
localization. Use an instance of UIItemEvaluationList in your
component, initialize it in the installEvList of your Evaluable
implementation and fill it with id and Object pairs. In the
applyEvList method you simply delegate this call to the
apply method of your UIItemEvaluationList instance.
| Constructor Summary | |
UIItemEvaluationList(UIManager uiManager)
Creates a new UIItemEvaluationList and sets the initial capacity of the internal arrays to zero. |
|
UIItemEvaluationList(UIManager uiManager,
int capacity)
Creates a new UIItemEvaluationList and sets the initial capacity of the internal arrays to the given value capicity. |
|
| Method Summary | |
void |
add(java.lang.String id,
java.awt.Component obj)
Adds a new id to the id array and a the obj to the object array. |
void |
apply()
The apply method invokes for each id-component pair the applyItem method of the internal UIManager. |
void |
apply(int index)
This specialized apply method allows you to update the id-component-resource relation for a specific item identified by the given index. |
void |
clear()
Clears both internal arrays. |
int |
getSize()
Returns the minimum of sizes of the two internal arrays. |
void |
setAt(int index,
java.awt.Component obj)
Sets a specific Component at the given index in the object array, |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public UIItemEvaluationList(UIManager uiManager)
uiManager - the UIManager to use during the apply.
public UIItemEvaluationList(UIManager uiManager,
int capacity)
capicity.
uiManager - The UIManager which is used to apply id's to objects.capacity - the initial capacity of the internal arrays.| Method Detail |
public int getSize()
public void add(java.lang.String id,
java.awt.Component obj)
id - the id to add to the id arrayobj - the obj to add to the object array.
public void setAt(int index,
java.awt.Component obj)
index - the position at which you want the component to be.obj - the component to set at the given index.public void clear()
public void apply()
UIManager.applyItem(String, Object)public void apply(int index)
index - the index in the id- and object array, identifying the
element you want to update.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||