类 CountTriggerPolicy<T>
java.lang.Object
org.apache.pulsar.functions.windowing.triggers.CountTriggerPolicy<T>
- 类型参数:
T- the type of event tracked by this policy.
- 所有已实现的接口:
TriggerPolicy<T,Integer>
A trigger that tracks event counts and calls back
TriggerHandler.onTrigger()
when the count threshold is hit.-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明getState()Return runtime state to be checkpointed by the framework for restoring the trigger policy in case of failures.voidreset()resets the trigger policy.voidrestoreState(Integer state) Restore the trigger policy from the state that was earlier checkpointed by the framework.voidshutdown()Any clean up could be handled here.voidstart()Starts the trigger policy.toString()voidTracks the event and could use this to invoke the trigger.
-
构造器详细资料
-
CountTriggerPolicy
-
-
方法详细资料
-
track
从接口复制的说明:TriggerPolicyTracks the event and could use this to invoke the trigger.- 指定者:
track在接口中TriggerPolicy<T,Integer> - 参数:
event- the input event
-
reset
public void reset()从接口复制的说明:TriggerPolicyresets the trigger policy.- 指定者:
reset在接口中TriggerPolicy<T,Integer>
-
start
public void start()从接口复制的说明:TriggerPolicyStarts the trigger policy. This can be used during recovery to start the triggers after recovery is complete.- 指定者:
start在接口中TriggerPolicy<T,Integer>
-
shutdown
public void shutdown()从接口复制的说明:TriggerPolicyAny clean up could be handled here.- 指定者:
shutdown在接口中TriggerPolicy<T,Integer>
-
getState
从接口复制的说明:TriggerPolicyReturn runtime state to be checkpointed by the framework for restoring the trigger policy in case of failures.- 指定者:
getState在接口中TriggerPolicy<T,Integer> - 返回:
- the state
-
restoreState
从接口复制的说明:TriggerPolicyRestore the trigger policy from the state that was earlier checkpointed by the framework.- 指定者:
restoreState在接口中TriggerPolicy<T,Integer> - 参数:
state- the state
-
toString
-