eneter.messaging.nodes.channelwrapper
Interface IDuplexChannelUnwrapper

All Superinterfaces:
IAttachableDuplexInputChannel

public interface IDuplexChannelUnwrapper
extends IAttachableDuplexInputChannel

Duplex channel unwrapper. The duplex channel wrapper is listening to more duplex input channels. When it receives some message, it wraps the message and sends it via the only duplex output channel. On the other side the message is received by duplex channel unwrapper. The unwrapper unwraps the message and uses the duplex output channel to forward the message to the correct receiver.
The receiver can also send the response message. Then it goes the same way back.
Notice, the 'duplex channel unwrapper' can communication only with 'duplex channel wrapper'. It cannot communicate with one-way 'channel wrapper'.


Method Summary
 java.lang.String getAssociatedResponseReceiverId(java.lang.String responseReceiverId)
          Returns response receiver id of the client connected to the unwrapper.
 Event<ResponseReceiverEventArgs> responseReceiverConnected()
          The event is invoked when the duplex channel wrapper opened the connection with this unwrapper via its duplex output channel.
 Event<ResponseReceiverEventArgs> responseReceiverDisconnected()
          The event is invoked when the duplex channel wrapper closed the connection with this unwrapper via its duplex output channel.
 
Methods inherited from interface eneter.messaging.infrastructure.attachable.IAttachableDuplexInputChannel
attachDuplexInputChannel, detachDuplexInputChannel, getAttachedDuplexInputChannel, isDuplexInputChannelAttached
 

Method Detail

responseReceiverConnected

Event<ResponseReceiverEventArgs> responseReceiverConnected()
The event is invoked when the duplex channel wrapper opened the connection with this unwrapper via its duplex output channel.

Returns:

responseReceiverDisconnected

Event<ResponseReceiverEventArgs> responseReceiverDisconnected()
The event is invoked when the duplex channel wrapper closed the connection with this unwrapper via its duplex output channel.

Returns:

getAssociatedResponseReceiverId

java.lang.String getAssociatedResponseReceiverId(java.lang.String responseReceiverId)
                                                 throws java.lang.Exception
Returns response receiver id of the client connected to the unwrapper.

Parameters:
responseReceiverId - responseRecieverId from unwrapped message
Returns:
responseReceiverId of the client connected to the channel unwrapper. Returns null if it does not exist.
Throws:
java.lang.Exception