com.jpeterson.x10.module
Class CM11AStatusTransmission

java.lang.Object
  |
  +--com.jpeterson.x10.module.CM11AStatusTransmission

public class CM11AStatusTransmission
extends java.lang.Object
implements CM11ATransmissionEvent

Create a status request. The CM11A performs monitoring on a certain house code. The status request downloads the status of the monitored house code.


Constructor Summary
CM11AStatusTransmission(CM11A parent, CM11AStatusListener listener)
          Create a standard CM11 transmission event to request the status of the monitoring performed by the CM11 interface
 
Method Summary
 int getNumAttempts()
          Retrieve the number of transmission attempts.
 void setMaxAttempts(int maxAttempts)
          Set the number of transmission attempts
 java.lang.String toString()
          Create a string representation of the transmission.
 void transmit(java.io.InputStream in, java.io.OutputStream out)
          Transmit a CM11 status command.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CM11AStatusTransmission

public CM11AStatusTransmission(CM11A parent,
                               CM11AStatusListener listener)
Create a standard CM11 transmission event to request the status of the monitoring performed by the CM11 interface
Parameters:
parent - The CM11A device to retrieve the status of.
listener - CM11AStatusListener to notify when status retrieved. May be null.
Method Detail

transmit

public void transmit(java.io.InputStream in,
                     java.io.OutputStream out)
              throws TooManyAttemptsException,
                     InterruptedTransmissionException,
                     java.io.EOFException,
                     java.io.IOException
Transmit a CM11 status command.
Specified by:
transmit in interface CM11ATransmissionEvent
Parameters:
in - Input stream to read from
out - Output stream to write to
Throws:
TooManyAttemptsException - Too many retries have occurred
InterruptedTransmissionException - An unsolicited interrupt has been received during the transmission.
java.io.IOException - Some sort of I/O or I/O protocol error has occurred

getNumAttempts

public int getNumAttempts()
Retrieve the number of transmission attempts.
Specified by:
getNumAttempts in interface CM11ATransmissionEvent
Returns:
the number of transmission attempts

setMaxAttempts

public void setMaxAttempts(int maxAttempts)
Set the number of transmission attempts
Specified by:
setMaxAttempts in interface CM11ATransmissionEvent
Parameters:
maxAttempts - the maximum number of transmission attempts

toString

public java.lang.String toString()
Create a string representation of the transmission.
Overrides:
toString in class java.lang.Object
Returns:
String representation of the transmission.