Interface AbstractSingleValueCondition.Mappable<T>

Type Parameters:
T - the Java type related to the database column type
All Known Implementing Classes:
IsEqualTo, IsEqualToWhenPresent, IsGreaterThan, IsGreaterThanOrEqualTo, IsGreaterThanOrEqualToWhenPresent, IsGreaterThanWhenPresent, IsLessThan, IsLessThanOrEqualTo, IsLessThanOrEqualToWhenPresent, IsLessThanWhenPresent, IsLike, IsLikeCaseInsensitive, IsLikeCaseInsensitiveWhenPresent, IsLikeWhenPresent, IsNotEqualTo, IsNotEqualToWhenPresent, IsNotLike, IsNotLikeCaseInsensitive, IsNotLikeCaseInsensitiveWhenPresent, IsNotLikeWhenPresent
Enclosing class:
AbstractSingleValueCondition<T>

public static interface AbstractSingleValueCondition.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 AbstractSingleValueCondition.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> AbstractSingleValueCondition<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.