11package io .grpc .examples ;
22
33import static io .grpc .MethodDescriptor .generateFullMethodName ;
4- import static io .grpc .stub .ClientCalls .asyncBidiStreamingCall ;
5- import static io .grpc .stub .ClientCalls .asyncClientStreamingCall ;
6- import static io .grpc .stub .ClientCalls .asyncServerStreamingCall ;
74import static io .grpc .stub .ClientCalls .asyncUnaryCall ;
8- import static io .grpc .stub .ClientCalls .blockingServerStreamingCall ;
95import static io .grpc .stub .ClientCalls .blockingUnaryCall ;
106import static io .grpc .stub .ClientCalls .futureUnaryCall ;
11- import static io .grpc .stub .ServerCalls .asyncBidiStreamingCall ;
12- import static io .grpc .stub .ServerCalls .asyncClientStreamingCall ;
13- import static io .grpc .stub .ServerCalls .asyncServerStreamingCall ;
147import static io .grpc .stub .ServerCalls .asyncUnaryCall ;
15- import static io .grpc .stub .ServerCalls .asyncUnimplementedStreamingCall ;
168import static io .grpc .stub .ServerCalls .asyncUnimplementedUnaryCall ;
179
1810/**
1911 */
2012@ javax .annotation .Generated (
21- value = "by gRPC proto compiler (version 1.11.0 )" ,
13+ value = "by gRPC proto compiler (version 1.13.1 )" ,
2214 comments = "Source: calculator.proto" )
2315public final class CalculatorGrpc {
2416
@@ -27,22 +19,11 @@ private CalculatorGrpc() {}
2719 public static final String SERVICE_NAME = "Calculator" ;
2820
2921 // Static method descriptors that strictly reflect the proto.
30- @ io .grpc .ExperimentalApi ("https://github.com/grpc/grpc-java/issues/1901" )
31- @ java .lang .Deprecated // Use {@link #getCalculateMethod()} instead.
32- public static final io .grpc .MethodDescriptor <io .grpc .examples .CalculatorOuterClass .CalculatorRequest ,
33- io .grpc .examples .CalculatorOuterClass .CalculatorResponse > METHOD_CALCULATE = getCalculateMethodHelper ();
34-
3522 private static volatile io .grpc .MethodDescriptor <io .grpc .examples .CalculatorOuterClass .CalculatorRequest ,
3623 io .grpc .examples .CalculatorOuterClass .CalculatorResponse > getCalculateMethod ;
3724
38- @ io .grpc .ExperimentalApi ("https://github.com/grpc/grpc-java/issues/1901" )
3925 public static io .grpc .MethodDescriptor <io .grpc .examples .CalculatorOuterClass .CalculatorRequest ,
4026 io .grpc .examples .CalculatorOuterClass .CalculatorResponse > getCalculateMethod () {
41- return getCalculateMethodHelper ();
42- }
43-
44- private static io .grpc .MethodDescriptor <io .grpc .examples .CalculatorOuterClass .CalculatorRequest ,
45- io .grpc .examples .CalculatorOuterClass .CalculatorResponse > getCalculateMethodHelper () {
4627 io .grpc .MethodDescriptor <io .grpc .examples .CalculatorOuterClass .CalculatorRequest , io .grpc .examples .CalculatorOuterClass .CalculatorResponse > getCalculateMethod ;
4728 if ((getCalculateMethod = CalculatorGrpc .getCalculateMethod ) == null ) {
4829 synchronized (CalculatorGrpc .class ) {
@@ -96,13 +77,13 @@ public static abstract class CalculatorImplBase implements io.grpc.BindableServi
9677 */
9778 public void calculate (io .grpc .examples .CalculatorOuterClass .CalculatorRequest request ,
9879 io .grpc .stub .StreamObserver <io .grpc .examples .CalculatorOuterClass .CalculatorResponse > responseObserver ) {
99- asyncUnimplementedUnaryCall (getCalculateMethodHelper (), responseObserver );
80+ asyncUnimplementedUnaryCall (getCalculateMethod (), responseObserver );
10081 }
10182
10283 @ java .lang .Override public final io .grpc .ServerServiceDefinition bindService () {
10384 return io .grpc .ServerServiceDefinition .builder (getServiceDescriptor ())
10485 .addMethod (
105- getCalculateMethodHelper (),
86+ getCalculateMethod (),
10687 asyncUnaryCall (
10788 new MethodHandlers <
10889 io .grpc .examples .CalculatorOuterClass .CalculatorRequest ,
@@ -135,7 +116,7 @@ protected CalculatorStub build(io.grpc.Channel channel,
135116 public void calculate (io .grpc .examples .CalculatorOuterClass .CalculatorRequest request ,
136117 io .grpc .stub .StreamObserver <io .grpc .examples .CalculatorOuterClass .CalculatorResponse > responseObserver ) {
137118 asyncUnaryCall (
138- getChannel ().newCall (getCalculateMethodHelper (), getCallOptions ()), request , responseObserver );
119+ getChannel ().newCall (getCalculateMethod (), getCallOptions ()), request , responseObserver );
139120 }
140121 }
141122
@@ -161,7 +142,7 @@ protected CalculatorBlockingStub build(io.grpc.Channel channel,
161142 */
162143 public io .grpc .examples .CalculatorOuterClass .CalculatorResponse calculate (io .grpc .examples .CalculatorOuterClass .CalculatorRequest request ) {
163144 return blockingUnaryCall (
164- getChannel (), getCalculateMethodHelper (), getCallOptions (), request );
145+ getChannel (), getCalculateMethod (), getCallOptions (), request );
165146 }
166147 }
167148
@@ -188,7 +169,7 @@ protected CalculatorFutureStub build(io.grpc.Channel channel,
188169 public com .google .common .util .concurrent .ListenableFuture <io .grpc .examples .CalculatorOuterClass .CalculatorResponse > calculate (
189170 io .grpc .examples .CalculatorOuterClass .CalculatorRequest request ) {
190171 return futureUnaryCall (
191- getChannel ().newCall (getCalculateMethodHelper (), getCallOptions ()), request );
172+ getChannel ().newCall (getCalculateMethod (), getCallOptions ()), request );
192173 }
193174 }
194175
@@ -276,7 +257,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() {
276257 if (result == null ) {
277258 serviceDescriptor = result = io .grpc .ServiceDescriptor .newBuilder (SERVICE_NAME )
278259 .setSchemaDescriptor (new CalculatorFileDescriptorSupplier ())
279- .addMethod (getCalculateMethodHelper ())
260+ .addMethod (getCalculateMethod ())
280261 .build ();
281262 }
282263 }
0 commit comments