Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
@javax.annotation.Generated(
value = "by gRPC proto compiler",
comments = "Source: grpc/testing/test.proto")
@io.grpc.stub.annotations.GrpcGenerated
public final class UnimplementedServiceGrpc {
private UnimplementedServiceGrpc() {}
public static final java.lang.String SERVICE_NAME = "grpc.testing.UnimplementedService";
// Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor getUnimplementedCallMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "UnimplementedCall",
requestType = io.grpc.testing.integration.EmptyProtos.Empty.class,
responseType = io.grpc.testing.integration.EmptyProtos.Empty.class,
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
public static io.grpc.MethodDescriptor getUnimplementedCallMethod() {
io.grpc.MethodDescriptor getUnimplementedCallMethod;
if ((getUnimplementedCallMethod = UnimplementedServiceGrpc.getUnimplementedCallMethod) == null) {
synchronized (UnimplementedServiceGrpc.class) {
if ((getUnimplementedCallMethod = UnimplementedServiceGrpc.getUnimplementedCallMethod) == null) {
UnimplementedServiceGrpc.getUnimplementedCallMethod = getUnimplementedCallMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "UnimplementedCall"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.grpc.testing.integration.EmptyProtos.Empty.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.grpc.testing.integration.EmptyProtos.Empty.getDefaultInstance()))
.setSchemaDescriptor(new UnimplementedServiceMethodDescriptorSupplier("UnimplementedCall"))
.build();
}
}
}
return getUnimplementedCallMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static UnimplementedServiceStub newStub(io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public UnimplementedServiceStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceStub(channel, callOptions);
}
};
return UnimplementedServiceStub.newStub(factory, channel);
}
/**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/
public static UnimplementedServiceBlockingStub newBlockingStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public UnimplementedServiceBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceBlockingStub(channel, callOptions);
}
};
return UnimplementedServiceBlockingStub.newStub(factory, channel);
}
/**
* Creates a new ListenableFuture-style stub that supports unary calls on the service
*/
public static UnimplementedServiceFutureStub newFutureStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public UnimplementedServiceFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceFutureStub(channel, callOptions);
}
};
return UnimplementedServiceFutureStub.newStub(factory, channel);
}
/**
*
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
public interface AsyncService {
/**
*
* A call that no server should implement
*
*/
default void unimplementedCall(io.grpc.testing.integration.EmptyProtos.Empty request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUnimplementedCallMethod(), responseObserver);
}
}
/**
* Base class for the server implementation of the service UnimplementedService.
*
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
public static abstract class UnimplementedServiceImplBase
implements io.grpc.BindableService, AsyncService {
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return UnimplementedServiceGrpc.bindService(this);
}
}
/**
* A stub to allow clients to do asynchronous rpc calls to service UnimplementedService.
*
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
public static final class UnimplementedServiceStub
extends io.grpc.stub.AbstractAsyncStub {
private UnimplementedServiceStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected UnimplementedServiceStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceStub(channel, callOptions);
}
/**
*
* A call that no server should implement
*
*/
public void unimplementedCall(io.grpc.testing.integration.EmptyProtos.Empty request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ClientCalls.asyncUnaryCall(
getChannel().newCall(getUnimplementedCallMethod(), getCallOptions()), request, responseObserver);
}
}
/**
* A stub to allow clients to do synchronous rpc calls to service UnimplementedService.
*
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
public static final class UnimplementedServiceBlockingStub
extends io.grpc.stub.AbstractBlockingStub {
private UnimplementedServiceBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected UnimplementedServiceBlockingStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceBlockingStub(channel, callOptions);
}
/**
*
* A call that no server should implement
*
*/
public io.grpc.testing.integration.EmptyProtos.Empty unimplementedCall(io.grpc.testing.integration.EmptyProtos.Empty request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getUnimplementedCallMethod(), getCallOptions(), request);
}
}
/**
* A stub to allow clients to do ListenableFuture-style rpc calls to service UnimplementedService.
*
* A simple service NOT implemented at servers so clients can test for
* that case.
*
*/
public static final class UnimplementedServiceFutureStub
extends io.grpc.stub.AbstractFutureStub {
private UnimplementedServiceFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected UnimplementedServiceFutureStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new UnimplementedServiceFutureStub(channel, callOptions);
}
/**
*
* A call that no server should implement
*
*/
public com.google.common.util.concurrent.ListenableFuture unimplementedCall(
io.grpc.testing.integration.EmptyProtos.Empty request) {
return io.grpc.stub.ClientCalls.futureUnaryCall(
getChannel().newCall(getUnimplementedCallMethod(), getCallOptions()), request);
}
}
private static final int METHODID_UNIMPLEMENTED_CALL = 0;
private static final class MethodHandlers implements
io.grpc.stub.ServerCalls.UnaryMethod,
io.grpc.stub.ServerCalls.ServerStreamingMethod,
io.grpc.stub.ServerCalls.ClientStreamingMethod,
io.grpc.stub.ServerCalls.BidiStreamingMethod {
private final AsyncService serviceImpl;
private final int methodId;
MethodHandlers(AsyncService serviceImpl, int methodId) {
this.serviceImpl = serviceImpl;
this.methodId = methodId;
}
@java.lang.Override
@java.lang.SuppressWarnings("unchecked")
public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) {
switch (methodId) {
case METHODID_UNIMPLEMENTED_CALL:
serviceImpl.unimplementedCall((io.grpc.testing.integration.EmptyProtos.Empty) request,
(io.grpc.stub.StreamObserver) responseObserver);
break;
default:
throw new AssertionError();
}
}
@java.lang.Override
@java.lang.SuppressWarnings("unchecked")
public io.grpc.stub.StreamObserver invoke(
io.grpc.stub.StreamObserver responseObserver) {
switch (methodId) {
default:
throw new AssertionError();
}
}
}
public static final io.grpc.ServerServiceDefinition bindService(AsyncService service) {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getUnimplementedCallMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
io.grpc.testing.integration.EmptyProtos.Empty,
io.grpc.testing.integration.EmptyProtos.Empty>(
service, METHODID_UNIMPLEMENTED_CALL)))
.build();
}
private static abstract class UnimplementedServiceBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
UnimplementedServiceBaseDescriptorSupplier() {}
@java.lang.Override
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
return io.grpc.testing.integration.Test.getDescriptor();
}
@java.lang.Override
public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() {
return getFileDescriptor().findServiceByName("UnimplementedService");
}
}
private static final class UnimplementedServiceFileDescriptorSupplier
extends UnimplementedServiceBaseDescriptorSupplier {
UnimplementedServiceFileDescriptorSupplier() {}
}
private static final class UnimplementedServiceMethodDescriptorSupplier
extends UnimplementedServiceBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
private final java.lang.String methodName;
UnimplementedServiceMethodDescriptorSupplier(java.lang.String methodName) {
this.methodName = methodName;
}
@java.lang.Override
public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() {
return getServiceDescriptor().findMethodByName(methodName);
}
}
private static volatile io.grpc.ServiceDescriptor serviceDescriptor;
public static io.grpc.ServiceDescriptor getServiceDescriptor() {
io.grpc.ServiceDescriptor result = serviceDescriptor;
if (result == null) {
synchronized (UnimplementedServiceGrpc.class) {
result = serviceDescriptor;
if (result == null) {
serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
.setSchemaDescriptor(new UnimplementedServiceFileDescriptorSupplier())
.addMethod(getUnimplementedCallMethod())
.build();
}
}
}
return result;
}
}