blob: c0d147c15071f97b0cdb4f10a2cb2b06af720a3b [file] [log] [blame]
Jan Tattermusch386bbdf2017-12-13 02:42:22 +01001// <auto-generated>
2// Generated by the protocol buffer compiler. DO NOT EDIT!
3// source: src/proto/grpc/testing/test.proto
4// </auto-generated>
Jan Tattermuschbfee01d2016-04-28 10:52:41 -07005// Original file comments:
Jan Tattermusch4d5c3102017-06-07 10:23:56 +02006// Copyright 2015-2016 gRPC authors.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -07007//
Jan Tattermusch4d5c3102017-06-07 10:23:56 +02008// Licensed under the Apache License, Version 2.0 (the "License");
9// you may not use this file except in compliance with the License.
10// You may obtain a copy of the License at
Jan Tattermuschbfee01d2016-04-28 10:52:41 -070011//
Jan Tattermusch4d5c3102017-06-07 10:23:56 +020012// http://www.apache.org/licenses/LICENSE-2.0
Jan Tattermuschbfee01d2016-04-28 10:52:41 -070013//
Jan Tattermusch4d5c3102017-06-07 10:23:56 +020014// Unless required by applicable law or agreed to in writing, software
15// distributed under the License is distributed on an "AS IS" BASIS,
16// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17// See the License for the specific language governing permissions and
18// limitations under the License.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -070019//
20// An integration test service that covers all the method signature permutations
21// of unary/streaming requests/responses.
22//
Jan Tattermuschca254732017-08-09 08:47:34 +020023#pragma warning disable 1591
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070024#region Designer generated code
25
26using System;
27using System.Threading;
28using System.Threading.Tasks;
Jan Tattermuschff4fc132017-03-14 09:27:50 +010029using grpc = global::Grpc.Core;
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070030
Jan Tattermusch5c42d8d2015-08-03 08:14:30 -070031namespace Grpc.Testing {
Jan Tattermuschbfee01d2016-04-28 10:52:41 -070032 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +010033 /// A simple service to test the various types of RPCs and experiment with
34 /// performance with various types of payload.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -070035 /// </summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -080036 public static partial class TestService
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070037 {
38 static readonly string __ServiceName = "grpc.testing.TestService";
39
Jan Tattermuschff4fc132017-03-14 09:27:50 +010040 static readonly grpc::Marshaller<global::Grpc.Testing.Empty> __Marshaller_Empty = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.Empty.Parser.ParseFrom);
41 static readonly grpc::Marshaller<global::Grpc.Testing.SimpleRequest> __Marshaller_SimpleRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.SimpleRequest.Parser.ParseFrom);
42 static readonly grpc::Marshaller<global::Grpc.Testing.SimpleResponse> __Marshaller_SimpleResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.SimpleResponse.Parser.ParseFrom);
43 static readonly grpc::Marshaller<global::Grpc.Testing.StreamingOutputCallRequest> __Marshaller_StreamingOutputCallRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.StreamingOutputCallRequest.Parser.ParseFrom);
44 static readonly grpc::Marshaller<global::Grpc.Testing.StreamingOutputCallResponse> __Marshaller_StreamingOutputCallResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.StreamingOutputCallResponse.Parser.ParseFrom);
45 static readonly grpc::Marshaller<global::Grpc.Testing.StreamingInputCallRequest> __Marshaller_StreamingInputCallRequest = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.StreamingInputCallRequest.Parser.ParseFrom);
46 static readonly grpc::Marshaller<global::Grpc.Testing.StreamingInputCallResponse> __Marshaller_StreamingInputCallResponse = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.StreamingInputCallResponse.Parser.ParseFrom);
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070047
Jan Tattermuschff4fc132017-03-14 09:27:50 +010048 static readonly grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty> __Method_EmptyCall = new grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty>(
49 grpc::MethodType.Unary,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070050 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070051 "EmptyCall",
52 __Marshaller_Empty,
53 __Marshaller_Empty);
54
Jan Tattermuschff4fc132017-03-14 09:27:50 +010055 static readonly grpc::Method<global::Grpc.Testing.SimpleRequest, global::Grpc.Testing.SimpleResponse> __Method_UnaryCall = new grpc::Method<global::Grpc.Testing.SimpleRequest, global::Grpc.Testing.SimpleResponse>(
56 grpc::MethodType.Unary,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070057 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070058 "UnaryCall",
59 __Marshaller_SimpleRequest,
60 __Marshaller_SimpleResponse);
61
Jan Tattermuschff4fc132017-03-14 09:27:50 +010062 static readonly grpc::Method<global::Grpc.Testing.SimpleRequest, global::Grpc.Testing.SimpleResponse> __Method_CacheableUnaryCall = new grpc::Method<global::Grpc.Testing.SimpleRequest, global::Grpc.Testing.SimpleResponse>(
63 grpc::MethodType.Unary,
Noah Eisenb2a26472016-10-21 16:43:57 -070064 __ServiceName,
65 "CacheableUnaryCall",
66 __Marshaller_SimpleRequest,
67 __Marshaller_SimpleResponse);
68
Jan Tattermuschff4fc132017-03-14 09:27:50 +010069 static readonly grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> __Method_StreamingOutputCall = new grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse>(
70 grpc::MethodType.ServerStreaming,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070071 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070072 "StreamingOutputCall",
73 __Marshaller_StreamingOutputCallRequest,
74 __Marshaller_StreamingOutputCallResponse);
75
Jan Tattermuschff4fc132017-03-14 09:27:50 +010076 static readonly grpc::Method<global::Grpc.Testing.StreamingInputCallRequest, global::Grpc.Testing.StreamingInputCallResponse> __Method_StreamingInputCall = new grpc::Method<global::Grpc.Testing.StreamingInputCallRequest, global::Grpc.Testing.StreamingInputCallResponse>(
77 grpc::MethodType.ClientStreaming,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070078 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070079 "StreamingInputCall",
80 __Marshaller_StreamingInputCallRequest,
81 __Marshaller_StreamingInputCallResponse);
82
Jan Tattermuschff4fc132017-03-14 09:27:50 +010083 static readonly grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> __Method_FullDuplexCall = new grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse>(
84 grpc::MethodType.DuplexStreaming,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070085 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070086 "FullDuplexCall",
87 __Marshaller_StreamingOutputCallRequest,
88 __Marshaller_StreamingOutputCallResponse);
89
Jan Tattermuschff4fc132017-03-14 09:27:50 +010090 static readonly grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> __Method_HalfDuplexCall = new grpc::Method<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse>(
91 grpc::MethodType.DuplexStreaming,
Jan Tattermuschcc97fed2015-08-05 00:44:29 -070092 __ServiceName,
Jan Tattermusch7eb3a762015-05-07 14:26:13 -070093 "HalfDuplexCall",
94 __Marshaller_StreamingOutputCallRequest,
95 __Marshaller_StreamingOutputCallResponse);
96
Jan Tattermuschff4fc132017-03-14 09:27:50 +010097 static readonly grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty> __Method_UnimplementedCall = new grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty>(
98 grpc::MethodType.Unary,
Noah Eisenb2a26472016-10-21 16:43:57 -070099 __ServiceName,
100 "UnimplementedCall",
101 __Marshaller_Empty,
102 __Marshaller_Empty);
103
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700104 /// <summary>Service descriptor</summary>
Jan Tattermusche6af5d12015-08-03 10:57:43 -0700105 public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
106 {
Jan Tattermusch72ce4422016-01-20 13:54:38 -0800107 get { return global::Grpc.Testing.TestReflection.Descriptor.Services[0]; }
Jan Tattermusche6af5d12015-08-03 10:57:43 -0700108 }
109
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700110 /// <summary>Base class for server-side implementations of TestService</summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -0800111 public abstract partial class TestServiceBase
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700112 {
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700113 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100114 /// One empty request followed by one empty response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700115 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100116 /// <param name="request">The request received from the client.</param>
117 /// <param name="context">The context of the server-side call handler being invoked.</param>
118 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100119 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.Empty> EmptyCall(global::Grpc.Testing.Empty request, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700120 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100121 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700122 }
123
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700124 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100125 /// One request followed by one response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700126 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100127 /// <param name="request">The request received from the client.</param>
128 /// <param name="context">The context of the server-side call handler being invoked.</param>
129 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100130 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.SimpleResponse> UnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700131 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100132 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700133 }
134
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700135 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100136 /// One request followed by one response. Response has cache control
137 /// headers set such that a caching HTTP proxy (such as GFE) can
138 /// satisfy subsequent requests.
Noah Eisenb2a26472016-10-21 16:43:57 -0700139 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100140 /// <param name="request">The request received from the client.</param>
141 /// <param name="context">The context of the server-side call handler being invoked.</param>
142 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100143 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.SimpleResponse> CacheableUnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::ServerCallContext context)
Noah Eisenb2a26472016-10-21 16:43:57 -0700144 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100145 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Noah Eisenb2a26472016-10-21 16:43:57 -0700146 }
147
148 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100149 /// One request followed by a sequence of responses (streamed download).
150 /// The server returns the payload with client desired type and sizes.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700151 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100152 /// <param name="request">The request received from the client.</param>
153 /// <param name="responseStream">Used for sending responses back to the client.</param>
154 /// <param name="context">The context of the server-side call handler being invoked.</param>
155 /// <returns>A task indicating completion of the handler.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100156 public virtual global::System.Threading.Tasks.Task StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, grpc::IServerStreamWriter<global::Grpc.Testing.StreamingOutputCallResponse> responseStream, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700157 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100158 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700159 }
160
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700161 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100162 /// A sequence of requests followed by one response (streamed upload).
163 /// The server returns the aggregated size of client payload as the result.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700164 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100165 /// <param name="requestStream">Used for reading requests from the client.</param>
166 /// <param name="context">The context of the server-side call handler being invoked.</param>
167 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100168 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.StreamingInputCallResponse> StreamingInputCall(grpc::IAsyncStreamReader<global::Grpc.Testing.StreamingInputCallRequest> requestStream, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700169 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100170 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700171 }
172
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700173 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100174 /// A sequence of requests with each request served by the server immediately.
175 /// As one request could lead to multiple responses, this interface
176 /// demonstrates the idea of full duplexing.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700177 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100178 /// <param name="requestStream">Used for reading requests from the client.</param>
179 /// <param name="responseStream">Used for sending responses back to the client.</param>
180 /// <param name="context">The context of the server-side call handler being invoked.</param>
181 /// <returns>A task indicating completion of the handler.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100182 public virtual global::System.Threading.Tasks.Task FullDuplexCall(grpc::IAsyncStreamReader<global::Grpc.Testing.StreamingOutputCallRequest> requestStream, grpc::IServerStreamWriter<global::Grpc.Testing.StreamingOutputCallResponse> responseStream, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700183 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100184 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700185 }
186
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700187 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100188 /// A sequence of requests followed by a sequence of responses.
189 /// The server buffers all the client requests and then serves them in order. A
190 /// stream of responses are returned to the client when the server starts with
191 /// first request.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700192 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100193 /// <param name="requestStream">Used for reading requests from the client.</param>
194 /// <param name="responseStream">Used for sending responses back to the client.</param>
195 /// <param name="context">The context of the server-side call handler being invoked.</param>
196 /// <returns>A task indicating completion of the handler.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100197 public virtual global::System.Threading.Tasks.Task HalfDuplexCall(grpc::IAsyncStreamReader<global::Grpc.Testing.StreamingOutputCallRequest> requestStream, grpc::IServerStreamWriter<global::Grpc.Testing.StreamingOutputCallResponse> responseStream, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700198 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100199 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700200 }
201
Noah Eisenb2a26472016-10-21 16:43:57 -0700202 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100203 /// The test server will not implement this method. It will be used
204 /// to test the behavior when clients call unimplemented methods.
Noah Eisenb2a26472016-10-21 16:43:57 -0700205 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100206 /// <param name="request">The request received from the client.</param>
207 /// <param name="context">The context of the server-side call handler being invoked.</param>
208 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100209 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.Empty> UnimplementedCall(global::Grpc.Testing.Empty request, grpc::ServerCallContext context)
Noah Eisenb2a26472016-10-21 16:43:57 -0700210 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100211 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Noah Eisenb2a26472016-10-21 16:43:57 -0700212 }
213
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700214 }
215
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700216 /// <summary>Client for TestService</summary>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100217 public partial class TestServiceClient : grpc::ClientBase<TestServiceClient>
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700218 {
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700219 /// <summary>Creates a new client for TestService</summary>
220 /// <param name="channel">The channel to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100221 public TestServiceClient(grpc::Channel channel) : base(channel)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700222 {
223 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700224 /// <summary>Creates a new client for TestService that uses a custom <c>CallInvoker</c>.</summary>
225 /// <param name="callInvoker">The callInvoker to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100226 public TestServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700227 {
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700228 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700229 /// <summary>Protected parameterless constructor to allow creation of test doubles.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700230 protected TestServiceClient() : base()
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700231 {
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700232 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700233 /// <summary>Protected constructor to allow creation of configured clients.</summary>
234 /// <param name="configuration">The client configuration.</param>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700235 protected TestServiceClient(ClientBaseConfiguration configuration) : base(configuration)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700236 {
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700237 }
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700238
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700239 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100240 /// One empty request followed by one empty response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700241 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100242 /// <param name="request">The request to send to the server.</param>
243 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
244 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
245 /// <param name="cancellationToken">An optional token for canceling the call.</param>
246 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100247 public virtual global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700248 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100249 return EmptyCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700250 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700251 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100252 /// One empty request followed by one empty response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700253 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100254 /// <param name="request">The request to send to the server.</param>
255 /// <param name="options">The options for the call.</param>
256 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100257 public virtual global::Grpc.Testing.Empty EmptyCall(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700258 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700259 return CallInvoker.BlockingUnaryCall(__Method_EmptyCall, null, options, request);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700260 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700261 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100262 /// One empty request followed by one empty response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700263 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100264 /// <param name="request">The request to send to the server.</param>
265 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
266 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
267 /// <param name="cancellationToken">An optional token for canceling the call.</param>
268 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100269 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> EmptyCallAsync(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700270 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100271 return EmptyCallAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700272 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700273 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100274 /// One empty request followed by one empty response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700275 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100276 /// <param name="request">The request to send to the server.</param>
277 /// <param name="options">The options for the call.</param>
278 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100279 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> EmptyCallAsync(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700280 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700281 return CallInvoker.AsyncUnaryCall(__Method_EmptyCall, null, options, request);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700282 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700283 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100284 /// One request followed by one response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700285 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100286 /// <param name="request">The request to send to the server.</param>
287 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
288 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
289 /// <param name="cancellationToken">An optional token for canceling the call.</param>
290 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100291 public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700292 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100293 return UnaryCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700294 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700295 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100296 /// One request followed by one response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700297 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100298 /// <param name="request">The request to send to the server.</param>
299 /// <param name="options">The options for the call.</param>
300 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100301 public virtual global::Grpc.Testing.SimpleResponse UnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700302 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700303 return CallInvoker.BlockingUnaryCall(__Method_UnaryCall, null, options, request);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700304 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700305 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100306 /// One request followed by one response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700307 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100308 /// <param name="request">The request to send to the server.</param>
309 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
310 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
311 /// <param name="cancellationToken">An optional token for canceling the call.</param>
312 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100313 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.SimpleResponse> UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700314 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100315 return UnaryCallAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700316 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700317 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100318 /// One request followed by one response.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700319 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100320 /// <param name="request">The request to send to the server.</param>
321 /// <param name="options">The options for the call.</param>
322 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100323 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.SimpleResponse> UnaryCallAsync(global::Grpc.Testing.SimpleRequest request, grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700324 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700325 return CallInvoker.AsyncUnaryCall(__Method_UnaryCall, null, options, request);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700326 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700327 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100328 /// One request followed by one response. Response has cache control
329 /// headers set such that a caching HTTP proxy (such as GFE) can
330 /// satisfy subsequent requests.
Noah Eisenb2a26472016-10-21 16:43:57 -0700331 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100332 /// <param name="request">The request to send to the server.</param>
333 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
334 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
335 /// <param name="cancellationToken">An optional token for canceling the call.</param>
336 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100337 public virtual global::Grpc.Testing.SimpleResponse CacheableUnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Noah Eisenb2a26472016-10-21 16:43:57 -0700338 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100339 return CacheableUnaryCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Noah Eisenb2a26472016-10-21 16:43:57 -0700340 }
341 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100342 /// One request followed by one response. Response has cache control
343 /// headers set such that a caching HTTP proxy (such as GFE) can
344 /// satisfy subsequent requests.
Noah Eisenb2a26472016-10-21 16:43:57 -0700345 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100346 /// <param name="request">The request to send to the server.</param>
347 /// <param name="options">The options for the call.</param>
348 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100349 public virtual global::Grpc.Testing.SimpleResponse CacheableUnaryCall(global::Grpc.Testing.SimpleRequest request, grpc::CallOptions options)
Noah Eisenb2a26472016-10-21 16:43:57 -0700350 {
351 return CallInvoker.BlockingUnaryCall(__Method_CacheableUnaryCall, null, options, request);
352 }
353 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100354 /// One request followed by one response. Response has cache control
355 /// headers set such that a caching HTTP proxy (such as GFE) can
356 /// satisfy subsequent requests.
Noah Eisenb2a26472016-10-21 16:43:57 -0700357 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100358 /// <param name="request">The request to send to the server.</param>
359 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
360 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
361 /// <param name="cancellationToken">An optional token for canceling the call.</param>
362 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100363 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.SimpleResponse> CacheableUnaryCallAsync(global::Grpc.Testing.SimpleRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Noah Eisenb2a26472016-10-21 16:43:57 -0700364 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100365 return CacheableUnaryCallAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Noah Eisenb2a26472016-10-21 16:43:57 -0700366 }
367 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100368 /// One request followed by one response. Response has cache control
369 /// headers set such that a caching HTTP proxy (such as GFE) can
370 /// satisfy subsequent requests.
Noah Eisenb2a26472016-10-21 16:43:57 -0700371 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100372 /// <param name="request">The request to send to the server.</param>
373 /// <param name="options">The options for the call.</param>
374 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100375 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.SimpleResponse> CacheableUnaryCallAsync(global::Grpc.Testing.SimpleRequest request, grpc::CallOptions options)
Noah Eisenb2a26472016-10-21 16:43:57 -0700376 {
377 return CallInvoker.AsyncUnaryCall(__Method_CacheableUnaryCall, null, options, request);
378 }
379 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100380 /// One request followed by a sequence of responses (streamed download).
381 /// The server returns the payload with client desired type and sizes.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700382 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100383 /// <param name="request">The request to send to the server.</param>
384 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
385 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
386 /// <param name="cancellationToken">An optional token for canceling the call.</param>
387 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100388 public virtual grpc::AsyncServerStreamingCall<global::Grpc.Testing.StreamingOutputCallResponse> StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700389 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100390 return StreamingOutputCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700391 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700392 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100393 /// One request followed by a sequence of responses (streamed download).
394 /// The server returns the payload with client desired type and sizes.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700395 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100396 /// <param name="request">The request to send to the server.</param>
397 /// <param name="options">The options for the call.</param>
398 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100399 public virtual grpc::AsyncServerStreamingCall<global::Grpc.Testing.StreamingOutputCallResponse> StreamingOutputCall(global::Grpc.Testing.StreamingOutputCallRequest request, grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700400 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700401 return CallInvoker.AsyncServerStreamingCall(__Method_StreamingOutputCall, null, options, request);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700402 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700403 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100404 /// A sequence of requests followed by one response (streamed upload).
405 /// The server returns the aggregated size of client payload as the result.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700406 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100407 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
408 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
409 /// <param name="cancellationToken">An optional token for canceling the call.</param>
410 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100411 public virtual grpc::AsyncClientStreamingCall<global::Grpc.Testing.StreamingInputCallRequest, global::Grpc.Testing.StreamingInputCallResponse> StreamingInputCall(grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700412 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100413 return StreamingInputCall(new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700414 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700415 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100416 /// A sequence of requests followed by one response (streamed upload).
417 /// The server returns the aggregated size of client payload as the result.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700418 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100419 /// <param name="options">The options for the call.</param>
420 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100421 public virtual grpc::AsyncClientStreamingCall<global::Grpc.Testing.StreamingInputCallRequest, global::Grpc.Testing.StreamingInputCallResponse> StreamingInputCall(grpc::CallOptions options)
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700422 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700423 return CallInvoker.AsyncClientStreamingCall(__Method_StreamingInputCall, null, options);
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700424 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700425 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100426 /// A sequence of requests with each request served by the server immediately.
427 /// As one request could lead to multiple responses, this interface
428 /// demonstrates the idea of full duplexing.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700429 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100430 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
431 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
432 /// <param name="cancellationToken">An optional token for canceling the call.</param>
433 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100434 public virtual grpc::AsyncDuplexStreamingCall<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> FullDuplexCall(grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschcc97fed2015-08-05 00:44:29 -0700435 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100436 return FullDuplexCall(new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700437 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700438 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100439 /// A sequence of requests with each request served by the server immediately.
440 /// As one request could lead to multiple responses, this interface
441 /// demonstrates the idea of full duplexing.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700442 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100443 /// <param name="options">The options for the call.</param>
444 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100445 public virtual grpc::AsyncDuplexStreamingCall<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> FullDuplexCall(grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700446 {
447 return CallInvoker.AsyncDuplexStreamingCall(__Method_FullDuplexCall, null, options);
448 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700449 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100450 /// A sequence of requests followed by a sequence of responses.
451 /// The server buffers all the client requests and then serves them in order. A
452 /// stream of responses are returned to the client when the server starts with
453 /// first request.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700454 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100455 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
456 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
457 /// <param name="cancellationToken">An optional token for canceling the call.</param>
458 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100459 public virtual grpc::AsyncDuplexStreamingCall<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> HalfDuplexCall(grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700460 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100461 return HalfDuplexCall(new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700462 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700463 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100464 /// A sequence of requests followed by a sequence of responses.
465 /// The server buffers all the client requests and then serves them in order. A
466 /// stream of responses are returned to the client when the server starts with
467 /// first request.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700468 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100469 /// <param name="options">The options for the call.</param>
470 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100471 public virtual grpc::AsyncDuplexStreamingCall<global::Grpc.Testing.StreamingOutputCallRequest, global::Grpc.Testing.StreamingOutputCallResponse> HalfDuplexCall(grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700472 {
473 return CallInvoker.AsyncDuplexStreamingCall(__Method_HalfDuplexCall, null, options);
474 }
Noah Eisenb2a26472016-10-21 16:43:57 -0700475 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100476 /// The test server will not implement this method. It will be used
477 /// to test the behavior when clients call unimplemented methods.
Noah Eisenb2a26472016-10-21 16:43:57 -0700478 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100479 /// <param name="request">The request to send to the server.</param>
480 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
481 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
482 /// <param name="cancellationToken">An optional token for canceling the call.</param>
483 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100484 public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Noah Eisenb2a26472016-10-21 16:43:57 -0700485 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100486 return UnimplementedCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Noah Eisenb2a26472016-10-21 16:43:57 -0700487 }
488 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100489 /// The test server will not implement this method. It will be used
490 /// to test the behavior when clients call unimplemented methods.
Noah Eisenb2a26472016-10-21 16:43:57 -0700491 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100492 /// <param name="request">The request to send to the server.</param>
493 /// <param name="options">The options for the call.</param>
494 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100495 public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Noah Eisenb2a26472016-10-21 16:43:57 -0700496 {
497 return CallInvoker.BlockingUnaryCall(__Method_UnimplementedCall, null, options, request);
498 }
499 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100500 /// The test server will not implement this method. It will be used
501 /// to test the behavior when clients call unimplemented methods.
Noah Eisenb2a26472016-10-21 16:43:57 -0700502 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100503 /// <param name="request">The request to send to the server.</param>
504 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
505 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
506 /// <param name="cancellationToken">An optional token for canceling the call.</param>
507 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100508 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> UnimplementedCallAsync(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Noah Eisenb2a26472016-10-21 16:43:57 -0700509 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100510 return UnimplementedCallAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Noah Eisenb2a26472016-10-21 16:43:57 -0700511 }
512 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100513 /// The test server will not implement this method. It will be used
514 /// to test the behavior when clients call unimplemented methods.
Noah Eisenb2a26472016-10-21 16:43:57 -0700515 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100516 /// <param name="request">The request to send to the server.</param>
517 /// <param name="options">The options for the call.</param>
518 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100519 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> UnimplementedCallAsync(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Noah Eisenb2a26472016-10-21 16:43:57 -0700520 {
521 return CallInvoker.AsyncUnaryCall(__Method_UnimplementedCall, null, options, request);
522 }
Jan Tattermusch10098d12016-10-06 13:15:12 +0200523 /// <summary>Creates a new instance of client from given <c>ClientBaseConfiguration</c>.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700524 protected override TestServiceClient NewInstance(ClientBaseConfiguration configuration)
525 {
526 return new TestServiceClient(configuration);
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700527 }
528 }
529
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700530 /// <summary>Creates service definition that can be registered with a server</summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100531 /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100532 public static grpc::ServerServiceDefinition BindService(TestServiceBase serviceImpl)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700533 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100534 return grpc::ServerServiceDefinition.CreateBuilder()
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700535 .AddMethod(__Method_EmptyCall, serviceImpl.EmptyCall)
536 .AddMethod(__Method_UnaryCall, serviceImpl.UnaryCall)
Noah Eisenb2a26472016-10-21 16:43:57 -0700537 .AddMethod(__Method_CacheableUnaryCall, serviceImpl.CacheableUnaryCall)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700538 .AddMethod(__Method_StreamingOutputCall, serviceImpl.StreamingOutputCall)
539 .AddMethod(__Method_StreamingInputCall, serviceImpl.StreamingInputCall)
540 .AddMethod(__Method_FullDuplexCall, serviceImpl.FullDuplexCall)
Noah Eisenb2a26472016-10-21 16:43:57 -0700541 .AddMethod(__Method_HalfDuplexCall, serviceImpl.HalfDuplexCall)
542 .AddMethod(__Method_UnimplementedCall, serviceImpl.UnimplementedCall).Build();
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700543 }
544
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700545 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700546 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100547 /// A simple service NOT implemented at servers so clients can test for
548 /// that case.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700549 /// </summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -0800550 public static partial class UnimplementedService
Jan Tattermusch70f86522015-10-07 18:23:51 -0700551 {
552 static readonly string __ServiceName = "grpc.testing.UnimplementedService";
553
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100554 static readonly grpc::Marshaller<global::Grpc.Testing.Empty> __Marshaller_Empty = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.Empty.Parser.ParseFrom);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700555
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100556 static readonly grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty> __Method_UnimplementedCall = new grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.Empty>(
557 grpc::MethodType.Unary,
Jan Tattermusch70f86522015-10-07 18:23:51 -0700558 __ServiceName,
559 "UnimplementedCall",
560 __Marshaller_Empty,
561 __Marshaller_Empty);
562
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700563 /// <summary>Service descriptor</summary>
Jan Tattermusch70f86522015-10-07 18:23:51 -0700564 public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
565 {
Jan Tattermusch72ce4422016-01-20 13:54:38 -0800566 get { return global::Grpc.Testing.TestReflection.Descriptor.Services[1]; }
Jan Tattermusch70f86522015-10-07 18:23:51 -0700567 }
568
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700569 /// <summary>Base class for server-side implementations of UnimplementedService</summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -0800570 public abstract partial class UnimplementedServiceBase
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700571 {
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700572 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100573 /// A call that no server should implement
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700574 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100575 /// <param name="request">The request received from the client.</param>
576 /// <param name="context">The context of the server-side call handler being invoked.</param>
577 /// <returns>The response to send back to the client (wrapped by a task).</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100578 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.Empty> UnimplementedCall(global::Grpc.Testing.Empty request, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700579 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100580 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700581 }
582
583 }
584
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700585 /// <summary>Client for UnimplementedService</summary>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100586 public partial class UnimplementedServiceClient : grpc::ClientBase<UnimplementedServiceClient>
Jan Tattermusch70f86522015-10-07 18:23:51 -0700587 {
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700588 /// <summary>Creates a new client for UnimplementedService</summary>
589 /// <param name="channel">The channel to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100590 public UnimplementedServiceClient(grpc::Channel channel) : base(channel)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700591 {
592 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700593 /// <summary>Creates a new client for UnimplementedService that uses a custom <c>CallInvoker</c>.</summary>
594 /// <param name="callInvoker">The callInvoker to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100595 public UnimplementedServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700596 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700597 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700598 /// <summary>Protected parameterless constructor to allow creation of test doubles.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700599 protected UnimplementedServiceClient() : base()
Jan Tattermusch70f86522015-10-07 18:23:51 -0700600 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700601 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700602 /// <summary>Protected constructor to allow creation of configured clients.</summary>
603 /// <param name="configuration">The client configuration.</param>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700604 protected UnimplementedServiceClient(ClientBaseConfiguration configuration) : base(configuration)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700605 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700606 }
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700607
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700608 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100609 /// A call that no server should implement
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700610 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100611 /// <param name="request">The request to send to the server.</param>
612 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
613 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
614 /// <param name="cancellationToken">An optional token for canceling the call.</param>
615 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100616 public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermusch70f86522015-10-07 18:23:51 -0700617 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100618 return UnimplementedCall(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700619 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700620 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100621 /// A call that no server should implement
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700622 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100623 /// <param name="request">The request to send to the server.</param>
624 /// <param name="options">The options for the call.</param>
625 /// <returns>The response received from the server.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100626 public virtual global::Grpc.Testing.Empty UnimplementedCall(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700627 {
628 return CallInvoker.BlockingUnaryCall(__Method_UnimplementedCall, null, options, request);
629 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700630 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100631 /// A call that no server should implement
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700632 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100633 /// <param name="request">The request to send to the server.</param>
634 /// <param name="headers">The initial metadata to send with the call. This parameter is optional.</param>
635 /// <param name="deadline">An optional deadline for the call. The call will be cancelled if deadline is hit.</param>
636 /// <param name="cancellationToken">An optional token for canceling the call.</param>
637 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100638 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> UnimplementedCallAsync(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700639 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100640 return UnimplementedCallAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700641 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700642 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100643 /// A call that no server should implement
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700644 /// </summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100645 /// <param name="request">The request to send to the server.</param>
646 /// <param name="options">The options for the call.</param>
647 /// <returns>The call object.</returns>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100648 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> UnimplementedCallAsync(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700649 {
650 return CallInvoker.AsyncUnaryCall(__Method_UnimplementedCall, null, options, request);
651 }
Jan Tattermusch10098d12016-10-06 13:15:12 +0200652 /// <summary>Creates a new instance of client from given <c>ClientBaseConfiguration</c>.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700653 protected override UnimplementedServiceClient NewInstance(ClientBaseConfiguration configuration)
654 {
655 return new UnimplementedServiceClient(configuration);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700656 }
657 }
658
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700659 /// <summary>Creates service definition that can be registered with a server</summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100660 /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100661 public static grpc::ServerServiceDefinition BindService(UnimplementedServiceBase serviceImpl)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700662 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100663 return grpc::ServerServiceDefinition.CreateBuilder()
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700664 .AddMethod(__Method_UnimplementedCall, serviceImpl.UnimplementedCall).Build();
665 }
666
Jan Tattermusch70f86522015-10-07 18:23:51 -0700667 }
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700668 /// <summary>
Jan Tattermusch726f40f2016-12-12 12:09:35 +0100669 /// A service used to control reconnect server.
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700670 /// </summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -0800671 public static partial class ReconnectService
Jan Tattermusch70f86522015-10-07 18:23:51 -0700672 {
673 static readonly string __ServiceName = "grpc.testing.ReconnectService";
674
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100675 static readonly grpc::Marshaller<global::Grpc.Testing.ReconnectParams> __Marshaller_ReconnectParams = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.ReconnectParams.Parser.ParseFrom);
676 static readonly grpc::Marshaller<global::Grpc.Testing.Empty> __Marshaller_Empty = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.Empty.Parser.ParseFrom);
677 static readonly grpc::Marshaller<global::Grpc.Testing.ReconnectInfo> __Marshaller_ReconnectInfo = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.ReconnectInfo.Parser.ParseFrom);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700678
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100679 static readonly grpc::Method<global::Grpc.Testing.ReconnectParams, global::Grpc.Testing.Empty> __Method_Start = new grpc::Method<global::Grpc.Testing.ReconnectParams, global::Grpc.Testing.Empty>(
680 grpc::MethodType.Unary,
Jan Tattermusch70f86522015-10-07 18:23:51 -0700681 __ServiceName,
682 "Start",
vjpai87bac952016-04-20 09:35:35 -0700683 __Marshaller_ReconnectParams,
Jan Tattermusch70f86522015-10-07 18:23:51 -0700684 __Marshaller_Empty);
685
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100686 static readonly grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.ReconnectInfo> __Method_Stop = new grpc::Method<global::Grpc.Testing.Empty, global::Grpc.Testing.ReconnectInfo>(
687 grpc::MethodType.Unary,
Jan Tattermusch70f86522015-10-07 18:23:51 -0700688 __ServiceName,
689 "Stop",
690 __Marshaller_Empty,
691 __Marshaller_ReconnectInfo);
692
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700693 /// <summary>Service descriptor</summary>
Jan Tattermusch70f86522015-10-07 18:23:51 -0700694 public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
695 {
Jan Tattermusch72ce4422016-01-20 13:54:38 -0800696 get { return global::Grpc.Testing.TestReflection.Descriptor.Services[2]; }
Jan Tattermusch70f86522015-10-07 18:23:51 -0700697 }
698
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700699 /// <summary>Base class for server-side implementations of ReconnectService</summary>
Alexander Polcync0f4c2c2016-11-07 10:24:35 -0800700 public abstract partial class ReconnectServiceBase
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700701 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100702 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.Empty> Start(global::Grpc.Testing.ReconnectParams request, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700703 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100704 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700705 }
706
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100707 public virtual global::System.Threading.Tasks.Task<global::Grpc.Testing.ReconnectInfo> Stop(global::Grpc.Testing.Empty request, grpc::ServerCallContext context)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700708 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100709 throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700710 }
711
712 }
713
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700714 /// <summary>Client for ReconnectService</summary>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100715 public partial class ReconnectServiceClient : grpc::ClientBase<ReconnectServiceClient>
Jan Tattermusch70f86522015-10-07 18:23:51 -0700716 {
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700717 /// <summary>Creates a new client for ReconnectService</summary>
718 /// <param name="channel">The channel to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100719 public ReconnectServiceClient(grpc::Channel channel) : base(channel)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700720 {
721 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700722 /// <summary>Creates a new client for ReconnectService that uses a custom <c>CallInvoker</c>.</summary>
723 /// <param name="callInvoker">The callInvoker to use to make remote calls.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100724 public ReconnectServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700725 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700726 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700727 /// <summary>Protected parameterless constructor to allow creation of test doubles.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700728 protected ReconnectServiceClient() : base()
Jan Tattermusch70f86522015-10-07 18:23:51 -0700729 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700730 }
Jan Tattermusched6ea4c2016-06-22 12:38:44 -0700731 /// <summary>Protected constructor to allow creation of configured clients.</summary>
732 /// <param name="configuration">The client configuration.</param>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700733 protected ReconnectServiceClient(ClientBaseConfiguration configuration) : base(configuration)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700734 {
Jan Tattermusch70f86522015-10-07 18:23:51 -0700735 }
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700736
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100737 public virtual global::Grpc.Testing.Empty Start(global::Grpc.Testing.ReconnectParams request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermusch70f86522015-10-07 18:23:51 -0700738 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100739 return Start(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch70f86522015-10-07 18:23:51 -0700740 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100741 public virtual global::Grpc.Testing.Empty Start(global::Grpc.Testing.ReconnectParams request, grpc::CallOptions options)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700742 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700743 return CallInvoker.BlockingUnaryCall(__Method_Start, null, options, request);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700744 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100745 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> StartAsync(global::Grpc.Testing.ReconnectParams request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermusch70f86522015-10-07 18:23:51 -0700746 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100747 return StartAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermusch70f86522015-10-07 18:23:51 -0700748 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100749 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.Empty> StartAsync(global::Grpc.Testing.ReconnectParams request, grpc::CallOptions options)
Jan Tattermusch70f86522015-10-07 18:23:51 -0700750 {
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700751 return CallInvoker.AsyncUnaryCall(__Method_Start, null, options, request);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700752 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100753 public virtual global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermusch70f86522015-10-07 18:23:51 -0700754 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100755 return Stop(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700756 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100757 public virtual global::Grpc.Testing.ReconnectInfo Stop(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700758 {
759 return CallInvoker.BlockingUnaryCall(__Method_Stop, null, options, request);
760 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100761 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.ReconnectInfo> StopAsync(global::Grpc.Testing.Empty request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700762 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100763 return StopAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700764 }
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100765 public virtual grpc::AsyncUnaryCall<global::Grpc.Testing.ReconnectInfo> StopAsync(global::Grpc.Testing.Empty request, grpc::CallOptions options)
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700766 {
767 return CallInvoker.AsyncUnaryCall(__Method_Stop, null, options, request);
768 }
Jan Tattermusch10098d12016-10-06 13:15:12 +0200769 /// <summary>Creates a new instance of client from given <c>ClientBaseConfiguration</c>.</summary>
Jan Tattermuschddc4e342016-03-21 19:03:14 -0700770 protected override ReconnectServiceClient NewInstance(ClientBaseConfiguration configuration)
771 {
772 return new ReconnectServiceClient(configuration);
Jan Tattermusch70f86522015-10-07 18:23:51 -0700773 }
774 }
775
Jan Tattermuschbfee01d2016-04-28 10:52:41 -0700776 /// <summary>Creates service definition that can be registered with a server</summary>
Jan Tattermusch00f66362016-12-12 13:02:29 +0100777 /// <param name="serviceImpl">An object implementing the server-side handling logic.</param>
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100778 public static grpc::ServerServiceDefinition BindService(ReconnectServiceBase serviceImpl)
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700779 {
Jan Tattermuschff4fc132017-03-14 09:27:50 +0100780 return grpc::ServerServiceDefinition.CreateBuilder()
Jan Tattermuscheeef5ed2016-03-14 16:08:39 -0700781 .AddMethod(__Method_Start, serviceImpl.Start)
782 .AddMethod(__Method_Stop, serviceImpl.Stop).Build();
783 }
784
Jan Tattermusch70f86522015-10-07 18:23:51 -0700785 }
Jan Tattermusch7eb3a762015-05-07 14:26:13 -0700786}
Jan Tattermuschcd7e3132015-05-07 15:10:23 -0700787#endregion