Class DefaultTwoOutputNonPartitionedContext<OUT1,OUT2>
- java.lang.Object
-
- org.apache.flink.datastream.impl.context.DefaultTwoOutputNonPartitionedContext<OUT1,OUT2>
-
- All Implemented Interfaces:
RuntimeContext
,TwoOutputNonPartitionedContext<OUT1,OUT2>
public class DefaultTwoOutputNonPartitionedContext<OUT1,OUT2> extends Object implements TwoOutputNonPartitionedContext<OUT1,OUT2>
The default implementation ofTwoOutputNonPartitionedContext
.
-
-
Field Summary
Fields Modifier and Type Field Description protected DefaultRuntimeContext
context
protected Collector<OUT1>
firstCollector
protected Collector<OUT2>
secondCollector
-
Constructor Summary
Constructors Constructor Description DefaultTwoOutputNonPartitionedContext(DefaultRuntimeContext context, DefaultPartitionedContext partitionedContext, Collector<OUT1> firstCollector, Collector<OUT2> secondCollector, boolean isKeyed, Set<Object> keySet)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
applyToAllPartitions(TwoOutputApplyPartitionFunction<OUT1,OUT2> applyPartitionFunction)
Apply a function to all partitions.JobInfo
getJobInfo()
Get theJobInfo
of this process function.MetricGroup
getMetricGroup()
Get the metric group of this process function.TaskInfo
getTaskInfo()
Get theTaskInfo
of this process function.
-
-
-
Field Detail
-
context
protected final DefaultRuntimeContext context
-
-
Constructor Detail
-
DefaultTwoOutputNonPartitionedContext
public DefaultTwoOutputNonPartitionedContext(DefaultRuntimeContext context, DefaultPartitionedContext partitionedContext, Collector<OUT1> firstCollector, Collector<OUT2> secondCollector, boolean isKeyed, Set<Object> keySet)
-
-
Method Detail
-
applyToAllPartitions
public void applyToAllPartitions(TwoOutputApplyPartitionFunction<OUT1,OUT2> applyPartitionFunction) throws Exception
Description copied from interface:TwoOutputNonPartitionedContext
Apply a function to all partitions. For keyed stream, it will apply to all keys. For non-keyed stream, it will apply to single partition.- Specified by:
applyToAllPartitions
in interfaceTwoOutputNonPartitionedContext<OUT1,OUT2>
- Throws:
Exception
-
getJobInfo
public JobInfo getJobInfo()
Description copied from interface:RuntimeContext
Get theJobInfo
of this process function.- Specified by:
getJobInfo
in interfaceRuntimeContext
-
getTaskInfo
public TaskInfo getTaskInfo()
Description copied from interface:RuntimeContext
Get theTaskInfo
of this process function.- Specified by:
getTaskInfo
in interfaceRuntimeContext
-
getMetricGroup
public MetricGroup getMetricGroup()
Description copied from interface:RuntimeContext
Get the metric group of this process function.- Specified by:
getMetricGroup
in interfaceRuntimeContext
-
-