ist.palcom.services.timer
Class TimerDevice
java.lang.Object
ist.palcom.device.AbstractDevice
ist.palcom.services.timer.TimerDevice
- All Implemented Interfaces:
- java.lang.Runnable
public class TimerDevice
- extends AbstractDevice
This class implements the "Palcom" part of the timer device.
One (in this case, the) important device-specific task is to
initialize the DeviceIO and pass it to the DeviceContext.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TimerDevice
protected TimerDevice(java.lang.String name,
DeviceID deviceID)
initDevice
protected void initDevice()
throws java.io.IOException
- Description copied from class:
AbstractDevice
- Initialize the device. Called from a PalcomThread. Here the actual setup
is done. Subclasses override this method, and call super.initDevice from
there.
- Overrides:
initDevice in class AbstractDevice
- Throws:
java.io.IOException
createDeviceContext
protected DeviceContext createDeviceContext(DeviceID deviceID,
PalcomScheduler scheduler)
- Description copied from class:
AbstractDevice
- Creates the
DeviceContext of the device. This method has to be
implemented in a concrete subclass.
- Specified by:
createDeviceContext in class AbstractDevice
- Parameters:
deviceID - The device ID.scheduler - The scheduler.
- Returns:
- The DeviceContext
stopDevice
protected void stopDevice()
throws java.io.IOException
- Description copied from class:
AbstractDevice
- Stop the device. Called from a PalcomThread. Here the actual cleanup is
done. Subclasses override this method, and call super.stopDevice from
there.
- Overrides:
stopDevice in class AbstractDevice
- Throws:
java.io.IOException