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

com.pulumi.gcp.apigateway.kotlin.inputs.ApiConfigGrpcServiceArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 8.10.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.apigateway.kotlin.inputs

import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.gcp.apigateway.inputs.ApiConfigGrpcServiceArgs.builder
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property fileDescriptorSet Input only. File descriptor set, generated by protoc.
 * To generate, use protoc with imports and source info included. For an example test.proto file, the following command would put the value in a new file named out.pb.
 * $ protoc --include_imports --include_source_info test.proto -o out.pb
 * Structure is documented below.
 * @property sources Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
 * Structure is documented below.
 */
public data class ApiConfigGrpcServiceArgs(
    public val fileDescriptorSet: Output,
    public val sources: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.gcp.apigateway.inputs.ApiConfigGrpcServiceArgs =
        com.pulumi.gcp.apigateway.inputs.ApiConfigGrpcServiceArgs.builder()
            .fileDescriptorSet(fileDescriptorSet.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .sources(
                sources?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            ).build()
}

/**
 * Builder for [ApiConfigGrpcServiceArgs].
 */
@PulumiTagMarker
public class ApiConfigGrpcServiceArgsBuilder internal constructor() {
    private var fileDescriptorSet: Output? = null

    private var sources: Output>? = null

    /**
     * @param value Input only. File descriptor set, generated by protoc.
     * To generate, use protoc with imports and source info included. For an example test.proto file, the following command would put the value in a new file named out.pb.
     * $ protoc --include_imports --include_source_info test.proto -o out.pb
     * Structure is documented below.
     */
    @JvmName("cbyoxmcjhartmajg")
    public suspend fun fileDescriptorSet(`value`: Output) {
        this.fileDescriptorSet = value
    }

    /**
     * @param value Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("gxywiwrhbrgqxwlj")
    public suspend fun sources(`value`: Output>) {
        this.sources = value
    }

    @JvmName("mqeiengoilgqcbiq")
    public suspend fun sources(vararg values: Output) {
        this.sources = Output.all(values.asList())
    }

    /**
     * @param values Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("abkgpvxmayvhhlfu")
    public suspend fun sources(values: List>) {
        this.sources = Output.all(values)
    }

    /**
     * @param value Input only. File descriptor set, generated by protoc.
     * To generate, use protoc with imports and source info included. For an example test.proto file, the following command would put the value in a new file named out.pb.
     * $ protoc --include_imports --include_source_info test.proto -o out.pb
     * Structure is documented below.
     */
    @JvmName("nlkmjlxhanqdlcpi")
    public suspend fun fileDescriptorSet(`value`: ApiConfigGrpcServiceFileDescriptorSetArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.fileDescriptorSet = mapped
    }

    /**
     * @param argument Input only. File descriptor set, generated by protoc.
     * To generate, use protoc with imports and source info included. For an example test.proto file, the following command would put the value in a new file named out.pb.
     * $ protoc --include_imports --include_source_info test.proto -o out.pb
     * Structure is documented below.
     */
    @JvmName("ddctyucsdtamnwdl")
    public suspend fun fileDescriptorSet(argument: suspend ApiConfigGrpcServiceFileDescriptorSetArgsBuilder.() -> Unit) {
        val toBeMapped = ApiConfigGrpcServiceFileDescriptorSetArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.fileDescriptorSet = mapped
    }

    /**
     * @param value Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("axutqxidhpdwgqcr")
    public suspend fun sources(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sources = mapped
    }

    /**
     * @param argument Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("ysxeybkiklofsfga")
    public suspend fun sources(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            ApiConfigGrpcServiceSourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param argument Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("vkekkjktchcvtsou")
    public suspend fun sources(vararg argument: suspend ApiConfigGrpcServiceSourceArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            ApiConfigGrpcServiceSourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param argument Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("msvfqqwtjkridrig")
    public suspend fun sources(argument: suspend ApiConfigGrpcServiceSourceArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            ApiConfigGrpcServiceSourceArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.sources = mapped
    }

    /**
     * @param values Uncompiled proto files associated with the descriptor set, used for display purposes (server-side compilation is not supported). These should match the inputs to 'protoc' command used to generate fileDescriptorSet.
     * Structure is documented below.
     */
    @JvmName("ngcpkbsnxcymgtvv")
    public suspend fun sources(vararg values: ApiConfigGrpcServiceSourceArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.sources = mapped
    }

    internal fun build(): ApiConfigGrpcServiceArgs = ApiConfigGrpcServiceArgs(
        fileDescriptorSet = fileDescriptorSet ?: throw PulumiNullFieldException("fileDescriptorSet"),
        sources = sources,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy