blob: 261a088f56be5be42cc4372e47f2e159d5089475 [file] [log] [blame]
nmittlerf8314582015-01-27 10:25:39 -08001package io.grpc.testing.integration;
zhangkun835e607852015-01-22 12:31:56 -08002
Kun Zhang2ee4d022015-06-04 16:39:25 -07003import static io.grpc.stub.ClientCalls.createMethodDescriptor;
4import static io.grpc.stub.ClientCalls.asyncUnaryCall;
5import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
6import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
7import static io.grpc.stub.ClientCalls.duplexStreamingCall;
8import static io.grpc.stub.ClientCalls.blockingUnaryCall;
9import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
10import static io.grpc.stub.ClientCalls.unaryFutureCall;
nmittlerf8314582015-01-27 10:25:39 -080011import static io.grpc.stub.ServerCalls.createMethodDefinition;
12import static io.grpc.stub.ServerCalls.asyncUnaryRequestCall;
13import static io.grpc.stub.ServerCalls.asyncStreamingRequestCall;
zhangkun835e607852015-01-22 12:31:56 -080014
15@javax.annotation.Generated("by gRPC proto compiler")
16public class TestServiceGrpc {
17
nmittlerf8314582015-01-27 10:25:39 -080018 private static final io.grpc.stub.Method<io.grpc.testing.integration.Test.SimpleRequest,
19 io.grpc.testing.integration.Test.SimpleResponse> METHOD_UNARY_CALL =
20 io.grpc.stub.Method.create(
21 io.grpc.MethodType.UNARY, "UnaryCall",
Kun Zhangaf9fb6d2015-06-30 16:08:46 -070022 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.SimpleRequest.parser()),
23 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.SimpleResponse.parser()));
nmittlerf8314582015-01-27 10:25:39 -080024 private static final io.grpc.stub.Method<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
25 io.grpc.testing.integration.Test.StreamingOutputCallResponse> METHOD_STREAMING_OUTPUT_CALL =
26 io.grpc.stub.Method.create(
27 io.grpc.MethodType.SERVER_STREAMING, "StreamingOutputCall",
Kun Zhangaf9fb6d2015-06-30 16:08:46 -070028 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallRequest.parser()),
29 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallResponse.parser()));
nmittlerf8314582015-01-27 10:25:39 -080030 private static final io.grpc.stub.Method<io.grpc.testing.integration.Test.StreamingInputCallRequest,
31 io.grpc.testing.integration.Test.StreamingInputCallResponse> METHOD_STREAMING_INPUT_CALL =
32 io.grpc.stub.Method.create(
33 io.grpc.MethodType.CLIENT_STREAMING, "StreamingInputCall",
Kun Zhangaf9fb6d2015-06-30 16:08:46 -070034 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingInputCallRequest.parser()),
35 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingInputCallResponse.parser()));
nmittlerf8314582015-01-27 10:25:39 -080036 private static final io.grpc.stub.Method<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
37 io.grpc.testing.integration.Test.StreamingOutputCallResponse> METHOD_FULL_DUPLEX_CALL =
38 io.grpc.stub.Method.create(
39 io.grpc.MethodType.DUPLEX_STREAMING, "FullDuplexCall",
Kun Zhangaf9fb6d2015-06-30 16:08:46 -070040 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallRequest.parser()),
41 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallResponse.parser()));
nmittlerf8314582015-01-27 10:25:39 -080042 private static final io.grpc.stub.Method<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
43 io.grpc.testing.integration.Test.StreamingOutputCallResponse> METHOD_HALF_DUPLEX_CALL =
44 io.grpc.stub.Method.create(
45 io.grpc.MethodType.DUPLEX_STREAMING, "HalfDuplexCall",
Kun Zhangaf9fb6d2015-06-30 16:08:46 -070046 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallRequest.parser()),
47 io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.integration.Test.StreamingOutputCallResponse.parser()));
zhangkun835e607852015-01-22 12:31:56 -080048
nmittlerf8314582015-01-27 10:25:39 -080049 public static TestServiceStub newStub(io.grpc.Channel channel) {
zhangkun835e607852015-01-22 12:31:56 -080050 return new TestServiceStub(channel, CONFIG);
51 }
52
53 public static TestServiceBlockingStub newBlockingStub(
nmittlerf8314582015-01-27 10:25:39 -080054 io.grpc.Channel channel) {
zhangkun835e607852015-01-22 12:31:56 -080055 return new TestServiceBlockingStub(channel, CONFIG);
56 }
57
58 public static TestServiceFutureStub newFutureStub(
nmittlerf8314582015-01-27 10:25:39 -080059 io.grpc.Channel channel) {
zhangkun835e607852015-01-22 12:31:56 -080060 return new TestServiceFutureStub(channel, CONFIG);
61 }
62
63 public static final TestServiceServiceDescriptor CONFIG =
64 new TestServiceServiceDescriptor();
65
66 @javax.annotation.concurrent.Immutable
67 public static class TestServiceServiceDescriptor extends
nmittlerf8314582015-01-27 10:25:39 -080068 io.grpc.stub.AbstractServiceDescriptor<TestServiceServiceDescriptor> {
69 public final io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.SimpleRequest,
70 io.grpc.testing.integration.Test.SimpleResponse> unaryCall;
71 public final io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
72 io.grpc.testing.integration.Test.StreamingOutputCallResponse> streamingOutputCall;
73 public final io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingInputCallRequest,
74 io.grpc.testing.integration.Test.StreamingInputCallResponse> streamingInputCall;
75 public final io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
76 io.grpc.testing.integration.Test.StreamingOutputCallResponse> fullDuplexCall;
77 public final io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
78 io.grpc.testing.integration.Test.StreamingOutputCallResponse> halfDuplexCall;
zhangkun835e607852015-01-22 12:31:56 -080079
80 private TestServiceServiceDescriptor() {
81 unaryCall = createMethodDescriptor(
82 "grpc.testing.TestService", METHOD_UNARY_CALL);
83 streamingOutputCall = createMethodDescriptor(
84 "grpc.testing.TestService", METHOD_STREAMING_OUTPUT_CALL);
85 streamingInputCall = createMethodDescriptor(
86 "grpc.testing.TestService", METHOD_STREAMING_INPUT_CALL);
87 fullDuplexCall = createMethodDescriptor(
88 "grpc.testing.TestService", METHOD_FULL_DUPLEX_CALL);
89 halfDuplexCall = createMethodDescriptor(
90 "grpc.testing.TestService", METHOD_HALF_DUPLEX_CALL);
91 }
92
Eric Anderson76d09552015-03-12 15:25:11 -070093 @SuppressWarnings("unchecked")
zhangkun835e607852015-01-22 12:31:56 -080094 private TestServiceServiceDescriptor(
nmittlerf8314582015-01-27 10:25:39 -080095 java.util.Map<java.lang.String, io.grpc.MethodDescriptor<?, ?>> methodMap) {
96 unaryCall = (io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.SimpleRequest,
97 io.grpc.testing.integration.Test.SimpleResponse>) methodMap.get(
zhangkun835e607852015-01-22 12:31:56 -080098 CONFIG.unaryCall.getName());
nmittlerf8314582015-01-27 10:25:39 -080099 streamingOutputCall = (io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
100 io.grpc.testing.integration.Test.StreamingOutputCallResponse>) methodMap.get(
zhangkun835e607852015-01-22 12:31:56 -0800101 CONFIG.streamingOutputCall.getName());
nmittlerf8314582015-01-27 10:25:39 -0800102 streamingInputCall = (io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingInputCallRequest,
103 io.grpc.testing.integration.Test.StreamingInputCallResponse>) methodMap.get(
zhangkun835e607852015-01-22 12:31:56 -0800104 CONFIG.streamingInputCall.getName());
nmittlerf8314582015-01-27 10:25:39 -0800105 fullDuplexCall = (io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
106 io.grpc.testing.integration.Test.StreamingOutputCallResponse>) methodMap.get(
zhangkun835e607852015-01-22 12:31:56 -0800107 CONFIG.fullDuplexCall.getName());
nmittlerf8314582015-01-27 10:25:39 -0800108 halfDuplexCall = (io.grpc.MethodDescriptor<io.grpc.testing.integration.Test.StreamingOutputCallRequest,
109 io.grpc.testing.integration.Test.StreamingOutputCallResponse>) methodMap.get(
zhangkun835e607852015-01-22 12:31:56 -0800110 CONFIG.halfDuplexCall.getName());
111 }
112
113 @java.lang.Override
114 protected TestServiceServiceDescriptor build(
nmittlerf8314582015-01-27 10:25:39 -0800115 java.util.Map<java.lang.String, io.grpc.MethodDescriptor<?, ?>> methodMap) {
zhangkun835e607852015-01-22 12:31:56 -0800116 return new TestServiceServiceDescriptor(methodMap);
117 }
118
119 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800120 public com.google.common.collect.ImmutableList<io.grpc.MethodDescriptor<?, ?>> methods() {
121 return com.google.common.collect.ImmutableList.<io.grpc.MethodDescriptor<?, ?>>of(
zhangkun835e607852015-01-22 12:31:56 -0800122 unaryCall,
123 streamingOutputCall,
124 streamingInputCall,
125 fullDuplexCall,
126 halfDuplexCall);
127 }
128 }
129
130 public static interface TestService {
131
nmittlerf8314582015-01-27 10:25:39 -0800132 public void unaryCall(io.grpc.testing.integration.Test.SimpleRequest request,
133 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.SimpleResponse> responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800134
nmittlerf8314582015-01-27 10:25:39 -0800135 public void streamingOutputCall(io.grpc.testing.integration.Test.StreamingOutputCallRequest request,
136 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800137
nmittlerf8314582015-01-27 10:25:39 -0800138 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallRequest> streamingInputCall(
139 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallResponse> responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800140
nmittlerf8314582015-01-27 10:25:39 -0800141 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> fullDuplexCall(
142 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800143
nmittlerf8314582015-01-27 10:25:39 -0800144 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> halfDuplexCall(
145 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800146 }
147
148 public static interface TestServiceBlockingClient {
149
nmittlerf8314582015-01-27 10:25:39 -0800150 public io.grpc.testing.integration.Test.SimpleResponse unaryCall(io.grpc.testing.integration.Test.SimpleRequest request);
zhangkun835e607852015-01-22 12:31:56 -0800151
nmittlerf8314582015-01-27 10:25:39 -0800152 public java.util.Iterator<io.grpc.testing.integration.Test.StreamingOutputCallResponse> streamingOutputCall(
153 io.grpc.testing.integration.Test.StreamingOutputCallRequest request);
zhangkun835e607852015-01-22 12:31:56 -0800154 }
155
156 public static interface TestServiceFutureClient {
157
nmittlerf8314582015-01-27 10:25:39 -0800158 public com.google.common.util.concurrent.ListenableFuture<io.grpc.testing.integration.Test.SimpleResponse> unaryCall(
159 io.grpc.testing.integration.Test.SimpleRequest request);
zhangkun835e607852015-01-22 12:31:56 -0800160 }
161
162 public static class TestServiceStub extends
nmittlerf8314582015-01-27 10:25:39 -0800163 io.grpc.stub.AbstractStub<TestServiceStub, TestServiceServiceDescriptor>
zhangkun835e607852015-01-22 12:31:56 -0800164 implements TestService {
nmittlerf8314582015-01-27 10:25:39 -0800165 private TestServiceStub(io.grpc.Channel channel,
zhangkun835e607852015-01-22 12:31:56 -0800166 TestServiceServiceDescriptor config) {
167 super(channel, config);
168 }
169
Kun Zhangd3c5b002015-06-25 20:24:01 -0700170 private TestServiceStub(io.grpc.Channel channel,
171 TestServiceServiceDescriptor config,
172 io.grpc.CallOptions callOptions) {
173 super(channel, config, callOptions);
174 }
175
zhangkun835e607852015-01-22 12:31:56 -0800176 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800177 protected TestServiceStub build(io.grpc.Channel channel,
Kun Zhangd3c5b002015-06-25 20:24:01 -0700178 TestServiceServiceDescriptor config,
179 io.grpc.CallOptions callOptions) {
180 return new TestServiceStub(channel, config, callOptions);
zhangkun835e607852015-01-22 12:31:56 -0800181 }
182
183 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800184 public void unaryCall(io.grpc.testing.integration.Test.SimpleRequest request,
185 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.SimpleResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800186 asyncUnaryCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700187 channel.newCall(config.unaryCall, callOptions), request, responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800188 }
189
190 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800191 public void streamingOutputCall(io.grpc.testing.integration.Test.StreamingOutputCallRequest request,
192 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800193 asyncServerStreamingCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700194 channel.newCall(config.streamingOutputCall, callOptions), request, responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800195 }
196
197 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800198 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallRequest> streamingInputCall(
199 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800200 return asyncClientStreamingCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700201 channel.newCall(config.streamingInputCall, callOptions), responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800202 }
203
204 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800205 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> fullDuplexCall(
206 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800207 return duplexStreamingCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700208 channel.newCall(config.fullDuplexCall, callOptions), responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800209 }
210
211 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800212 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> halfDuplexCall(
213 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800214 return duplexStreamingCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700215 channel.newCall(config.halfDuplexCall, callOptions), responseObserver);
zhangkun835e607852015-01-22 12:31:56 -0800216 }
217 }
218
219 public static class TestServiceBlockingStub extends
nmittlerf8314582015-01-27 10:25:39 -0800220 io.grpc.stub.AbstractStub<TestServiceBlockingStub, TestServiceServiceDescriptor>
zhangkun835e607852015-01-22 12:31:56 -0800221 implements TestServiceBlockingClient {
nmittlerf8314582015-01-27 10:25:39 -0800222 private TestServiceBlockingStub(io.grpc.Channel channel,
zhangkun835e607852015-01-22 12:31:56 -0800223 TestServiceServiceDescriptor config) {
224 super(channel, config);
225 }
226
Kun Zhangd3c5b002015-06-25 20:24:01 -0700227 private TestServiceBlockingStub(io.grpc.Channel channel,
228 TestServiceServiceDescriptor config,
229 io.grpc.CallOptions callOptions) {
230 super(channel, config, callOptions);
231 }
232
zhangkun835e607852015-01-22 12:31:56 -0800233 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800234 protected TestServiceBlockingStub build(io.grpc.Channel channel,
Kun Zhangd3c5b002015-06-25 20:24:01 -0700235 TestServiceServiceDescriptor config,
236 io.grpc.CallOptions callOptions) {
237 return new TestServiceBlockingStub(channel, config, callOptions);
zhangkun835e607852015-01-22 12:31:56 -0800238 }
239
240 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800241 public io.grpc.testing.integration.Test.SimpleResponse unaryCall(io.grpc.testing.integration.Test.SimpleRequest request) {
zhangkun835e607852015-01-22 12:31:56 -0800242 return blockingUnaryCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700243 channel.newCall(config.unaryCall, callOptions), request);
zhangkun835e607852015-01-22 12:31:56 -0800244 }
245
246 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800247 public java.util.Iterator<io.grpc.testing.integration.Test.StreamingOutputCallResponse> streamingOutputCall(
248 io.grpc.testing.integration.Test.StreamingOutputCallRequest request) {
zhangkun835e607852015-01-22 12:31:56 -0800249 return blockingServerStreamingCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700250 channel.newCall(config.streamingOutputCall, callOptions), request);
zhangkun835e607852015-01-22 12:31:56 -0800251 }
252 }
253
254 public static class TestServiceFutureStub extends
nmittlerf8314582015-01-27 10:25:39 -0800255 io.grpc.stub.AbstractStub<TestServiceFutureStub, TestServiceServiceDescriptor>
zhangkun835e607852015-01-22 12:31:56 -0800256 implements TestServiceFutureClient {
nmittlerf8314582015-01-27 10:25:39 -0800257 private TestServiceFutureStub(io.grpc.Channel channel,
zhangkun835e607852015-01-22 12:31:56 -0800258 TestServiceServiceDescriptor config) {
259 super(channel, config);
260 }
261
Kun Zhangd3c5b002015-06-25 20:24:01 -0700262 private TestServiceFutureStub(io.grpc.Channel channel,
263 TestServiceServiceDescriptor config,
264 io.grpc.CallOptions callOptions) {
265 super(channel, config, callOptions);
266 }
267
zhangkun835e607852015-01-22 12:31:56 -0800268 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800269 protected TestServiceFutureStub build(io.grpc.Channel channel,
Kun Zhangd3c5b002015-06-25 20:24:01 -0700270 TestServiceServiceDescriptor config,
271 io.grpc.CallOptions callOptions) {
272 return new TestServiceFutureStub(channel, config, callOptions);
zhangkun835e607852015-01-22 12:31:56 -0800273 }
274
275 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800276 public com.google.common.util.concurrent.ListenableFuture<io.grpc.testing.integration.Test.SimpleResponse> unaryCall(
277 io.grpc.testing.integration.Test.SimpleRequest request) {
zhangkun835e607852015-01-22 12:31:56 -0800278 return unaryFutureCall(
Kun Zhangd3c5b002015-06-25 20:24:01 -0700279 channel.newCall(config.unaryCall, callOptions), request);
zhangkun835e607852015-01-22 12:31:56 -0800280 }
281 }
282
nmittlerf8314582015-01-27 10:25:39 -0800283 public static io.grpc.ServerServiceDefinition bindService(
zhangkun835e607852015-01-22 12:31:56 -0800284 final TestService serviceImpl) {
nmittlerf8314582015-01-27 10:25:39 -0800285 return io.grpc.ServerServiceDefinition.builder("grpc.testing.TestService")
zhangkun835e607852015-01-22 12:31:56 -0800286 .addMethod(createMethodDefinition(
287 METHOD_UNARY_CALL,
288 asyncUnaryRequestCall(
nmittlerf8314582015-01-27 10:25:39 -0800289 new io.grpc.stub.ServerCalls.UnaryRequestMethod<
290 io.grpc.testing.integration.Test.SimpleRequest,
291 io.grpc.testing.integration.Test.SimpleResponse>() {
zhangkun835e607852015-01-22 12:31:56 -0800292 @java.lang.Override
293 public void invoke(
nmittlerf8314582015-01-27 10:25:39 -0800294 io.grpc.testing.integration.Test.SimpleRequest request,
295 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.SimpleResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800296 serviceImpl.unaryCall(request, responseObserver);
297 }
298 })))
299 .addMethod(createMethodDefinition(
300 METHOD_STREAMING_OUTPUT_CALL,
301 asyncUnaryRequestCall(
nmittlerf8314582015-01-27 10:25:39 -0800302 new io.grpc.stub.ServerCalls.UnaryRequestMethod<
303 io.grpc.testing.integration.Test.StreamingOutputCallRequest,
304 io.grpc.testing.integration.Test.StreamingOutputCallResponse>() {
zhangkun835e607852015-01-22 12:31:56 -0800305 @java.lang.Override
306 public void invoke(
nmittlerf8314582015-01-27 10:25:39 -0800307 io.grpc.testing.integration.Test.StreamingOutputCallRequest request,
308 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800309 serviceImpl.streamingOutputCall(request, responseObserver);
310 }
311 })))
312 .addMethod(createMethodDefinition(
313 METHOD_STREAMING_INPUT_CALL,
314 asyncStreamingRequestCall(
nmittlerf8314582015-01-27 10:25:39 -0800315 new io.grpc.stub.ServerCalls.StreamingRequestMethod<
316 io.grpc.testing.integration.Test.StreamingInputCallRequest,
317 io.grpc.testing.integration.Test.StreamingInputCallResponse>() {
zhangkun835e607852015-01-22 12:31:56 -0800318 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800319 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallRequest> invoke(
320 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingInputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800321 return serviceImpl.streamingInputCall(responseObserver);
322 }
323 })))
324 .addMethod(createMethodDefinition(
325 METHOD_FULL_DUPLEX_CALL,
326 asyncStreamingRequestCall(
nmittlerf8314582015-01-27 10:25:39 -0800327 new io.grpc.stub.ServerCalls.StreamingRequestMethod<
328 io.grpc.testing.integration.Test.StreamingOutputCallRequest,
329 io.grpc.testing.integration.Test.StreamingOutputCallResponse>() {
zhangkun835e607852015-01-22 12:31:56 -0800330 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800331 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> invoke(
332 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800333 return serviceImpl.fullDuplexCall(responseObserver);
334 }
335 })))
336 .addMethod(createMethodDefinition(
337 METHOD_HALF_DUPLEX_CALL,
338 asyncStreamingRequestCall(
nmittlerf8314582015-01-27 10:25:39 -0800339 new io.grpc.stub.ServerCalls.StreamingRequestMethod<
340 io.grpc.testing.integration.Test.StreamingOutputCallRequest,
341 io.grpc.testing.integration.Test.StreamingOutputCallResponse>() {
zhangkun835e607852015-01-22 12:31:56 -0800342 @java.lang.Override
nmittlerf8314582015-01-27 10:25:39 -0800343 public io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallRequest> invoke(
344 io.grpc.stub.StreamObserver<io.grpc.testing.integration.Test.StreamingOutputCallResponse> responseObserver) {
zhangkun835e607852015-01-22 12:31:56 -0800345 return serviceImpl.halfDuplexCall(responseObserver);
346 }
347 }))).build();
348 }
349}