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

com.pulumi.aws.cloudfront.kotlin.inputs.DistributionRestrictionsGeoRestrictionArgs.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: 6.57.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.aws.cloudfront.kotlin.inputs

import com.pulumi.aws.cloudfront.inputs.DistributionRestrictionsGeoRestrictionArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 *
 * @property locations [ISO 3166-1-alpha-2 codes][4] for which you want CloudFront either to distribute your content (`whitelist`) or not distribute your content (`blacklist`). If the type is specified as `none` an empty array can be used.
 * @property restrictionType Method that you want to use to restrict distribution of your content by country: `none`, `whitelist`, or `blacklist`.
 */
public data class DistributionRestrictionsGeoRestrictionArgs(
    public val locations: Output>? = null,
    public val restrictionType: Output,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.aws.cloudfront.inputs.DistributionRestrictionsGeoRestrictionArgs = com.pulumi.aws.cloudfront.inputs.DistributionRestrictionsGeoRestrictionArgs.builder()
        .locations(locations?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
        .restrictionType(restrictionType.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [DistributionRestrictionsGeoRestrictionArgs].
 */
@PulumiTagMarker
public class DistributionRestrictionsGeoRestrictionArgsBuilder internal constructor() {
    private var locations: Output>? = null

    private var restrictionType: Output? = null

    /**
     * @param value [ISO 3166-1-alpha-2 codes][4] for which you want CloudFront either to distribute your content (`whitelist`) or not distribute your content (`blacklist`). If the type is specified as `none` an empty array can be used.
     */
    @JvmName("peynxnbecajjowju")
    public suspend fun locations(`value`: Output>) {
        this.locations = value
    }

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

    /**
     * @param values [ISO 3166-1-alpha-2 codes][4] for which you want CloudFront either to distribute your content (`whitelist`) or not distribute your content (`blacklist`). If the type is specified as `none` an empty array can be used.
     */
    @JvmName("onuuponxmllyufjw")
    public suspend fun locations(values: List>) {
        this.locations = Output.all(values)
    }

    /**
     * @param value Method that you want to use to restrict distribution of your content by country: `none`, `whitelist`, or `blacklist`.
     */
    @JvmName("qktowytxusaidllk")
    public suspend fun restrictionType(`value`: Output) {
        this.restrictionType = value
    }

    /**
     * @param value [ISO 3166-1-alpha-2 codes][4] for which you want CloudFront either to distribute your content (`whitelist`) or not distribute your content (`blacklist`). If the type is specified as `none` an empty array can be used.
     */
    @JvmName("okjxlpdootsxhhmd")
    public suspend fun locations(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.locations = mapped
    }

    /**
     * @param values [ISO 3166-1-alpha-2 codes][4] for which you want CloudFront either to distribute your content (`whitelist`) or not distribute your content (`blacklist`). If the type is specified as `none` an empty array can be used.
     */
    @JvmName("ksmocaqkyuxqktyl")
    public suspend fun locations(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.locations = mapped
    }

    /**
     * @param value Method that you want to use to restrict distribution of your content by country: `none`, `whitelist`, or `blacklist`.
     */
    @JvmName("hlxqndotrbamstee")
    public suspend fun restrictionType(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.restrictionType = mapped
    }

    internal fun build(): DistributionRestrictionsGeoRestrictionArgs =
        DistributionRestrictionsGeoRestrictionArgs(
            locations = locations,
            restrictionType = restrictionType ?: throw PulumiNullFieldException("restrictionType"),
        )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy