Example #1
0
        public virtual bool TryGetContext <TMessage>(out IBusPublishContext <TMessage> context)
            where TMessage : class
        {
            context = PublishContext <TMessage> .FromMessage(_message, this);

            return(context != null);
        }
Example #2
0
        public static PublishContext <T> CreatePublishContext <T>(T message)
            where T : class
        {
            PublishContext <T> publishContext = PublishContext <T> .FromMessage(message);

            SetReceiveContextForSend(publishContext);

            return(publishContext);
        }