All Downloads are FREE. Search and download functionalities are using the official Maven repository.

tech.ydb.proto.operation.v1.OperationServiceGrpc Maven / Gradle / Ivy

package tech.ydb.proto.operation.v1;

import static io.grpc.MethodDescriptor.generateFullMethodName;

/**
 */
@javax.annotation.Generated(
    value = "by gRPC proto compiler (version 1.59.1)",
    comments = "Source: ydb_operation_v1.proto")
@io.grpc.stub.annotations.GrpcGenerated
public final class OperationServiceGrpc {

  private OperationServiceGrpc() {}

  public static final java.lang.String SERVICE_NAME = "Ydb.Operation.V1.OperationService";

  // Static method descriptors that strictly reflect the proto.
  private static volatile io.grpc.MethodDescriptor getGetOperationMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "GetOperation",
      requestType = tech.ydb.proto.OperationProtos.GetOperationRequest.class,
      responseType = tech.ydb.proto.OperationProtos.GetOperationResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getGetOperationMethod() {
    io.grpc.MethodDescriptor getGetOperationMethod;
    if ((getGetOperationMethod = OperationServiceGrpc.getGetOperationMethod) == null) {
      synchronized (OperationServiceGrpc.class) {
        if ((getGetOperationMethod = OperationServiceGrpc.getGetOperationMethod) == null) {
          OperationServiceGrpc.getGetOperationMethod = getGetOperationMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetOperation"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.GetOperationRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.GetOperationResponse.getDefaultInstance()))
              .setSchemaDescriptor(new OperationServiceMethodDescriptorSupplier("GetOperation"))
              .build();
        }
      }
    }
    return getGetOperationMethod;
  }

  private static volatile io.grpc.MethodDescriptor getCancelOperationMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "CancelOperation",
      requestType = tech.ydb.proto.OperationProtos.CancelOperationRequest.class,
      responseType = tech.ydb.proto.OperationProtos.CancelOperationResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getCancelOperationMethod() {
    io.grpc.MethodDescriptor getCancelOperationMethod;
    if ((getCancelOperationMethod = OperationServiceGrpc.getCancelOperationMethod) == null) {
      synchronized (OperationServiceGrpc.class) {
        if ((getCancelOperationMethod = OperationServiceGrpc.getCancelOperationMethod) == null) {
          OperationServiceGrpc.getCancelOperationMethod = getCancelOperationMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CancelOperation"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.CancelOperationRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.CancelOperationResponse.getDefaultInstance()))
              .setSchemaDescriptor(new OperationServiceMethodDescriptorSupplier("CancelOperation"))
              .build();
        }
      }
    }
    return getCancelOperationMethod;
  }

  private static volatile io.grpc.MethodDescriptor getForgetOperationMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "ForgetOperation",
      requestType = tech.ydb.proto.OperationProtos.ForgetOperationRequest.class,
      responseType = tech.ydb.proto.OperationProtos.ForgetOperationResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getForgetOperationMethod() {
    io.grpc.MethodDescriptor getForgetOperationMethod;
    if ((getForgetOperationMethod = OperationServiceGrpc.getForgetOperationMethod) == null) {
      synchronized (OperationServiceGrpc.class) {
        if ((getForgetOperationMethod = OperationServiceGrpc.getForgetOperationMethod) == null) {
          OperationServiceGrpc.getForgetOperationMethod = getForgetOperationMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ForgetOperation"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.ForgetOperationRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.ForgetOperationResponse.getDefaultInstance()))
              .setSchemaDescriptor(new OperationServiceMethodDescriptorSupplier("ForgetOperation"))
              .build();
        }
      }
    }
    return getForgetOperationMethod;
  }

  private static volatile io.grpc.MethodDescriptor getListOperationsMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "ListOperations",
      requestType = tech.ydb.proto.OperationProtos.ListOperationsRequest.class,
      responseType = tech.ydb.proto.OperationProtos.ListOperationsResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getListOperationsMethod() {
    io.grpc.MethodDescriptor getListOperationsMethod;
    if ((getListOperationsMethod = OperationServiceGrpc.getListOperationsMethod) == null) {
      synchronized (OperationServiceGrpc.class) {
        if ((getListOperationsMethod = OperationServiceGrpc.getListOperationsMethod) == null) {
          OperationServiceGrpc.getListOperationsMethod = getListOperationsMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListOperations"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.ListOperationsRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  tech.ydb.proto.OperationProtos.ListOperationsResponse.getDefaultInstance()))
              .setSchemaDescriptor(new OperationServiceMethodDescriptorSupplier("ListOperations"))
              .build();
        }
      }
    }
    return getListOperationsMethod;
  }

