Interface HasMaximumSelectionSize

All Known Subinterfaces:
WithMaximumSelectionSizeMixin<SELF>
All Known Implementing Classes:
GridMultiSelect

public interface HasMaximumSelectionSize
Marker interface for objects that have a limit to selection size. Whatever selection size means is left for implementations to decide.
Since:
2020-12-09
Author:
miki
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    Indicates unlimited selection size.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns the current maximum selection size.
    void
    setMaximumSelectionSize(int maximumSelectionSize)
    Defines the new maximum selection size.
  • Field Details

    • UNLIMITED

      static final int UNLIMITED
      Indicates unlimited selection size. This should be the default for each implementing class. Any maximum selection size not larger than this number means unlimited selection.
      See Also:
  • Method Details

    • setMaximumSelectionSize

      void setMaximumSelectionSize(int maximumSelectionSize)
      Defines the new maximum selection size. When current selection is above the new limit, the selection should change so that it fits the new limit.
      Parameters:
      maximumSelectionSize - Maximum selection size.
    • getMaximumSelectionSize

      int getMaximumSelectionSize()
      Returns the current maximum selection size.
      Returns:
      Maximum allowed selection size; UNLIMITED by default.