Class ComboBoxSelectionContext

All Implemented Interfaces:
Extensible, SelectionChangeEmitter, SelectionContext, SelectionSource

public class ComboBoxSelectionContext extends AbstractSelectionContext
A selection provider that wraps a JList. Elements contained in Selections handled by this provider represent currently selected list objects.
  • Constructor Details

    • ComboBoxSelectionContext

      public ComboBoxSelectionContext(JComboBox comboBox)
  • Method Details

    • getSelection

      public Selection getSelection()
      Returns:
      The current selection. The selection may be empty, but never null.
      See Also:
    • setSelection

      public void setSelection(Selection selection)
      Description copied from interface: SelectionContext
      Sets a new selection.
      Parameters:
      selection - The new selection.
    • getComboBox

      public JComboBox getComboBox()
    • setComboBox

      public void setComboBox(JComboBox comboBox)