org.mbari.siam.utils
Class BoxcarFilter

java.lang.Object
  extended by org.mbari.siam.utils.Filter
      extended by org.mbari.siam.utils.BoxcarFilter

public class BoxcarFilter
extends Filter


Field Summary
protected  int _depth
           
protected  int _index
           
protected  java.util.Vector _values
           
static int DEFAULT_DEPTH
           
 
Fields inherited from class org.mbari.siam.utils.Filter
_log4j, ACTION_CANCEL, ACTION_OK, DEFAULT_ID, DEFAULT_NAME
 
Constructor Summary
BoxcarFilter()
           
BoxcarFilter(int depth)
           
BoxcarFilter(java.lang.String name, int id)
           
BoxcarFilter(java.lang.String name, int id, int depth)
           
BoxcarFilter(java.lang.String name, int id, java.util.Vector inputs, int depth)
           
 
Method Summary
 int depth()
           
protected  int doFilterAction(double value)
          Perform the filter function with the new input value.
 void reset()
          Reset filter.
 void setDepth(int depth)
          Resets the depth of this filter.
 
Methods inherited from class org.mbari.siam.utils.Filter
addInput, addInputs, attach, doubleValue, floatValue, getID, getInput, getInput, indexOf, inputCount, inputGate, intValue, longValue, name, outputGate, removeAllInputs, removeInput, setID, setName, toString, triggerIn, triggerOut
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_DEPTH

public static final int DEFAULT_DEPTH
See Also:
Constant Field Values

_values

protected java.util.Vector _values

_depth

protected int _depth

_index

protected int _index
Constructor Detail

BoxcarFilter

public BoxcarFilter()

BoxcarFilter

public BoxcarFilter(int depth)

BoxcarFilter

public BoxcarFilter(java.lang.String name,
                    int id)

BoxcarFilter

public BoxcarFilter(java.lang.String name,
                    int id,
                    int depth)

BoxcarFilter

public BoxcarFilter(java.lang.String name,
                    int id,
                    java.util.Vector inputs,
                    int depth)
             throws InvalidPropertyException
Throws:
InvalidPropertyException
Method Detail

doFilterAction

protected int doFilterAction(double value)
Perform the filter function with the new input value. Sets member variable _filterValue, which will be passed to the output by triggerOut() if the output gating conditions are met. Overrides base class default.

Specified by:
doFilterAction in class Filter

reset

public void reset()
Reset filter. Does nothing by default. Subclasses may use this to provide a way to reset the filter. Overrides base class default.

Overrides:
reset in class Filter

depth

public int depth()

setDepth

public void setDepth(int depth)
              throws InvalidPropertyException
Resets the depth of this filter. Also empties filter contents

Throws:
InvalidPropertyException


Copyright © 2003 MBARI.

The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.