Package org.apache.pivot.wtk
Interface Spinner.ItemBindMapping
-
- All Known Implementing Classes:
SpinnerIndexBindMapping
- Enclosing class:
- Spinner
public static interface Spinner.ItemBindMapping
Translates between spinner and bind context data during data binding.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Object
get(List<?> spinnerData, int index)
Retrieves the item at the given index during aComponent.store(Object)
operation.int
indexOf(List<?> spinnerData, java.lang.Object value)
Returns the index of the item in the source list during aComponent.load(Object)
operation.
-
-
-
Method Detail
-
indexOf
int indexOf(List<?> spinnerData, java.lang.Object value)
Returns the index of the item in the source list during aComponent.load(Object)
operation.- Parameters:
spinnerData
- The source spinner data.value
- The value to locate.- Returns:
- The index of first occurrence of the value if it exists in the
list;
-1
, otherwise.
-
get
java.lang.Object get(List<?> spinnerData, int index)
Retrieves the item at the given index during aComponent.store(Object)
operation.- Parameters:
spinnerData
- The source spinner data.index
- The index of the value to retrieve.- Returns:
- The item at the given index.
-
-