public interface IMultiTypedMessageSender extends IAttachableDuplexOutputChannel
Modifier and Type | Method and Description |
---|---|
Event<DuplexChannelEventArgs> |
connectionClosed()
Raised when the service closed the connection with the client.
|
Event<DuplexChannelEventArgs> |
connectionOpened()
Raised when the connection with the receiver is open.
|
java.util.ArrayList<java.lang.Class<?>> |
getRegisteredResponseMessageTypes()
Returns the list of registered response message types which can be received.
|
<T> void |
registerResponseMessageReceiver(EventHandler<TypedResponseReceivedEventArgs<T>> handler,
java.lang.Class<T> clazz)
Registers response message handler for specified message type.
|
<TRequestMessage> |
sendRequestMessage(TRequestMessage message,
java.lang.Class<TRequestMessage> clazz)
Sends request message.
|
<T> void |
unregisterResponseMessageReceiver(java.lang.Class<T> clazz)
Unregisters the response message handler for the specified message type.
|
attachDuplexOutputChannel, detachDuplexOutputChannel, getAttachedDuplexOutputChannel, isDuplexOutputChannelAttached
Event<DuplexChannelEventArgs> connectionOpened()
Event<DuplexChannelEventArgs> connectionClosed()
<T> void registerResponseMessageReceiver(EventHandler<TypedResponseReceivedEventArgs<T>> handler, java.lang.Class<T> clazz) throws java.lang.Exception
handler
- response message handler.clazz
- type of the response message.java.lang.Exception
<T> void unregisterResponseMessageReceiver(java.lang.Class<T> clazz)
clazz
- java.util.ArrayList<java.lang.Class<?>> getRegisteredResponseMessageTypes()
<TRequestMessage> void sendRequestMessage(TRequestMessage message, java.lang.Class<TRequestMessage> clazz) throws java.lang.Exception
message
- request messageclazz
- type of the messagejava.lang.Exception