Module is.codion.swing.common.model
Interface FilterComboBoxModel.ComboBoxSelection<T>
- Type Parameters:
T- the item type
- All Superinterfaces:
is.codion.common.model.selection.SingleItemSelection<T>
- Enclosing interface:
- FilterComboBoxModel<T>
public static interface FilterComboBoxModel.ComboBoxSelection<T>
extends is.codion.common.model.selection.SingleItemSelection<T>
-
Method Summary
Modifier and TypeMethodDescriptionis.codion.common.state.StateSpecifies whether filtering the model affects the currently selected item.booleanReturns true if this model contains null and it is selected.Provides a way for the combo box model to translate an item when it is selected, such as selecting the String "1" in a String based model when selected item is set to the number 1.Provides a way for the combo box model to prevent the selection of certain items.value()Methods inherited from interface is.codion.common.model.selection.SingleItemSelection
changing, clear, empty, item
-
Method Details
-
value
T value()- Returns:
- the selected value, null in case the value representing null is selected
- See Also:
-
nullSelected
boolean nullSelected()Returns true if this model contains null and it is selected.- Returns:
- true if this model contains null and it is selected, false otherwise
- See Also:
-
translator
Provides a way for the combo box model to translate an item when it is selected, such as selecting the String "1" in a String based model when selected item is set to the number 1.- Returns:
- the
Valuecontrolling the selected item translator
-
validPredicate
Provides a way for the combo box model to prevent the selection of certain items.- Returns:
- the
Valuecontrolling the valid selection predicate
-
filterSelected
is.codion.common.state.State filterSelected()Specifies whether filtering the model affects the currently selected item. If true, the selection is cleared when the selected item is filtered from the model, otherwise the selected item can potentially represent a value which is not currently visible in the model This is false by default.- Returns:
- the
Statecontrolling whether filtering affects the selected item - See Also:
-
FilterModel.VisibleItems.predicate()
-