Interface SelectorsStateManager.StateDuplicator<T>

Type Parameters:
T - the type of the object
All Superinterfaces:
Function<T,T>, UnaryOperator<T>
Enclosing class:
SelectorsStateManager
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 static interface SelectorsStateManager.StateDuplicator<T> extends UnaryOperator<T>
A function that create a duplicate of the input object. The duplication must be a deep copy.
  • Method Summary

    Modifier and Type
    Method
    Description
    default T
    apply(T t)
     
    Duplicate the input objet
    static long
    duplicateLong(long l)
    Utility to duplicate a long

    Methods inherited from interface Function

    andThen, compose
  • Method Details

    • duplicate

      T duplicate(T t)
      Duplicate the input objet
      Parameters:
      t - the input object to duplicate
      Returns:
      a deep copy of the input object
    • apply

      default T apply(T t)
      Specified by:
      apply in interface Function<T,T>
    • duplicateLong

      static long duplicateLong(long l)
      Utility to duplicate a long
      Parameters:
      l - a long
      Returns:
      a copy of the long