com.espertech.esper.pattern.guard
Class TimerWithinGuardFactory

java.lang.Object
  extended by com.espertech.esper.pattern.guard.TimerWithinGuardFactory
All Implemented Interfaces:
GuardFactory, MetaDefItem, java.io.Serializable

public class TimerWithinGuardFactory
extends java.lang.Object
implements GuardFactory, MetaDefItem, java.io.Serializable

Factory for TimerWithinGuard instances.

See Also:
Serialized Form

Field Summary
protected  MatchedEventConvertor convertor
          For converting matched-events maps to events-per-stream.
protected  ExprNode millisecondsExpr
          Number of milliseconds.
 
Constructor Summary
TimerWithinGuardFactory()
           
 
Method Summary
protected  long computeMilliseconds(MatchedEventMap beginState, PatternAgentInstanceContext context)
           
 Guard makeGuard(PatternAgentInstanceContext context, MatchedEventMap matchedEventMap, Quitable quitable, EvalStateNodeNumber stateNodeId, java.lang.Object guardState)
          Constructs a guard instance.
 void setGuardParameters(java.util.List<ExprNode> parameters, MatchedEventConvertor convertor)
          Sets the guard object parameters.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

millisecondsExpr

protected ExprNode millisecondsExpr
Number of milliseconds.


convertor

protected transient MatchedEventConvertor convertor
For converting matched-events maps to events-per-stream.

Constructor Detail

TimerWithinGuardFactory

public TimerWithinGuardFactory()
Method Detail

setGuardParameters

public void setGuardParameters(java.util.List<ExprNode> parameters,
                               MatchedEventConvertor convertor)
                        throws GuardParameterException
Description copied from interface: GuardFactory
Sets the guard object parameters.

Specified by:
setGuardParameters in interface GuardFactory
Parameters:
parameters - is a list of parameters
convertor - for converting a
Throws:
GuardParameterException - thrown to indicate a parameter problem

computeMilliseconds

protected long computeMilliseconds(MatchedEventMap beginState,
                                   PatternAgentInstanceContext context)

makeGuard

public Guard makeGuard(PatternAgentInstanceContext context,
                       MatchedEventMap matchedEventMap,
                       Quitable quitable,
                       EvalStateNodeNumber stateNodeId,
                       java.lang.Object guardState)
Description copied from interface: GuardFactory
Constructs a guard instance.

Specified by:
makeGuard in interface GuardFactory
Parameters:
context - - services for use by guard
matchedEventMap - - the prior matching events
quitable - - to use for indicating the guard has quit
stateNodeId - - a node id for the state object
guardState - - state node for guard
Returns:
guard instance

© 2006-2015 EsperTech Inc.
All rights reserved.
Visit us at espertech.com