Пример #1
0
        /// <inheritdoc/>
        public PublishMessageResponse PublishMessage(PublishMessageRequest request)
        {
            request.TopicName = this.TopicName;

            var marshaller   = new PublishMessageRequestMarshaller();
            var unmarshaller = PublishMessageResponseUnmarshaller.Instance;

            return(_serviceClient.Invoke <PublishMessageRequest, PublishMessageResponse>(request, marshaller, unmarshaller));
        }
Пример #2
0
        public async Task <PublishMessageResponse> PublishMessageAsync(PublishMessageRequest request)
        {
            request.TopicName = this.TopicName;

            var marshaller   = new PublishMessageRequestMarshaller();
            var unmarshaller = PublishMessageResponseUnmarshaller.Instance;

            return(await _serviceClient.InvokeAsync <PublishMessageRequest, PublishMessageResponse>(request, marshaller, unmarshaller).ConfigureAwait(false));
        }
Пример #3
0
        /// <inheritdoc/>
        public IAsyncResult BeginPublishMessage(PublishMessageRequest request, AsyncCallback callback, object state)
        {
            request.TopicName = this.TopicName;

            var marshaller   = new PublishMessageRequestMarshaller();
            var unmarshaller = PublishMessageResponseUnmarshaller.Instance;

            return(_serviceClient.BeginInvoke <PublishMessageRequest>(request, marshaller, unmarshaller,
                                                                      callback, state));
        }