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

com.google.cloud.dialogflow.v2.FulfillmentsGrpc Maven / Gradle / Ivy

There is a newer version: 4.60.0
Show newest version
/*
 * Copyright 2024 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.google.cloud.dialogflow.v2;

import static io.grpc.MethodDescriptor.generateFullMethodName;

/**
 *
 *
 * 
 * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
 * 
*/ @javax.annotation.Generated( value = "by gRPC proto compiler", comments = "Source: google/cloud/dialogflow/v2/fulfillment.proto") @io.grpc.stub.annotations.GrpcGenerated public final class FulfillmentsGrpc { private FulfillmentsGrpc() {} public static final java.lang.String SERVICE_NAME = "google.cloud.dialogflow.v2.Fulfillments"; // Static method descriptors that strictly reflect the proto. private static volatile io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.GetFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getGetFulfillmentMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "GetFulfillment", requestType = com.google.cloud.dialogflow.v2.GetFulfillmentRequest.class, responseType = com.google.cloud.dialogflow.v2.Fulfillment.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.GetFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getGetFulfillmentMethod() { io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.GetFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getGetFulfillmentMethod; if ((getGetFulfillmentMethod = FulfillmentsGrpc.getGetFulfillmentMethod) == null) { synchronized (FulfillmentsGrpc.class) { if ((getGetFulfillmentMethod = FulfillmentsGrpc.getGetFulfillmentMethod) == null) { FulfillmentsGrpc.getGetFulfillmentMethod = getGetFulfillmentMethod = io.grpc.MethodDescriptor . newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetFulfillment")) .setSampledToLocalTracing(true) .setRequestMarshaller( io.grpc.protobuf.ProtoUtils.marshaller( com.google.cloud.dialogflow.v2.GetFulfillmentRequest .getDefaultInstance())) .setResponseMarshaller( io.grpc.protobuf.ProtoUtils.marshaller( com.google.cloud.dialogflow.v2.Fulfillment.getDefaultInstance())) .setSchemaDescriptor( new FulfillmentsMethodDescriptorSupplier("GetFulfillment")) .build(); } } } return getGetFulfillmentMethod; } private static volatile io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getUpdateFulfillmentMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "UpdateFulfillment", requestType = com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest.class, responseType = com.google.cloud.dialogflow.v2.Fulfillment.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getUpdateFulfillmentMethod() { io.grpc.MethodDescriptor< com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment> getUpdateFulfillmentMethod; if ((getUpdateFulfillmentMethod = FulfillmentsGrpc.getUpdateFulfillmentMethod) == null) { synchronized (FulfillmentsGrpc.class) { if ((getUpdateFulfillmentMethod = FulfillmentsGrpc.getUpdateFulfillmentMethod) == null) { FulfillmentsGrpc.getUpdateFulfillmentMethod = getUpdateFulfillmentMethod = io.grpc.MethodDescriptor . newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateFulfillment")) .setSampledToLocalTracing(true) .setRequestMarshaller( io.grpc.protobuf.ProtoUtils.marshaller( com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest .getDefaultInstance())) .setResponseMarshaller( io.grpc.protobuf.ProtoUtils.marshaller( com.google.cloud.dialogflow.v2.Fulfillment.getDefaultInstance())) .setSchemaDescriptor( new FulfillmentsMethodDescriptorSupplier("UpdateFulfillment")) .build(); } } } return getUpdateFulfillmentMethod; } /** Creates a new async stub that supports all call types for the service */ public static FulfillmentsStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public FulfillmentsStub newStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsStub(channel, callOptions); } }; return FulfillmentsStub.newStub(factory, channel); } /** * Creates a new blocking-style stub that supports unary and streaming output calls on the service */ public static FulfillmentsBlockingStub newBlockingStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public FulfillmentsBlockingStub newStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsBlockingStub(channel, callOptions); } }; return FulfillmentsBlockingStub.newStub(factory, channel); } /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ public static FulfillmentsFutureStub newFutureStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = new io.grpc.stub.AbstractStub.StubFactory() { @java.lang.Override public FulfillmentsFutureStub newStub( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsFutureStub(channel, callOptions); } }; return FulfillmentsFutureStub.newStub(factory, channel); } /** * * *
   * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
   * 
*/ public interface AsyncService { /** * * *
     * Retrieves the fulfillment.
     * 
*/ default void getFulfillment( com.google.cloud.dialogflow.v2.GetFulfillmentRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( getGetFulfillmentMethod(), responseObserver); } /** * * *
     * Updates the fulfillment.
     * 
*/ default void updateFulfillment( com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( getUpdateFulfillmentMethod(), responseObserver); } } /** * Base class for the server implementation of the service Fulfillments. * *
   * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
   * 
*/ public abstract static class FulfillmentsImplBase implements io.grpc.BindableService, AsyncService { @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return FulfillmentsGrpc.bindService(this); } } /** * A stub to allow clients to do asynchronous rpc calls to service Fulfillments. * *
   * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
   * 
*/ public static final class FulfillmentsStub extends io.grpc.stub.AbstractAsyncStub { private FulfillmentsStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected FulfillmentsStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsStub(channel, callOptions); } /** * * *
     * Retrieves the fulfillment.
     * 
*/ public void getFulfillment( com.google.cloud.dialogflow.v2.GetFulfillmentRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getGetFulfillmentMethod(), getCallOptions()), request, responseObserver); } /** * * *
     * Updates the fulfillment.
     * 
*/ public void updateFulfillment( com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest request, io.grpc.stub.StreamObserver responseObserver) { io.grpc.stub.ClientCalls.asyncUnaryCall( getChannel().newCall(getUpdateFulfillmentMethod(), getCallOptions()), request, responseObserver); } } /** * A stub to allow clients to do synchronous rpc calls to service Fulfillments. * *
   * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
   * 
*/ public static final class FulfillmentsBlockingStub extends io.grpc.stub.AbstractBlockingStub { private FulfillmentsBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected FulfillmentsBlockingStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsBlockingStub(channel, callOptions); } /** * * *
     * Retrieves the fulfillment.
     * 
*/ public com.google.cloud.dialogflow.v2.Fulfillment getFulfillment( com.google.cloud.dialogflow.v2.GetFulfillmentRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getGetFulfillmentMethod(), getCallOptions(), request); } /** * * *
     * Updates the fulfillment.
     * 
*/ public com.google.cloud.dialogflow.v2.Fulfillment updateFulfillment( com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest request) { return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getUpdateFulfillmentMethod(), getCallOptions(), request); } } /** * A stub to allow clients to do ListenableFuture-style rpc calls to service Fulfillments. * *
   * Service for managing [Fulfillments][google.cloud.dialogflow.v2.Fulfillment].
   * 
*/ public static final class FulfillmentsFutureStub extends io.grpc.stub.AbstractFutureStub { private FulfillmentsFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected FulfillmentsFutureStub build( io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new FulfillmentsFutureStub(channel, callOptions); } /** * * *
     * Retrieves the fulfillment.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture< com.google.cloud.dialogflow.v2.Fulfillment> getFulfillment(com.google.cloud.dialogflow.v2.GetFulfillmentRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getGetFulfillmentMethod(), getCallOptions()), request); } /** * * *
     * Updates the fulfillment.
     * 
*/ public com.google.common.util.concurrent.ListenableFuture< com.google.cloud.dialogflow.v2.Fulfillment> updateFulfillment(com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest request) { return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getUpdateFulfillmentMethod(), getCallOptions()), request); } } private static final int METHODID_GET_FULFILLMENT = 0; private static final int METHODID_UPDATE_FULFILLMENT = 1; 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_FULFILLMENT: serviceImpl.getFulfillment( (com.google.cloud.dialogflow.v2.GetFulfillmentRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_UPDATE_FULFILLMENT: serviceImpl.updateFulfillment( (com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest) 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( getGetFulfillmentMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< com.google.cloud.dialogflow.v2.GetFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment>(service, METHODID_GET_FULFILLMENT))) .addMethod( getUpdateFulfillmentMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( new MethodHandlers< com.google.cloud.dialogflow.v2.UpdateFulfillmentRequest, com.google.cloud.dialogflow.v2.Fulfillment>( service, METHODID_UPDATE_FULFILLMENT))) .build(); } private abstract static class FulfillmentsBaseDescriptorSupplier implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { FulfillmentsBaseDescriptorSupplier() {} @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { return com.google.cloud.dialogflow.v2.FulfillmentProto.getDescriptor(); } @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("Fulfillments"); } } private static final class FulfillmentsFileDescriptorSupplier extends FulfillmentsBaseDescriptorSupplier { FulfillmentsFileDescriptorSupplier() {} } private static final class FulfillmentsMethodDescriptorSupplier extends FulfillmentsBaseDescriptorSupplier implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { private final java.lang.String methodName; FulfillmentsMethodDescriptorSupplier(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 (FulfillmentsGrpc.class) { result = serviceDescriptor; if (result == null) { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new FulfillmentsFileDescriptorSupplier()) .addMethod(getGetFulfillmentMethod()) .addMethod(getUpdateFulfillmentMethod()) .build(); } } } return result; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy