Class FunctionAssembler


  • public class FunctionAssembler
    extends java.lang.Object
    • Constructor Detail

      • FunctionAssembler

        public FunctionAssembler()
    • Method Detail

      • andThen

        public FunctionAssembler andThen​(java.util.function.LongUnaryOperator andThen)
        Valid for any number of calls from the beginning of assembly.
        Parameters:
        andThen - a LongUnaryOperator
        Returns:
        this FunctionAssemble
      • andThen

        public FunctionAssembler andThen​(java.util.function.LongFunction andThen)
        Only valid after 0 or more LongUnaryOperators, but not after another LongFunction which isn't a LongFunction<Long>. Without explicit type annotations (type erasure doesn't help you for late binding), we will assume that multiple LongFunctions in sequence follow LongFunction<Long>s and cast or error if not.
        Parameters:
        andThen - a LongFunction
        Returns:
        this FunctionAssembler
      • andThen

        public FunctionAssembler andThen​(java.util.function.Function andThen)

        Allows for mapping generic functions into the composed lambda. This is not yet type safe, because type erasure.

        If this is called after a LongFunction<?> has been added, then the types are presumed to match, and the lamda is coerced via casting.

        Parameters:
        andThen - Function to add to the outer calling layer
        Returns:
        this FunctionAssembler
      • getFunction

        public java.util.function.LongFunction<?> getFunction()
      • getDataMapper

        public <T> DataMapper<T> getDataMapper()