de.wagner_ibw.iow.spi
Class AbstractSPIDevice

java.lang.Object
  |
  +--de.wagner_ibw.iow.spi.AbstractSPIDevice
All Implemented Interfaces:
SPIDevice
Direct Known Subclasses:
AT25080A, GenericSPIDevice, M95020

public abstract class AbstractSPIDevice
extends java.lang.Object
implements SPIDevice

This is the abtract implementation of the SPIDevice interface.

Since:
0.9.4.
Author:
Thomas Wagner

Constructor Summary
AbstractSPIDevice(java.lang.String name, int flags)
           
 
Method Summary
 java.lang.String getName()
          Returns the name of the spi device.
 void reportReceived(int[] readBuffer)
          Callback method is called when a matching report was received.
 void setIowDevice(AbstractIowDevice iow)
          Sets the reference to an IO-Warrior device for write report operations.
 java.lang.String toString()
          Returns the name of the spi device as String.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractSPIDevice

public AbstractSPIDevice(java.lang.String name,
                         int flags)
Method Detail

getName

public java.lang.String getName()
Description copied from interface: SPIDevice
Returns the name of the spi device.

Specified by:
getName in interface SPIDevice
Returns:
Name of the spi device.

reportReceived

public void reportReceived(int[] readBuffer)
Description copied from interface: SPIDevice
Callback method is called when a matching report was received.

Specified by:
reportReceived in interface SPIDevice
Parameters:
readBuffer - Read buffer from a received report.

setIowDevice

public void setIowDevice(AbstractIowDevice iow)
Description copied from interface: SPIDevice
Sets the reference to an IO-Warrior device for write report operations.

Specified by:
setIowDevice in interface SPIDevice
Parameters:
iow - Instance of an IO-Warrior device.

toString

public java.lang.String toString()
Returns the name of the spi device as String.

Overrides:
toString in class java.lang.Object
Returns:
String representation of information about this spi device.