|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.javaparts.dde.Conversation
This class represents a conversation with DDE server. Conversation is established on basis of service/topic pair. The following transactions are supported:
setDefaultTimeout method.
Asynchronous transaction methods return immediately and their
result can be obtained from AsyncCompletedEvent.
Advice transactions add items for DDE server to notify about their changes.
You get these notifications via ItemChangedEvent.
DDEEventListener| Constructor Summary | |
protected |
Conversation(java.lang.String service,
java.lang.String topic,
com.javaparts.dde.DDEThread dde,
long conversationId)
Creates a new instance of Conversation. |
| Method Summary | |
void |
close()
Close this conversation with DDE server. |
void |
execute(java.lang.String cmd)
Perform synchronous execute transaction with default timeout. |
void |
execute(java.lang.String cmd,
int timeout)
Perform synchronous execute transaction. |
void |
executeAsync(java.lang.String cmd)
Perform asynchronous execute transaction. |
void |
executeAsync(java.lang.String cmd,
java.lang.String tid)
Perform asynchronous execute transaction. |
java.lang.String |
getService()
Get service name of the conversation. |
java.lang.String |
getTopic()
Get topic name of the conversation. |
void |
poke(java.lang.String item,
byte[] value)
Perform synchronous poke transaction with default timeout. |
void |
poke(java.lang.String item,
byte[] value,
int timeout)
Perform synchronous poke transaction. |
void |
pokeAsync(java.lang.String item,
byte[] value)
Perform asynchronous poke transaction. |
void |
pokeAsync(java.lang.String item,
byte[] value,
java.lang.String tid)
Perform asynchronous poke transaction. |
byte[] |
request(java.lang.String item)
Perform synchronous request transaction with default timeout. |
byte[] |
request(java.lang.String item,
int timeout)
Perform synchronous request transaction. |
void |
requestAsync(java.lang.String item)
Perform asynchronous request transaction. |
void |
requestAsync(java.lang.String item,
java.lang.String tid)
Perform asynchronous request transaction. |
void |
setDefaultTimeout(int timeout)
Set default timeout for all synchronous transactions in this conversation. |
void |
startAdvice(java.lang.String item)
Perform start advice transaction with default timeout. |
void |
startAdvice(java.lang.String item,
int timeout)
Perform start advice transaction. |
void |
stopAdvice(java.lang.String item)
Perform stop advice transaction with default timeout. |
void |
stopAdvice(java.lang.String item,
int timeout)
Perform stop advice transaction. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
protected Conversation(java.lang.String service,
java.lang.String topic,
com.javaparts.dde.DDEThread dde,
long conversationId)
DDEClient.connect method.
| Method Detail |
public byte[] request(java.lang.String item,
int timeout)
throws DDEException
item - item nametimeout - timeout in miliseconds
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public byte[] request(java.lang.String item)
throws DDEException
item - item name
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void requestAsync(java.lang.String item,
java.lang.String tid)
throws DDEException
item - item nametid - transaction identification
DDEException - if conversation is closed.
public void requestAsync(java.lang.String item)
throws DDEException
item - item name
DDEException - if conversation is closed.
public void execute(java.lang.String cmd,
int timeout)
throws DDEException
cmd - command to executetimeout - timeout in miliseconds
DDEException - if given command is not accepted by the server,
conversation is closed, or timeout is reached.
public void execute(java.lang.String cmd)
throws DDEException
cmd - command to execute
DDEException - if given command is not accepted by the server,
conversation is closed, or timeout is reached.
public void executeAsync(java.lang.String cmd,
java.lang.String tid)
throws DDEException
cmd - command to executetid - transaction identification
DDEException - if conversation is closed.
public void executeAsync(java.lang.String cmd)
throws DDEException
cmd - command to execute
DDEException - if conversation is closed.
public void poke(java.lang.String item,
byte[] value,
int timeout)
throws DDEException
item - name of the item to updatevalue - new item valuetimeout - timeout in miliseconds
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void poke(java.lang.String item,
byte[] value)
throws DDEException
item - name of the item to updatevalue - new item value
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void pokeAsync(java.lang.String item,
byte[] value,
java.lang.String tid)
throws DDEException
item - name of the item to updatevalue - new item valuetid - transaction identification
DDEException - if conversation is closed.
public void pokeAsync(java.lang.String item,
byte[] value)
throws DDEException
item - name of the item to updatevalue - new item value
DDEException - if conversation is closed.
public void startAdvice(java.lang.String item,
int timeout)
throws DDEException
item - name of the item we want to subscribetimeout - timeout in miliseconds
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void startAdvice(java.lang.String item)
throws DDEException
item - name of the item we want to subscribe
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void stopAdvice(java.lang.String item,
int timeout)
throws DDEException
item - name of the item we want to unsubscribetimeout - tiemout in miliseconds
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void stopAdvice(java.lang.String item)
throws DDEException
item - name of the item we want to unsubscribe
DDEException - if there is no such item,
conversation is closed, or timeout is reached.
public void close()
throws DDEException
DDEExceptionpublic java.lang.String getService()
public java.lang.String getTopic()
public void setDefaultTimeout(int timeout)
timeout - timeout in miliseconds.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||