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

xyz.block.ftl.v1.console.ConsoleServiceGrpc Maven / Gradle / Ivy

There is a newer version: 0.368.1
Show newest version
package xyz.block.ftl.v1.console;

import static io.grpc.MethodDescriptor.generateFullMethodName;

/**
 */
@javax.annotation.Generated(
    value = "by gRPC proto compiler (version 1.65.1)",
    comments = "Source: xyz/block/ftl/v1/console/console.proto")
@io.grpc.stub.annotations.GrpcGenerated
public final class ConsoleServiceGrpc {

  private ConsoleServiceGrpc() {}

  public static final java.lang.String SERVICE_NAME = "xyz.block.ftl.v1.console.ConsoleService";

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

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "Ping",
      requestType = xyz.block.ftl.v1.PingRequest.class,
      responseType = xyz.block.ftl.v1.PingResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getPingMethod() {
    io.grpc.MethodDescriptor getPingMethod;
    if ((getPingMethod = ConsoleServiceGrpc.getPingMethod) == null) {
      synchronized (ConsoleServiceGrpc.class) {
        if ((getPingMethod = ConsoleServiceGrpc.getPingMethod) == null) {
          ConsoleServiceGrpc.getPingMethod = getPingMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Ping"))
              .setSafe(true)
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.PingRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.PingResponse.getDefaultInstance()))
              .setSchemaDescriptor(new ConsoleServiceMethodDescriptorSupplier("Ping"))
              .build();
        }
      }
    }
    return getPingMethod;
  }

  private static volatile io.grpc.MethodDescriptor getGetModulesMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "GetModules",
      requestType = xyz.block.ftl.v1.console.GetModulesRequest.class,
      responseType = xyz.block.ftl.v1.console.GetModulesResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getGetModulesMethod() {
    io.grpc.MethodDescriptor getGetModulesMethod;
    if ((getGetModulesMethod = ConsoleServiceGrpc.getGetModulesMethod) == null) {
      synchronized (ConsoleServiceGrpc.class) {
        if ((getGetModulesMethod = ConsoleServiceGrpc.getGetModulesMethod) == null) {
          ConsoleServiceGrpc.getGetModulesMethod = getGetModulesMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetModules"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.GetModulesRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.GetModulesResponse.getDefaultInstance()))
              .setSchemaDescriptor(new ConsoleServiceMethodDescriptorSupplier("GetModules"))
              .build();
        }
      }
    }
    return getGetModulesMethod;
  }

  private static volatile io.grpc.MethodDescriptor getStreamEventsMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "StreamEvents",
      requestType = xyz.block.ftl.v1.console.StreamEventsRequest.class,
      responseType = xyz.block.ftl.v1.console.StreamEventsResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
  public static io.grpc.MethodDescriptor getStreamEventsMethod() {
    io.grpc.MethodDescriptor getStreamEventsMethod;
    if ((getStreamEventsMethod = ConsoleServiceGrpc.getStreamEventsMethod) == null) {
      synchronized (ConsoleServiceGrpc.class) {
        if ((getStreamEventsMethod = ConsoleServiceGrpc.getStreamEventsMethod) == null) {
          ConsoleServiceGrpc.getStreamEventsMethod = getStreamEventsMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "StreamEvents"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.StreamEventsRequest.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.StreamEventsResponse.getDefaultInstance()))
              .setSchemaDescriptor(new ConsoleServiceMethodDescriptorSupplier("StreamEvents"))
              .build();
        }
      }
    }
    return getStreamEventsMethod;
  }

  private static volatile io.grpc.MethodDescriptor getGetEventsMethod;

  @io.grpc.stub.annotations.RpcMethod(
      fullMethodName = SERVICE_NAME + '/' + "GetEvents",
      requestType = xyz.block.ftl.v1.console.EventsQuery.class,
      responseType = xyz.block.ftl.v1.console.GetEventsResponse.class,
      methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
  public static io.grpc.MethodDescriptor getGetEventsMethod() {
    io.grpc.MethodDescriptor getGetEventsMethod;
    if ((getGetEventsMethod = ConsoleServiceGrpc.getGetEventsMethod) == null) {
      synchronized (ConsoleServiceGrpc.class) {
        if ((getGetEventsMethod = ConsoleServiceGrpc.getGetEventsMethod) == null) {
          ConsoleServiceGrpc.getGetEventsMethod = getGetEventsMethod =
              io.grpc.MethodDescriptor.newBuilder()
              .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
              .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetEvents"))
              .setSampledToLocalTracing(true)
              .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.EventsQuery.getDefaultInstance()))
              .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
                  xyz.block.ftl.v1.console.GetEventsResponse.getDefaultInstance()))
              .setSchemaDescriptor(new ConsoleServiceMethodDescriptorSupplier("GetEvents"))
              .build();
        }
      }
    }
    return getGetEventsMethod;
  }

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

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

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

  /**
   */
  public interface AsyncService {

    /**
     * 
     * Ping service for readiness.
     * 
*/ default void ping(xyz.block.ftl.v1.PingRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getPingMethod(), responseObserver); } /** */ default void getModules(xyz.block.ftl.v1.console.GetModulesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetModulesMethod(), responseObserver); } /** */ default void streamEvents(xyz.block.ftl.v1.console.StreamEventsRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getStreamEventsMethod(), responseObserver); } /** */ default void getEvents(xyz.block.ftl.v1.console.EventsQuery request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetEventsMethod(), responseObserver); } } /** * Base class for the server implementation of the service ConsoleService. */ public static abstract class ConsoleServiceImplBase implements io.grpc.BindableService, AsyncService { @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return ConsoleServiceGrpc.bindService(this); } } /** * A stub to allow clients to do asynchronous rpc calls to service ConsoleService. */ public static final class ConsoleServiceStub extends io.grpc.stub.AbstractAsyncStub { private ConsoleServiceStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected ConsoleServiceStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new ConsoleServiceStub(channel, callOptions); } /** *
     * Ping service for readiness.
     * 
*/ public void ping(xyz.block.ftl.v1.PingRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getPingMethod(), getCallOptions()), request, responseObserver); } /** */ public void getModules(xyz.block.ftl.v1.console.GetModulesRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetModulesMethod(), getCallOptions()), request, responseObserver); } /** */ public void streamEvents(xyz.block.ftl.v1.console.StreamEventsRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncServerStreamingCall( getChannel().newCall(getStreamEventsMethod(), getCallOptions()), request, responseObserver); } /** */ public void getEvents(xyz.block.ftl.v1.console.EventsQuery request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetEventsMethod(), getCallOptions()), request, responseObserver); } } /** * A stub to allow clients to do synchronous rpc calls to service ConsoleService. */ public static final class ConsoleServiceBlockingStub extends io.grpc.stub.AbstractBlockingStub { private ConsoleServiceBlockingStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected ConsoleServiceBlockingStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new ConsoleServiceBlockingStub(channel, callOptions); } /** *
     * Ping service for readiness.
     * 
*/ public xyz.block.ftl.v1.PingResponse ping(xyz.block.ftl.v1.PingRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getPingMethod(), getCallOptions(), request); } /** */ public xyz.block.ftl.v1.console.GetModulesResponse getModules(xyz.block.ftl.v1.console.GetModulesRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetModulesMethod(), getCallOptions(), request); } /** */ public java.util.Iterator streamEvents( xyz.block.ftl.v1.console.StreamEventsRequest request) { return io.grpc.stub.ClientCalls.blockingServerStreamingCall( getChannel(), getStreamEventsMethod(), getCallOptions(), request); } /** */ public xyz.block.ftl.v1.console.GetEventsResponse getEvents(xyz.block.ftl.v1.console.EventsQuery request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetEventsMethod(), getCallOptions(), request); } } /** * A stub to allow clients to do ListenableFuture-style rpc calls to service ConsoleService. */ public static final class ConsoleServiceFutureStub extends io.grpc.stub.AbstractFutureStub { private ConsoleServiceFutureStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected ConsoleServiceFutureStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new ConsoleServiceFutureStub(channel, callOptions); } /** *
     * Ping service for readiness.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture ping( xyz.block.ftl.v1.PingRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getPingMethod(), getCallOptions()), request); } /** */ public com.google.common.util.concurrent.ListenableFuture getModules( xyz.block.ftl.v1.console.GetModulesRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetModulesMethod(), getCallOptions()), request); } /** */ public com.google.common.util.concurrent.ListenableFuture getEvents( xyz.block.ftl.v1.console.EventsQuery request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetEventsMethod(), getCallOptions()), request); } } private static final int METHODID_PING = 0; private static final int METHODID_GET_MODULES = 1; private static final int METHODID_STREAM_EVENTS = 2; private static final int METHODID_GET_EVENTS = 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_PING: serviceImpl.ping((xyz.block.ftl.v1.PingRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_MODULES: serviceImpl.getModules((xyz.block.ftl.v1.console.GetModulesRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_STREAM_EVENTS: serviceImpl.streamEvents((xyz.block.ftl.v1.console.StreamEventsRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_EVENTS: serviceImpl.getEvents((xyz.block.ftl.v1.console.EventsQuery) 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( getPingMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< xyz.block.ftl.v1.PingRequest, xyz.block.ftl.v1.PingResponse>( service, METHODID_PING))) .addMethod( getGetModulesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< xyz.block.ftl.v1.console.GetModulesRequest, xyz.block.ftl.v1.console.GetModulesResponse>( service, METHODID_GET_MODULES))) .addMethod( getStreamEventsMethod(), io.grpc.stub.ServerCalls.asyncServerStreamingCall( new MethodHandlers< xyz.block.ftl.v1.console.StreamEventsRequest, xyz.block.ftl.v1.console.StreamEventsResponse>( service, METHODID_STREAM_EVENTS))) .addMethod( getGetEventsMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< xyz.block.ftl.v1.console.EventsQuery, xyz.block.ftl.v1.console.GetEventsResponse>( service, METHODID_GET_EVENTS))) .build(); } private static abstract class ConsoleServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { ConsoleServiceBaseDescriptorSupplier() {} @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { return xyz.block.ftl.v1.console.Console.getDescriptor(); } @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("ConsoleService"); } } private static final class ConsoleServiceFileDescriptorSupplier extends ConsoleServiceBaseDescriptorSupplier { ConsoleServiceFileDescriptorSupplier() {} } private static final class ConsoleServiceMethodDescriptorSupplier extends ConsoleServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { private final java.lang.String methodName; ConsoleServiceMethodDescriptorSupplier(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 (ConsoleServiceGrpc.class) { result = serviceDescriptor; if (result == null) { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new ConsoleServiceFileDescriptorSupplier()) .addMethod(getPingMethod()) .addMethod(getGetModulesMethod()) .addMethod(getStreamEventsMethod()) .addMethod(getGetEventsMethod()) .build(); } } } return result; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy