org.openuat.sensors
Interface SamplesSink

All Known Implementing Classes:
MotionAuthenticationProtocol2, TimeSeries

public interface SamplesSink

This interface represents a sink for sample values, and only defines three methods: to add new samples, to react to a segment becoming "active" (by some definition) and to react to a segment becoming "inactive".

Version:
1.0
Author:
Rene Mayrhofer

Method Summary
 void addSample(double sample, int index)
          Adds a new sample to the sink.
 void segmentEnd(int index)
          Should be called when it is detected that an active segment end, i.e.
 void segmentStart(int index)
          Should be called when it is detected that an active segment starts, i.e.
 

Method Detail

addSample

void addSample(double sample,
               int index)
Adds a new sample to the sink.

Parameters:
sample - The new sample value to add.
index - The index of this sample. All samples are required to be equally spaced.

segmentStart

void segmentStart(int index)
Should be called when it is detected that an active segment starts, i.e. when it is detected that the source has become active by some definition.

Parameters:
index - The index at which the active segment starts.

segmentEnd

void segmentEnd(int index)
Should be called when it is detected that an active segment end, i.e. when it is detected that the source has become quiescent by some definition.

Parameters:
index - The index at which the active segment ends.


2005-2006, Rene Mayrhofer.