Interface ItemLabelGenerator<T>

Type Parameters:
T - item type
All Superinterfaces:
Function<T,String>, Serializable, SerializableFunction<T,String>
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ItemLabelGenerator<T> extends SerializableFunction<T,String>
ItemLabelGenerator can be used to customize the string shown to the user for an item.
Since:
1.0
Author:
Vaadin Ltd
  • Method Summary

    Modifier and Type
    Method
    Description
    apply(T item)
    Gets a caption for the item.

    Methods inherited from interface java.util.function.Function

    andThen, compose
  • Method Details

    • apply

      String apply(T item)
      Gets a caption for the item.
      Specified by:
      apply in interface Function<T,String>
      Parameters:
      item - the item to get caption for
      Returns:
      the caption of the item, not null