public class CountCoBundleTrigger<IN1,IN2> extends Object implements CoBundleTrigger<IN1,IN2>
CoBundleTrigger that fires once the count of elements in a bundle reaches the given
count.| 构造器和说明 |
|---|
CountCoBundleTrigger(long maxCount) |
| 限定符和类型 | 方法和说明 |
|---|---|
String |
explain() |
void |
onElement1(IN1 element)
Called for every element that gets added to the bundle from the first input.
|
void |
onElement2(IN2 element)
Called for every element that gets added to the bundle from the second input.
|
void |
registerCallback(BundleTriggerCallback callback)
Register a callback which will be called once this trigger decides to finish this bundle.
|
void |
reset()
Reset the trigger to its initiate status.
|
public void registerCallback(BundleTriggerCallback callback)
CoBundleTriggerregisterCallback 在接口中 CoBundleTrigger<IN1,IN2>public void onElement1(IN1 element) throws Exception
CoBundleTriggerBundleTriggerCallback.finishBundle() should be invoked.onElement1 在接口中 CoBundleTrigger<IN1,IN2>element - The element that arrived from the first input.Exceptionpublic void onElement2(IN2 element) throws Exception
CoBundleTriggerBundleTriggerCallback.finishBundle() should be invoked.onElement2 在接口中 CoBundleTrigger<IN1,IN2>element - The element that arrived from the second input.Exceptionpublic void reset()
CoBundleTriggerreset 在接口中 CoBundleTrigger<IN1,IN2>public String explain()
explain 在接口中 CoBundleTrigger<IN1,IN2>Copyright © 2014–2020 The Apache Software Foundation. All rights reserved.