Class FunctionCompiler


  • public class FunctionCompiler
    extends java.lang.Object
    A compiler translates Wayang functions into executable Flink functions.
    • Constructor Detail

      • FunctionCompiler

        public FunctionCompiler()
    • Method Detail

      • compile

        public <I,​O> org.apache.flink.api.common.functions.MapFunction<I,​O> compile​(TransformationDescriptor<I,​O> descriptor)
        Compile a transformation.
        Type Parameters:
        I - input type of the transformation
        O - output type of the transformation
        Parameters:
        descriptor - describes the transformation
        Returns:
        a compiled function
      • compile

        public <I,​O> org.apache.flink.api.common.functions.FlatMapFunction<I,​O> compile​(FunctionDescriptor.SerializableFunction<I,​java.lang.Iterable<O>> flatMapDescriptor)
        Compile a transformation.
        Type Parameters:
        I - input type of the transformation
        O - output type of the transformation
        Parameters:
        flatMapDescriptor - describes the transformation
        Returns:
        a compiled function
      • compile

        public <T> org.apache.flink.api.common.functions.ReduceFunction<T> compile​(ReduceDescriptor<T> descriptor)
        Compile a reduction.
        Type Parameters:
        T - input/output type of the transformation
        Parameters:
        descriptor - describes the transformation
        Returns:
        a compiled function
      • compileKeySelector

        public <T,​K> org.apache.flink.api.java.functions.KeySelector<T,​K> compileKeySelector​(TransformationDescriptor<T,​K> descriptor)
      • compileCoGroup

        public <T0,​T1,​O> org.apache.flink.api.common.functions.CoGroupFunction<T0,​T1,​O> compileCoGroup()
      • compileOutput

        public <T> org.apache.flink.api.java.io.TextOutputFormat.TextFormatter<T> compileOutput​(TransformationDescriptor<T,​java.lang.String> formattingDescriptor)
      • compile

        public <I,​O> org.apache.flink.api.common.functions.MapPartitionFunction<I,​O> compile​(MapPartitionsDescriptor<I,​O> descriptor)
        Compile a partition transformation.
        Type Parameters:
        I - input type of the transformation
        O - output type of the transformation
        Parameters:
        descriptor - describes the transformation
        Returns:
        a compiled function