edu.columbia.coms6901.pingtel.pingim
Class DOMessage
java.lang.Object
|
+--edu.columbia.coms6901.pingtel.pingim.SIPMessage
|
+--edu.columbia.coms6901.pingtel.pingim.DOMessage
- public class DOMessage
- extends SIPMessage
Implementation of a SIP DO message.
Used to control X10 devices.
- Version:
- 1.0
- Author:
- Micah Sherr
Field Summary |
static int |
OFF
X10-controlled device is off |
static int |
ON
X10-controlled device is on |
private com.pingtel.xpressa.sys.XpressaSettings |
settings
the current set of settings for this phone |
Constructor Summary |
DOMessage(java.lang.String sForeignSipAddress,
java.lang.String sDeviceName,
int iAction)
Creates a new instance of a SIP DO message. |
Method Summary |
private boolean |
setHeaders(java.lang.String sForeignSipAddress,
java.lang.String sDeviceName,
int iAction)
Sets appropriate headers for SIP DO message. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
settings
private com.pingtel.xpressa.sys.XpressaSettings settings
- the current set of settings for this phone
ON
public static final int ON
- X10-controlled device is on
OFF
public static final int OFF
- X10-controlled device is off
DOMessage
public DOMessage(java.lang.String sForeignSipAddress,
java.lang.String sDeviceName,
int iAction)
- Creates a new instance of a SIP DO message.
- Parameters:
sForeignSipAddress
- SIP address of receipientsDeviceName
- Name of device (e.g., "lamp")iAction
- Either ON or OFF
setHeaders
private boolean setHeaders(java.lang.String sForeignSipAddress,
java.lang.String sDeviceName,
int iAction)
- Sets appropriate headers for SIP DO message.
- Parameters:
sForeignSipAddress
- the SIP address of the X10 devicesDeviceName
- the name of the deviceiAction
- either ON or OFF- Returns:
- true on success, false on error