public class SmartSockets extends cMsgSubdomainAdapter
UDL: cMsg:cMsg://host:port/SmartSockets/projectName
| Constructor and Description |
|---|
SmartSockets() |
| Modifier and Type | Method and Description |
|---|---|
void |
handleClientShutdown()
Close connection to smartsockets server.
|
void |
handleSendRequest(cMsgMessageFull msg)
Forwards message to smartsockets system.
|
void |
handleSubscribeRequest(java.lang.String subject,
java.lang.String type,
int id)
Subscribe to receive smartsockets messages.
|
void |
handleUnsubscribeRequest(java.lang.String subject,
java.lang.String type,
int id)
Unsubscribe smartsockets subscription.
|
boolean |
hasSend()
Method to tell if the "send" cMsg API function is implemented
by this interface implementation in the "handleSendRequest"
method.
|
boolean |
hasSubscribe()
Method to tell if the "subscribe" cMsg API function is implemented
by this interface implementation in the "handleSubscribeRequest"
method.
|
boolean |
hasUnsubscribe()
Method to tell if the "unsubscribe" cMsg API function is implemented
by this interface implementation in the "handleUnsubscribeRequest"
method.
|
void |
registerClient(cMsgClientInfo info)
Connect to smartsockets server.
|
void |
setUDLRemainder(java.lang.String UDLRemainder)
Method to give the subdomain handler the appropriate part
of the UDL the client used to talk to the domain server.
|
handleSendAndGetRequest, handleShutdownClientsRequest, handleSubscribeAndGetRequest, handleSyncSendRequest, handleUnSendAndGetRequest, handleUnsubscribeAndGetRequest, hasSendAndGet, hasShutdown, hasSubscribeAndGet, hasSyncSendpublic boolean hasSend()
hasSend in interface cMsgSubdomainInterfacehasSend in class cMsgSubdomainAdapterpublic boolean hasSubscribe()
hasSubscribe in interface cMsgSubdomainInterfacehasSubscribe in class cMsgSubdomainAdapterpublic boolean hasUnsubscribe()
hasUnsubscribe in interface cMsgSubdomainInterfacehasUnsubscribe in class cMsgSubdomainAdapterpublic void setUDLRemainder(java.lang.String UDLRemainder)
throws cMsgException
setUDLRemainder in interface cMsgSubdomainInterfacesetUDLRemainder in class cMsgSubdomainAdapterUDLRemainder - last part of the UDL appropriate to the subdomain handlercMsgException - neverpublic void registerClient(cMsgClientInfo info) throws cMsgException
registerClient in interface cMsgSubdomainInterfaceregisterClient in class cMsgSubdomainAdapterinfo - contains all client infocMsgException - if cannot connect to smartsockets serverpublic void handleSendRequest(cMsgMessageFull msg) throws cMsgException
handleSendRequest in interface cMsgSubdomainInterfacehandleSendRequest in class cMsgSubdomainAdaptermsg - message from sendercMsgException - if cannot forward messagepublic void handleSubscribeRequest(java.lang.String subject,
java.lang.String type,
int id)
throws cMsgException
handleSubscribeRequest in interface cMsgSubdomainInterfacehandleSubscribeRequest in class cMsgSubdomainAdaptersubject - subject subscribed totype - type subscribed toid - unique idcMsgException - if cannot subscribepublic void handleUnsubscribeRequest(java.lang.String subject,
java.lang.String type,
int id)
handleUnsubscribeRequest in interface cMsgSubdomainInterfacehandleUnsubscribeRequest in class cMsgSubdomainAdaptersubject - subject of subscriptiontype - type of subscriptionid - unique idpublic void handleClientShutdown()
throws cMsgException
handleClientShutdown in interface cMsgSubdomainInterfacehandleClientShutdown in class cMsgSubdomainAdaptercMsgException - never