  /**
   * Creates a new async stub that supports all call types for the service
   */
  public static OperationServiceStub newStub(io.grpc.Channel channel) {
    io.grpc.stub.AbstractStub.StubFactory factory =
      new io.grpc.stub.AbstractStub.StubFactory() {
        @java.lang.Override
        public OperationServiceStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
          return new OperationServiceStub(channel, callOptions);
        }
      };
    return OperationServiceStub.newStub(factory, channel);
  }

  /**
   * Creates a new blocking-style stub that supports unary and streaming output calls on the service
   */
  public static OperationServiceBlockingStub newBlockingStub(
      io.grpc.Channel channel) {
    io.grpc.stub.AbstractStub.StubFactory factory =
      new io.grpc.stub.AbstractStub.StubFactory() {
        @java.lang.Override
        public OperationServiceBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
          return new OperationServiceBlockingStub(channel, callOptions);
        }
      };
    return OperationServiceBlockingStub.newStub(factory, channel);
  }

  /**
   * Creates a new ListenableFuture-style stub that supports unary calls on the service
   */
  public static OperationServiceFutureStub newFutureStub(
      io.grpc.Channel channel) {
    io.grpc.stub.AbstractStub.StubFactory factory =
      new io.grpc.stub.AbstractStub.StubFactory() {
        @java.lang.Override
        public OperationServiceFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
          return new OperationServiceFutureStub(channel, callOptions);
        }
      };
    return OperationServiceFutureStub.newStub(factory, channel);
  }

  /**
   */
  public interface AsyncService {

    /**
     * 
     * Check status for a given operation.
     * 
*/ default void getOperation(tech.ydb.proto.OperationProtos.GetOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetOperationMethod(), responseObserver); } /** *
     * Starts cancellation of a long-running operation,
     * Clients can use GetOperation to check whether the cancellation succeeded
     * or whether the operation completed despite cancellation.
     * 
*/ default void cancelOperation(tech.ydb.proto.OperationProtos.CancelOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getCancelOperationMethod(), responseObserver); } /** *
     * Forgets long-running operation. It does not cancel the operation and returns
     * an error if operation was not completed.
     * 
*/ default void forgetOperation(tech.ydb.proto.OperationProtos.ForgetOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getForgetOperationMethod(), responseObserver); } /** *
     * Lists operations that match the specified filter in the request.
     * 
*/ default void listOperations(tech.ydb.proto.OperationProtos.ListOperationsRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListOperationsMethod(), responseObserver); } } /** * Base class for the server implementation of the service OperationService. */ public static abstract class OperationServiceImplBase implements io.grpc.BindableService, AsyncService { @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return OperationServiceGrpc.bindService(this); } } /** * A stub to allow clients to do asynchronous rpc calls to service OperationService. */ public static final class OperationServiceStub extends io.grpc.stub.AbstractAsyncStub { private OperationServiceStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected OperationServiceStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new OperationServiceStub(channel, callOptions); } /** *
     * Check status for a given operation.
     * 
*/ public void getOperation(tech.ydb.proto.OperationProtos.GetOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetOperationMethod(), getCallOptions()), request, responseObserver); } /** *
     * Starts cancellation of a long-running operation,
     * Clients can use GetOperation to check whether the cancellation succeeded
     * or whether the operation completed despite cancellation.
     * 
*/ public void cancelOperation(tech.ydb.proto.OperationProtos.CancelOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getCancelOperationMethod(), getCallOptions()), request, responseObserver); } /** *
     * Forgets long-running operation. It does not cancel the operation and returns
     * an error if operation was not completed.
     * 
*/ public void forgetOperation(tech.ydb.proto.OperationProtos.ForgetOperationRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getForgetOperationMethod(), getCallOptions()), request, responseObserver); } /** *
     * Lists operations that match the specified filter in the request.
     * 
*/ public void listOperations(tech.ydb.proto.OperationProtos.ListOperationsRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getListOperationsMethod(), getCallOptions()), request, responseObserver); } } /** * A stub to allow clients to do synchronous rpc calls to service OperationService. */ public static final class OperationServiceBlockingStub extends io.grpc.stub.AbstractBlockingStub { private OperationServiceBlockingStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected OperationServiceBlockingStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new OperationServiceBlockingStub(channel, callOptions); } /** *
     * Check status for a given operation.
     * 
*/ public tech.ydb.proto.OperationProtos.GetOperationResponse getOperation(tech.ydb.proto.OperationProtos.GetOperationRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetOperationMethod(), getCallOptions(), request); } /** *
     * Starts cancellation of a long-running operation,
     * Clients can use GetOperation to check whether the cancellation succeeded
     * or whether the operation completed despite cancellation.
     * 
*/ public tech.ydb.proto.OperationProtos.CancelOperationResponse cancelOperation(tech.ydb.proto.OperationProtos.CancelOperationRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getCancelOperationMethod(), getCallOptions(), request); } /** *
     * Forgets long-running operation. It does not cancel the operation and returns
     * an error if operation was not completed.
     * 
*/ public tech.ydb.proto.OperationProtos.ForgetOperationResponse forgetOperation(tech.ydb.proto.OperationProtos.ForgetOperationRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getForgetOperationMethod(), getCallOptions(), request); } /** *
     * Lists operations that match the specified filter in the request.
     * 
*/ public tech.ydb.proto.OperationProtos.ListOperationsResponse listOperations(tech.ydb.proto.OperationProtos.ListOperationsRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getListOperationsMethod(), getCallOptions(), request); } } /** * A stub to allow clients to do ListenableFuture-style rpc calls to service OperationService. */ public static final class OperationServiceFutureStub extends io.grpc.stub.AbstractFutureStub { private OperationServiceFutureStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected OperationServiceFutureStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new OperationServiceFutureStub(channel, callOptions); } /** *
     * Check status for a given operation.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture getOperation( tech.ydb.proto.OperationProtos.GetOperationRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetOperationMethod(), getCallOptions()), request); } /** *
     * Starts cancellation of a long-running operation,
     * Clients can use GetOperation to check whether the cancellation succeeded
     * or whether the operation completed despite cancellation.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture cancelOperation( tech.ydb.proto.OperationProtos.CancelOperationRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getCancelOperationMethod(), getCallOptions()), request); } /** *
     * Forgets long-running operation. It does not cancel the operation and returns
     * an error if operation was not completed.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture forgetOperation( tech.ydb.proto.OperationProtos.ForgetOperationRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getForgetOperationMethod(), getCallOptions()), request); } /** *
     * Lists operations that match the specified filter in the request.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture listOperations( tech.ydb.proto.OperationProtos.ListOperationsRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getListOperationsMethod(), getCallOptions()), request); } } private static final int METHODID_GET_OPERATION = 0; private static final int METHODID_CANCEL_OPERATION = 1; private static final int METHODID_FORGET_OPERATION = 2; private static final int METHODID_LIST_OPERATIONS = 3; 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_GET_OPERATION: serviceImpl.getOperation((tech.ydb.proto.OperationProtos.GetOperationRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_CANCEL_OPERATION: serviceImpl.cancelOperation((tech.ydb.proto.OperationProtos.CancelOperationRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_FORGET_OPERATION: serviceImpl.forgetOperation((tech.ydb.proto.OperationProtos.ForgetOperationRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_LIST_OPERATIONS: serviceImpl.listOperations((tech.ydb.proto.OperationProtos.ListOperationsRequest) 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( getGetOperationMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< tech.ydb.proto.OperationProtos.GetOperationRequest, tech.ydb.proto.OperationProtos.GetOperationResponse>( service, METHODID_GET_OPERATION))) .addMethod( getCancelOperationMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< tech.ydb.proto.OperationProtos.CancelOperationRequest, tech.ydb.proto.OperationProtos.CancelOperationResponse>( service, METHODID_CANCEL_OPERATION))) .addMethod( getForgetOperationMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< tech.ydb.proto.OperationProtos.ForgetOperationRequest, tech.ydb.proto.OperationProtos.ForgetOperationResponse>( service, METHODID_FORGET_OPERATION))) .addMethod( getListOperationsMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< tech.ydb.proto.OperationProtos.ListOperationsRequest, tech.ydb.proto.OperationProtos.ListOperationsResponse>( service, METHODID_LIST_OPERATIONS))) .build(); } private static abstract class OperationServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { OperationServiceBaseDescriptorSupplier() {} @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { return tech.ydb.proto.operation.v1.YdbOperationV1.getDescriptor(); } @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("OperationService"); } } private static final class OperationServiceFileDescriptorSupplier extends OperationServiceBaseDescriptorSupplier { OperationServiceFileDescriptorSupplier() {} } private static final class OperationServiceMethodDescriptorSupplier extends OperationServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { private final java.lang.String methodName; OperationServiceMethodDescriptorSupplier(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 (OperationServiceGrpc.class) { result = serviceDescriptor; if (result == null) { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new OperationServiceFileDescriptorSupplier()) .addMethod(getGetOperationMethod()) .addMethod(getCancelOperationMethod()) .addMethod(getForgetOperationMethod()) .addMethod(getListOperationsMethod()) .build(); } } } return result; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy