Interface CheckboxPrompt

All Superinterfaces:
Prompt
All Known Implementing Classes:
DefaultCheckboxPrompt

public interface CheckboxPrompt extends Prompt
Interface for checkbox prompts. A checkbox prompt allows the user to select multiple items from a list.
  • Method Details

    • getItems

      List<CheckboxItem> getItems()
      Get the list of checkbox items.
      Returns:
      the list of checkbox items
    • getPageSize

      default int getPageSize()
      Get the page size for pagination. If 0 or negative, all items are shown without pagination.
      Returns:
      the page size, or 0 for no pagination
    • showPageIndicator

      default boolean showPageIndicator()
      Whether to show a loop indicator when pagination is enabled. If true, shows "(1/3)" style indicators.
      Returns:
      true to show page indicators, false to hide
    • getMinSelections

      default int getMinSelections()
      Get the minimum number of items that must be selected.
      Returns:
      the minimum number of selections, or 0 for no minimum
    • getMaxSelections

      default int getMaxSelections()
      Get the maximum number of items that can be selected.
      Returns:
      the maximum number of selections, or 0 for no maximum
    • isFilterable

      default boolean isFilterable()
      Whether the checkbox list supports inline text filtering. When enabled, the user can type characters to filter the displayed items. When disabled, typed characters are ignored.
      Returns:
      true if filtering is enabled, false otherwise