Interface AbstractListValueCondition.Mappable<T>

Type Parameters:
T - the Java type related to the database column type
All Known Implementing Classes:
IsIn, IsInCaseInsensitive, IsInCaseInsensitiveWhenPresent, IsInWhenPresent, IsNotIn, IsNotInCaseInsensitive, IsNotInCaseInsensitiveWhenPresent, IsNotInWhenPresent
Enclosing class:
AbstractListValueCondition<T>

public static interface AbstractListValueCondition.Mappable<T>
Conditions may implement Mappable to alter condition values or types during rendering.

If a condition is Mappable, then a user may add a mapper to the usage of the condition that can alter the values of a condition, or change that datatype.

Implementations of Mappable may call AbstractListValueCondition.mapSupport(Function, Function, Supplier) as a common implementation of the mapping algorithm.

  • Method Summary

    Modifier and Type
    Method
    Description
    map(Function<? super @NonNull T,? extends R> mapper)
    If renderable, apply the mapping to the value and return a new condition with the new value.
  • Method Details

    • map

      <R> AbstractListValueCondition<R> map(Function<? super @NonNull T,? extends R> mapper)
      If renderable, apply the mapping to the value and return a new condition with the new value. Else return a condition that will not render (this).
      Type Parameters:
      R - type of the new condition
      Parameters:
      mapper - a mapping function to apply to the value, if renderable
      Returns:
      a new condition with the result of applying the mapper to the value of this condition, if renderable, otherwise a condition that will not render.