main.grpc.com.streamlayer.chatManager.ChatManagerGrpc Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sl-protofiles Show documentation
Show all versions of sl-protofiles Show documentation
StreamLayer Java Protofiles
package com.streamlayer.chatManager;
import static io.grpc.MethodDescriptor.generateFullMethodName;
/**
*/
@javax.annotation.Generated(
value = "by gRPC proto compiler (version 1.65.1)",
comments = "Source: streamlayer/chatManager/chatManager.client.proto")
@io.grpc.stub.annotations.GrpcGenerated
public final class ChatManagerGrpc {
private ChatManagerGrpc() {}
public static final java.lang.String SERVICE_NAME = "streamlayer.chatManager.ChatManager";
// Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor getCreateGroupMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "CreateGroup",
requestType = com.streamlayer.chatManager.CreateGroupRequest.class,
responseType = com.streamlayer.chatManager.CreateGroupResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
public static io.grpc.MethodDescriptor getCreateGroupMethod() {
io.grpc.MethodDescriptor getCreateGroupMethod;
if ((getCreateGroupMethod = ChatManagerGrpc.getCreateGroupMethod) == null) {
synchronized (ChatManagerGrpc.class) {
if ((getCreateGroupMethod = ChatManagerGrpc.getCreateGroupMethod) == null) {
ChatManagerGrpc.getCreateGroupMethod = getCreateGroupMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateGroup"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.CreateGroupRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.CreateGroupResponse.getDefaultInstance()))
.build();
}
}
}
return getCreateGroupMethod;
}
private static volatile io.grpc.MethodDescriptor getUpdateGroupMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "UpdateGroup",
requestType = com.streamlayer.chatManager.UpdateGroupRequest.class,
responseType = com.streamlayer.chatManager.UpdateGroupResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
public static io.grpc.MethodDescriptor getUpdateGroupMethod() {
io.grpc.MethodDescriptor getUpdateGroupMethod;
if ((getUpdateGroupMethod = ChatManagerGrpc.getUpdateGroupMethod) == null) {
synchronized (ChatManagerGrpc.class) {
if ((getUpdateGroupMethod = ChatManagerGrpc.getUpdateGroupMethod) == null) {
ChatManagerGrpc.getUpdateGroupMethod = getUpdateGroupMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateGroup"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.UpdateGroupRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.UpdateGroupResponse.getDefaultInstance()))
.build();
}
}
}
return getUpdateGroupMethod;
}
private static volatile io.grpc.MethodDescriptor getGetGroupMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "GetGroup",
requestType = com.streamlayer.chatManager.GetGroupRequest.class,
responseType = com.streamlayer.chatManager.GetGroupResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
public static io.grpc.MethodDescriptor getGetGroupMethod() {
io.grpc.MethodDescriptor getGetGroupMethod;
if ((getGetGroupMethod = ChatManagerGrpc.getGetGroupMethod) == null) {
synchronized (ChatManagerGrpc.class) {
if ((getGetGroupMethod = ChatManagerGrpc.getGetGroupMethod) == null) {
ChatManagerGrpc.getGetGroupMethod = getGetGroupMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetGroup"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.GetGroupRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.lite.ProtoLiteUtils.marshaller(
com.streamlayer.chatManager.GetGroupResponse.getDefaultInstance()))
.build();
}
}
}
return getGetGroupMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static ChatManagerStub newStub(io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ChatManagerStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerStub(channel, callOptions);
}
};
return ChatManagerStub.newStub(factory, channel);
}
/**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/
public static ChatManagerBlockingStub newBlockingStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ChatManagerBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerBlockingStub(channel, callOptions);
}
};
return ChatManagerBlockingStub.newStub(factory, channel);
}
/**
* Creates a new ListenableFuture-style stub that supports unary calls on the service
*/
public static ChatManagerFutureStub newFutureStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ChatManagerFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerFutureStub(channel, callOptions);
}
};
return ChatManagerFutureStub.newStub(factory, channel);
}
/**
*/
public interface AsyncService {
/**
*/
default void createGroup(com.streamlayer.chatManager.CreateGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCreateGroupMethod(), responseObserver);
}
/**
*/
default void updateGroup(com.streamlayer.chatManager.UpdateGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateGroupMethod(), responseObserver);
}
/**
*/
default void getGroup(com.streamlayer.chatManager.GetGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetGroupMethod(), responseObserver);
}
}
/**
* Base class for the server implementation of the service ChatManager.
*/
public static abstract class ChatManagerImplBase
implements io.grpc.BindableService, AsyncService {
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return ChatManagerGrpc.bindService(this);
}
}
/**
* A stub to allow clients to do asynchronous rpc calls to service ChatManager.
*/
public static final class ChatManagerStub
extends io.grpc.stub.AbstractAsyncStub {
private ChatManagerStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ChatManagerStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerStub(channel, callOptions);
}
/**
*/
public void createGroup(com.streamlayer.chatManager.CreateGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ClientCalls.asyncUnaryCall(
getChannel().newCall(getCreateGroupMethod(), getCallOptions()), request, responseObserver);
}
/**
*/
public void updateGroup(com.streamlayer.chatManager.UpdateGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ClientCalls.asyncUnaryCall(
getChannel().newCall(getUpdateGroupMethod(), getCallOptions()), request, responseObserver);
}
/**
*/
public void getGroup(com.streamlayer.chatManager.GetGroupRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ClientCalls.asyncUnaryCall(
getChannel().newCall(getGetGroupMethod(), getCallOptions()), request, responseObserver);
}
}
/**
* A stub to allow clients to do synchronous rpc calls to service ChatManager.
*/
public static final class ChatManagerBlockingStub
extends io.grpc.stub.AbstractBlockingStub {
private ChatManagerBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ChatManagerBlockingStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerBlockingStub(channel, callOptions);
}
/**
*/
public com.streamlayer.chatManager.CreateGroupResponse createGroup(com.streamlayer.chatManager.CreateGroupRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getCreateGroupMethod(), getCallOptions(), request);
}
/**
*/
public com.streamlayer.chatManager.UpdateGroupResponse updateGroup(com.streamlayer.chatManager.UpdateGroupRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getUpdateGroupMethod(), getCallOptions(), request);
}
/**
*/
public com.streamlayer.chatManager.GetGroupResponse getGroup(com.streamlayer.chatManager.GetGroupRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getGetGroupMethod(), getCallOptions(), request);
}
}
/**
* A stub to allow clients to do ListenableFuture-style rpc calls to service ChatManager.
*/
public static final class ChatManagerFutureStub
extends io.grpc.stub.AbstractFutureStub {
private ChatManagerFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ChatManagerFutureStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ChatManagerFutureStub(channel, callOptions);
}
/**
*/
public com.google.common.util.concurrent.ListenableFuture createGroup(
com.streamlayer.chatManager.CreateGroupRequest request) {
return io.grpc.stub.ClientCalls.futureUnaryCall(
getChannel().newCall(getCreateGroupMethod(), getCallOptions()), request);
}
/**
*/
public com.google.common.util.concurrent.ListenableFuture updateGroup(
com.streamlayer.chatManager.UpdateGroupRequest request) {
return io.grpc.stub.ClientCalls.futureUnaryCall(
getChannel().newCall(getUpdateGroupMethod(), getCallOptions()), request);
}
/**
*/
public com.google.common.util.concurrent.ListenableFuture getGroup(
com.streamlayer.chatManager.GetGroupRequest request) {
return io.grpc.stub.ClientCalls.futureUnaryCall(
getChannel().newCall(getGetGroupMethod(), getCallOptions()), request);
}
}
private static final int METHODID_CREATE_GROUP = 0;
private static final int METHODID_UPDATE_GROUP = 1;
private static final int METHODID_GET_GROUP = 2;
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_CREATE_GROUP:
serviceImpl.createGroup((com.streamlayer.chatManager.CreateGroupRequest) request,
(io.grpc.stub.StreamObserver) responseObserver);
break;
case METHODID_UPDATE_GROUP:
serviceImpl.updateGroup((com.streamlayer.chatManager.UpdateGroupRequest) request,
(io.grpc.stub.StreamObserver) responseObserver);
break;
case METHODID_GET_GROUP:
serviceImpl.getGroup((com.streamlayer.chatManager.GetGroupRequest) 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(
getCreateGroupMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.streamlayer.chatManager.CreateGroupRequest,
com.streamlayer.chatManager.CreateGroupResponse>(
service, METHODID_CREATE_GROUP)))
.addMethod(
getUpdateGroupMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.streamlayer.chatManager.UpdateGroupRequest,
com.streamlayer.chatManager.UpdateGroupResponse>(
service, METHODID_UPDATE_GROUP)))
.addMethod(
getGetGroupMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
com.streamlayer.chatManager.GetGroupRequest,
com.streamlayer.chatManager.GetGroupResponse>(
service, METHODID_GET_GROUP)))
.build();
}
private static volatile io.grpc.ServiceDescriptor serviceDescriptor;
public static io.grpc.ServiceDescriptor getServiceDescriptor() {
io.grpc.ServiceDescriptor result = serviceDescriptor;
if (result == null) {
synchronized (ChatManagerGrpc.class) {
result = serviceDescriptor;
if (result == null) {
serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
.addMethod(getCreateGroupMethod())
.addMethod(getUpdateGroupMethod())
.addMethod(getGetGroupMethod())
.build();
}
}
}
return result;
}
}