Package com.yahoo.messagebus
Class SendProxy
java.lang.Object
com.yahoo.messagebus.SendProxy
- All Implemented Interfaces:
MessageHandler,ReplyHandler
This class owns a message that is being sent by message bus. Once a reply is received, the message is attached to it
and returned to the application. This also implements the discard policy of
RoutingNode.- Author:
- Simon Thoresen Hult
-
Constructor Summary
ConstructorsConstructorDescriptionSendProxy(MessageBus mbus, Network net, Resender resender) Constructs a new instance of this class to maintain sending of a single message. -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleMessage(Message msg) This function is called when a message arrives.voidhandleReply(Reply reply) This function is called when a reply arrives.
-
Constructor Details
-
SendProxy
Constructs a new instance of this class to maintain sending of a single message.- Parameters:
mbus- The message bus that owns this.net- The network layer to transmit through.resender- The resender to use.
-
-
Method Details
-
handleMessage
Description copied from interface:MessageHandlerThis function is called when a message arrives.- Specified by:
handleMessagein interfaceMessageHandler- Parameters:
msg- The message that arrived.
-
handleReply
Description copied from interface:ReplyHandlerThis function is called when a reply arrives.- Specified by:
handleReplyin interfaceReplyHandler- Parameters:
reply- The reply that arrived.
-