org.appng.api.support

## Interface OptionOwner.Selector

- All Superinterfaces:
    OptionOwner.HitCounter<String>
  Enclosing interface:
    OptionOwner

      public static interface OptionOwner.Selector
      extends OptionOwner.HitCounter<String>

  A selector decides whether or not a given `Option` should be selected. Also implements `OptionOwner.HitCounter`, using the options's value and returning `null` by default.
  See Also:
    `Option.isSelected()`

- - ### Method Summary

    All Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default Integer` | `count(String optionValue)` Counts the hits for the option created from the given element.
    `void` | `select(Option o)` Selects or de-selects an option by calling `Option.setSelected(Boolean)`.

- - ### Method Detail

    - #### select

          void select(Option o)

      Selects or de-selects an option by calling `Option.setSelected(Boolean)`.
      Parameters:
        `o` - the `Option` which might be selected

    - #### count

          default Integer count(String optionValue)

      Description copied from interface: `OptionOwner.HitCounter`
      Counts the hits for the option created from the given element.
      Specified by:
        `count` in interface `OptionOwner.HitCounter<String>`
      Parameters:
        `optionValue` - the element to count the hits for
      Returns:
        the number of hits for this option

Copyright © 2011–2023 aiticon GmbH. All rights reserved.