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

com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.MutinyBQLienServiceGrpc Maven / Gradle / Ivy

The newest version!
package com.redhat.mercury.merchandisingloan.v10.api.bqlienservice;

import static com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BQLienServiceGrpc.getServiceDescriptor;
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;

@javax.annotation.Generated(
value = "by Mutiny Grpc generator",
comments = "Source: v10/api/bq_lien_service.proto")
public final class MutinyBQLienServiceGrpc implements io.quarkus.grpc.runtime.MutinyGrpc {
    private MutinyBQLienServiceGrpc() {}

    public static MutinyBQLienServiceStub newMutinyStub(io.grpc.Channel channel) {
        return new MutinyBQLienServiceStub(channel);
    }

    
    public static final class MutinyBQLienServiceStub extends io.grpc.stub.AbstractStub implements io.quarkus.grpc.runtime.MutinyStub {
        private BQLienServiceGrpc.BQLienServiceStub delegateStub;

        private MutinyBQLienServiceStub(io.grpc.Channel channel) {
            super(channel);
            delegateStub = BQLienServiceGrpc.newStub(channel);
        }

        private MutinyBQLienServiceStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
            super(channel, callOptions);
            delegateStub = BQLienServiceGrpc.newStub(channel).build(channel, callOptions);
        }

        @Override
        protected MutinyBQLienServiceStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
            return new MutinyBQLienServiceStub(channel, callOptions);
        }

        
        public io.smallrye.mutiny.Uni exchangeLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.ExchangeLienRequest request) {
            return io.quarkus.grpc.runtime.ClientCalls.oneToOne(request, delegateStub::exchangeLien);
        }

        
        public io.smallrye.mutiny.Uni initiateLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.InitiateLienRequest request) {
            return io.quarkus.grpc.runtime.ClientCalls.oneToOne(request, delegateStub::initiateLien);
        }

        
        public io.smallrye.mutiny.Uni retrieveLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.RetrieveLienRequest request) {
            return io.quarkus.grpc.runtime.ClientCalls.oneToOne(request, delegateStub::retrieveLien);
        }

        
        public io.smallrye.mutiny.Uni updateLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.UpdateLienRequest request) {
            return io.quarkus.grpc.runtime.ClientCalls.oneToOne(request, delegateStub::updateLien);
        }

    }

    
    public static abstract class BQLienServiceImplBase implements io.grpc.BindableService {

        private String compression;
        /**
        * Set whether the server will try to use a compressed response.
        *
        * @param compression the compression, e.g {@code gzip}
        */
        public BQLienServiceImplBase withCompression(String compression) {
        this.compression = compression;
        return this;
        }


        
        public io.smallrye.mutiny.Uni exchangeLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.ExchangeLienRequest request) {
            throw new io.grpc.StatusRuntimeException(io.grpc.Status.UNIMPLEMENTED);
        }

        
        public io.smallrye.mutiny.Uni initiateLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.InitiateLienRequest request) {
            throw new io.grpc.StatusRuntimeException(io.grpc.Status.UNIMPLEMENTED);
        }

        
        public io.smallrye.mutiny.Uni retrieveLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.RetrieveLienRequest request) {
            throw new io.grpc.StatusRuntimeException(io.grpc.Status.UNIMPLEMENTED);
        }

        
        public io.smallrye.mutiny.Uni updateLien(com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.UpdateLienRequest request) {
            throw new io.grpc.StatusRuntimeException(io.grpc.Status.UNIMPLEMENTED);
        }

        @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
            return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
                    .addMethod(
                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BQLienServiceGrpc.getExchangeLienMethod(),
                            asyncUnaryCall(
                                    new MethodHandlers<
                                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.ExchangeLienRequest,
                                            com.redhat.mercury.merchandisingloan.v10.LienOuterClass.Lien>(
                                            this, METHODID_EXCHANGE_LIEN, compression)))
                    .addMethod(
                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BQLienServiceGrpc.getInitiateLienMethod(),
                            asyncUnaryCall(
                                    new MethodHandlers<
                                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.InitiateLienRequest,
                                            com.redhat.mercury.merchandisingloan.v10.LienOuterClass.Lien>(
                                            this, METHODID_INITIATE_LIEN, compression)))
                    .addMethod(
                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BQLienServiceGrpc.getRetrieveLienMethod(),
                            asyncUnaryCall(
                                    new MethodHandlers<
                                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.RetrieveLienRequest,
                                            com.redhat.mercury.merchandisingloan.v10.LienOuterClass.Lien>(
                                            this, METHODID_RETRIEVE_LIEN, compression)))
                    .addMethod(
                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BQLienServiceGrpc.getUpdateLienMethod(),
                            asyncUnaryCall(
                                    new MethodHandlers<
                                            com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.UpdateLienRequest,
                                            com.redhat.mercury.merchandisingloan.v10.LienOuterClass.Lien>(
                                            this, METHODID_UPDATE_LIEN, compression)))
                    .build();
        }
    }

    private static final int METHODID_EXCHANGE_LIEN = 0;
    private static final int METHODID_INITIATE_LIEN = 1;
    private static final int METHODID_RETRIEVE_LIEN = 2;
    private static final int METHODID_UPDATE_LIEN = 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 BQLienServiceImplBase serviceImpl;
        private final int methodId;
        private final String compression;

        MethodHandlers(BQLienServiceImplBase serviceImpl, int methodId, String compression) {
            this.serviceImpl = serviceImpl;
            this.methodId = methodId;
            this.compression = compression;
        }

        @java.lang.Override
        @java.lang.SuppressWarnings("unchecked")
        public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) {
            switch (methodId) {
                case METHODID_EXCHANGE_LIEN:
                    io.quarkus.grpc.runtime.ServerCalls.oneToOne((com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.ExchangeLienRequest) request,
                            (io.grpc.stub.StreamObserver) responseObserver,
                            compression,
                            serviceImpl::exchangeLien);
                    break;
                case METHODID_INITIATE_LIEN:
                    io.quarkus.grpc.runtime.ServerCalls.oneToOne((com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.InitiateLienRequest) request,
                            (io.grpc.stub.StreamObserver) responseObserver,
                            compression,
                            serviceImpl::initiateLien);
                    break;
                case METHODID_RETRIEVE_LIEN:
                    io.quarkus.grpc.runtime.ServerCalls.oneToOne((com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.RetrieveLienRequest) request,
                            (io.grpc.stub.StreamObserver) responseObserver,
                            compression,
                            serviceImpl::retrieveLien);
                    break;
                case METHODID_UPDATE_LIEN:
                    io.quarkus.grpc.runtime.ServerCalls.oneToOne((com.redhat.mercury.merchandisingloan.v10.api.bqlienservice.BqLienService.UpdateLienRequest) request,
                            (io.grpc.stub.StreamObserver) responseObserver,
                            compression,
                            serviceImpl::updateLien);
                    break;
                default:
                    throw new java.lang.AssertionError();
            }
        }

        @java.lang.Override
        @java.lang.SuppressWarnings("unchecked")
        public io.grpc.stub.StreamObserver invoke(io.grpc.stub.StreamObserver responseObserver) {
            switch (methodId) {
                default:
                    throw new java.lang.AssertionError();
            }
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy