Interface SelectionEvent<C extends Component,​T>

  • Type Parameters:
    T - the data type of the selection model
    C - the component type
    All Superinterfaces:
    Serializable
    All Known Implementing Classes:
    MultiSelectionEvent, SingleSelectionEvent

    public interface SelectionEvent<C extends Component,​T>
    extends Serializable
    A selection event that unifies the way to access to selection event for multi selection and single selection components (in case when only one selected item is required).
    Since:
    1.0
    Author:
    Vaadin Ltd
    • Method Detail

      • getAllSelectedItems

        Set<T> getAllSelectedItems()
        Gets all the currently selected items.

        This method applies more to multiselection - for single select it returns either an empty set or a set containing the only selected item.

        Returns:
        return all the selected items, if any, never null
      • getSource

        C getSource()
        The component on which the Event initially occurred.
        Returns:
        The component on which the Event initially occurred.
      • isFromClient

        boolean isFromClient()
        Checks if this event originated from the client side.
        Returns:
        true if the event originated from the client side, false otherwise