edu.berkeley.guir.papier_mache.event
Class EventFilter

java.lang.Object
  extended by edu.berkeley.guir.papier_mache.event.EventFilter
All Implemented Interfaces:
java.util.EventListener, PhobListener
Direct Known Subclasses:
MotionlessFilter

public class EventFilter
extends java.lang.Object
implements PhobListener

A class that accepts events and filters them according to a specified ObjectClassifier. The filtered events are sent to the VisionListener passed in to the constructor.

Author:
Scott Klemmer ( srk(AT)cs.berkeley.edu )

Constructor Summary
EventFilter(ObjectClassifier classif, PhobListener visionListener)
           
 
Method Summary
 void addClassification(ObjectClassifier oc)
           
 void addListener(PhobListener listener)
           
 void phobAdded(PhobEvent visEvent)
          Called when a PhobProducer has sensed a new object
 void phobRemoved(PhobEvent visEvent)
          Called when an object is removed from a PhobProducer's sensor
 void phobUpdated(PhobEvent visEvent)
          Called when new information is available about a previously found object
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EventFilter

public EventFilter(ObjectClassifier classif,
                   PhobListener visionListener)
Method Detail

phobAdded

public void phobAdded(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when a PhobProducer has sensed a new object

Specified by:
phobAdded in interface PhobListener
Parameters:
visEvent - an event describing the found object

phobUpdated

public void phobUpdated(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when new information is available about a previously found object

Specified by:
phobUpdated in interface PhobListener
Parameters:
visEvent - an event with new information about the found object

phobRemoved

public void phobRemoved(PhobEvent visEvent)
Description copied from interface: PhobListener
Called when an object is removed from a PhobProducer's sensor

Specified by:
phobRemoved in interface PhobListener
Parameters:
visEvent - an event referencing the removed object

addClassification

public void addClassification(ObjectClassifier oc)

addListener

public void addListener(PhobListener listener)