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

build.bazel.remote.logstream.v1.LogStreamServiceClientStub.kt Maven / Gradle / Ivy

package build.bazel.remote.logstream.v1

import com.google.common.util.concurrent.ListenableFuture
import io.grpc.CallOptions
import io.grpc.Channel
import io.grpc.MethodDescriptor
import io.grpc.MethodDescriptor.MethodType
import io.grpc.MethodDescriptor.generateFullMethodName
import io.grpc.Status.Code
import io.grpc.protobuf.ProtoUtils
import io.grpc.stub.AbstractStub
import io.grpc.stub.ClientCalls.asyncBidiStreamingCall
import io.grpc.stub.ClientCalls.asyncClientStreamingCall
import io.grpc.stub.ClientCalls.asyncServerStreamingCall
import io.grpc.stub.ClientCalls.futureUnaryCall
import javax.annotation.Generated

@Generated("com.google.api.kotlin.generator.GRPCGenerator")
class LogStreamServiceClientStub(channel: Channel, callOptions: CallOptions = CallOptions.DEFAULT) :
        AbstractStub(channel, callOptions) {
    private val createLogStreamDescriptor: MethodDescriptor by
            lazy {
            MethodDescriptor.newBuilder()
                .setType(MethodDescriptor.MethodType.UNARY)
               
                    .setFullMethodName(generateFullMethodName("build.bazel.remote.logstream.v1.LogStreamService",
                    "CreateLogStream"))
                .setSampledToLocalTracing(true)
                .setRequestMarshaller(ProtoUtils.marshaller(
                    CreateLogStreamRequest.getDefaultInstance()))
                .setResponseMarshaller(ProtoUtils.marshaller(
                    LogStream.getDefaultInstance()))
                .build()

            }

    override fun build(channel: Channel, callOptions: CallOptions): LogStreamServiceClientStub =
            LogStreamServiceClientStub(channel, callOptions)

    fun createLogStream(request: CreateLogStreamRequest): ListenableFuture =
            futureUnaryCall(
        channel.newCall(createLogStreamDescriptor, callOptions),
        request
    )

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy