Class FunctionMap<K,​I,​O>

  • Type Parameters:
    K - Type of key
    I - Input type
    O - Output type
    All Implemented Interfaces:
    Function<Map<K,​I>,​Map<K,​O>>

    public class FunctionMap<K,​I,​O>
    extends KorypheFunction<Map<K,​I>,​Map<K,​O>>
    Applies a Function to the values of an input Map, to produce a new output map.
    • Constructor Detail

      • FunctionMap

        public FunctionMap()
        Default - for serialisation.
      • FunctionMap

        public FunctionMap​(Function<I,​O> function)
    • Method Detail

      • setFunction

        public void setFunction​(Function<I,​O> function)
      • getFunction

        public Function<I,​O> getFunction()
      • apply

        public Map<K,​O> apply​(Map<K,​I> input)
        Iterate through the values of an input map, applying the wrapped Function.
        Parameters:
        input - Input map.
        Returns:
        Output map.