Package sk.ipesoft.d2000.d2japi
Interface RPCConversationContext
-
public interface RPCConversationContextContext of RPC conversation. Context is used for calling conversation partner and for obtaining further information about the RPC conversation.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidabort()Abort current conversation.voidcallRPCNoreply(int interfaceHobj, java.lang.String name, sk.ipesoft.d2000.base.UnivalValue<?>[] arguments, RPCConversationFlag conversationFlag)Call partners RPC asynchronously.intgetId()Get internal ID of RPC conversation.intgetInterfaceHobj()Get HOBJ of ESL interface that declares called RPC or zero if RPC is not declared by ESL interface.booleanisMeInitiator()Initiator of the conversation getstrue, target of the conversation getsfalse.booleanisToMeOpened()Gettrueif receiving messages from the partner is possible.booleanisToPartnerOpened()Gettrueif sending messages to the partner is possible.
-
-
-
Method Detail
-
abort
void abort()
Abort current conversation. Partner is notified about RPC conversation abortion.- Throws:
java.lang.IllegalStateException- when the conversation has been already closed for sending messages.
-
callRPCNoreply
void callRPCNoreply(int interfaceHobj, java.lang.String name, sk.ipesoft.d2000.base.UnivalValue<?>[] arguments, RPCConversationFlag conversationFlag)Call partners RPC asynchronously.- Parameters:
interfaceHobj- HOBJ of ESL interface if called method is implementationname- name of called RPCarguments- arguments of RPC callconversationFlag- flag indicating state of the RPC conversation- Throws:
java.lang.IllegalStateException- when the conversation has been already closed for sending messages.
-
getId
int getId()
Get internal ID of RPC conversation.ID is unique only in combination with
isMeInitiator()and only during one moment. IDs are recycled after conversation's closure or abortion.- Returns:
- internal ID
-
getInterfaceHobj
int getInterfaceHobj()
Get HOBJ of ESL interface that declares called RPC or zero if RPC is not declared by ESL interface.- Returns:
- HOBJ or zero.
-
isToPartnerOpened
boolean isToPartnerOpened()
Gettrueif sending messages to the partner is possible.- Returns:
trueif sending messages to the partner is possible
-
isMeInitiator
boolean isMeInitiator()
Initiator of the conversation getstrue, target of the conversation getsfalse.- Returns:
trueto initiator of the conversation.
-
isToMeOpened
boolean isToMeOpened()
Gettrueif receiving messages from the partner is possible.- Returns:
trueif receiving messages from the partner is possible
-
-