Package ca.uqac.lif.cep.signal
Class WindowProcessor
- java.lang.Object
-
- ca.uqac.lif.cep.Processor
-
- ca.uqac.lif.cep.SynchronousProcessor
-
- ca.uqac.lif.cep.signal.WindowProcessor
-
- All Implemented Interfaces:
ca.uqac.lif.azrael.Printable
,ca.uqac.lif.azrael.Readable
,ca.uqac.lif.cep.Contextualizable
,ca.uqac.lif.cep.Duplicable
,ca.uqac.lif.cep.DuplicableProcessor
- Direct Known Subclasses:
PeakFinderLocalMaximum
,PeakFinderTravelRise
,PlateauFinder
public abstract class WindowProcessor extends ca.uqac.lif.cep.SynchronousProcessor
-
-
Field Summary
Fields Modifier and Type Field Description protected float
m_maxValue
The maximum value encountered so farprotected float
m_minValue
The minimum value encountered so farprotected java.util.Vector<java.lang.Float>
m_values
The window of values to rememberprotected int
m_windowWidth
The width of the window to processprotected static double
s_precision
The precision used to for the equality between double precision numbers-
Fields inherited from class ca.uqac.lif.cep.SynchronousProcessor
m_inputPushables, m_outputPullables, m_tempQueue
-
Fields inherited from class ca.uqac.lif.cep.Processor
m_context, m_eventTracker, m_hasBeenNotifiedOfEndOfTrace, m_inputArity, m_inputCount, m_inputPullables, m_inputQueues, m_notifiedEndOfTraceDownstream, m_outputArity, m_outputCount, m_outputPushables, m_outputQueues, MAX_PULL_RETRIES, s_versionString
-
-
Constructor Summary
Constructors Constructor Description WindowProcessor()
WindowProcessor(int width)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract java.lang.Float
computeOutputValue()
protected static boolean
doubleEquals(double d1, double d2)
protected float
getMaxValue()
protected float
getMinValue()
void
reset()
-
Methods inherited from class ca.uqac.lif.cep.SynchronousProcessor
compute, getPullableOutput, getPushableInput, setEventTracker
-
Methods inherited from class ca.uqac.lif.cep.Processor
allNotifiedEndOfTrace, allNull, associateTo, associateToInput, associateToOutput, copyInputQueue, copyOutputQueue, duplicate, duplicate, duplicateInto, equals, getAt, getContext, getContext, getEmptyQueue, getEventTracker, getId, getInputArity, getInputCount, getInputQueue, getInputType, getInputTypesFor, getLeaves, getLeaves, getOutputArity, getOutputCount, getOutputQueue, getOutputType, getPullableInput, getPullableOutput, getPushableInput, getPushableOutput, hashCode, leftShift, newContext, onEndOfTrace, or, or, print, printState, read, readState, rightShift, setContext, setContext, setPullableInput, setPushableOutput, start, startAll, stop, stopAll
-
-
-
-
Field Detail
-
s_precision
protected static final double s_precision
The precision used to for the equality between double precision numbers- See Also:
- Constant Field Values
-
m_values
protected java.util.Vector<java.lang.Float> m_values
The window of values to remember
-
m_windowWidth
protected final int m_windowWidth
The width of the window to process
-
m_maxValue
protected float m_maxValue
The maximum value encountered so far
-
m_minValue
protected float m_minValue
The minimum value encountered so far
-
-
Method Detail
-
reset
public void reset()
- Overrides:
reset
in classca.uqac.lif.cep.Processor
-
getMaxValue
protected float getMaxValue()
-
getMinValue
protected float getMinValue()
-
doubleEquals
protected static boolean doubleEquals(double d1, double d2)
-
computeOutputValue
protected abstract java.lang.Float computeOutputValue()
-
-