ukcrobots.core
Class SensorChangeListener

java.lang.Object
  |
  +--ukcrobots.core.SensorChangeListener
All Implemented Interfaces:
SensorListener

public abstract class SensorChangeListener
extends Object
implements SensorListener

A general listener only interested in the fact that a sensor's state has changed, not in the values that indicate the change.

Version:
2001.12.21
Author:
d.j.barnes @at@ kent.ac.uk

Constructor Summary
SensorChangeListener()
           
 
Method Summary
abstract  void stateChanged()
          Notify the listener that the sensor's state has changed.
 void stateChanged(int oldValue, int newValue)
          This method discards the underlying integer values from the sensor as they are not required.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait
 

Constructor Detail

SensorChangeListener

public SensorChangeListener()
Method Detail

stateChanged

public abstract void stateChanged()
Notify the listener that the sensor's state has changed.


stateChanged

public void stateChanged(int oldValue,
                         int newValue)
This method discards the underlying integer values from the sensor as they are not required.

Specified by:
stateChanged in interface SensorListener
Parameters:
oldValue - The old sensor value.
newValue - The new sensor value.