|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.guiseframework.model.AbstractListSelectEditor<V>
V - The type of values contained in the model.public abstract class AbstractListSelectEditor<V>
An abstract class for editing values in a list model. Prototypes are provided for common edit functionality. This class registers itself with the given list, which will cause memory leaks if an instance of this class is discarded without also discarding the list.
| Constructor Summary | |
|---|---|
AbstractListSelectEditor(ListSelectModel<V> listSelectModel)
List select model constructor. |
|
| Method Summary | |
|---|---|
protected abstract V |
createValue()
Creates a new value to add to the list. |
protected abstract ValuedComponent<V> |
createValuedComponent()
Creates a component for editing a value. |
void |
editValue()
Edits the currently selected value in the list. |
protected void |
editValue(V value,
int index,
boolean replace)
Commences editing a value. |
ActionPrototype |
getEditActionPrototype()
|
ActionPrototype |
getInsertActionPrototype()
|
ListSelectModel<V> |
getListSelectModel()
|
ActionPrototype |
getLowerActionPrototype()
|
ActionPrototype |
getRaiseActionPrototype()
|
ActionPrototype |
getRemoveActionPrototype()
|
void |
insertValue()
Creates and allows the user to edit a new value. |
void |
lowerValue()
Lowers the currently selected value in the list. |
void |
raiseValue()
Raises the currently selected value in the list. |
void |
removeValue()
Removes the currently selected value in the list. |
protected void |
updateProperties()
Updates the action properties based upon the current state of the list select model. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractListSelectEditor(ListSelectModel<V> listSelectModel)
listSelectModel - The list select model this prototype manipulates.
java.lang.NullPointerException - if the given list select model is null.| Method Detail |
|---|
public ListSelectModel<V> getListSelectModel()
getListSelectModel in interface ListSelectEditor<V>public ActionPrototype getInsertActionPrototype()
getInsertActionPrototype in interface ListSelectEditor<V>public ActionPrototype getEditActionPrototype()
getEditActionPrototype in interface ListSelectEditor<V>public ActionPrototype getRemoveActionPrototype()
getRemoveActionPrototype in interface ListSelectEditor<V>public ActionPrototype getLowerActionPrototype()
getLowerActionPrototype in interface ListSelectEditor<V>public ActionPrototype getRaiseActionPrototype()
getRaiseActionPrototype in interface ListSelectEditor<V>protected void updateProperties()
protected void editValue(V value,
int index,
boolean replace)
value - The value to edit.index - The index at which the edited value will be placed.replace - true if the value should replace the value at the given index, or false if the value should be inserted at the given index.public void insertValue()
insertValue in interface ListSelectEditor<V>public void editValue()
editValue in interface ListSelectEditor<V>public void removeValue()
removeValue in interface ListSelectEditor<V>public void lowerValue()
public void raiseValue()
protected abstract V createValue()
protected abstract ValuedComponent<V> createValuedComponent()
value - The current value.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||