com.pulumi.alicloud.pvtz.kotlin.RuleArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-alicloud-kotlin Show documentation
Show all versions of pulumi-alicloud-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.alicloud.pvtz.kotlin
import com.pulumi.alicloud.pvtz.RuleArgs.builder
import com.pulumi.alicloud.pvtz.kotlin.inputs.RuleForwardIpArgs
import com.pulumi.alicloud.pvtz.kotlin.inputs.RuleForwardIpArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName
/**
* Provides a Private Zone Rule resource.
* For information about Private Zone Rule and how to use it, see [What is Rule](https://www.alibabacloud.com/help/en/privatezone/latest/add-forwarding-rule).
* > **NOTE:** Available since v1.143.0.
* ## Import
* Private Zone Rule can be imported using the id, e.g.
* ```sh
* $ pulumi import alicloud:pvtz/rule:Rule example
* ```
* @property endpointId The ID of the Endpoint.
* @property forwardIps Forwarding target. See `forward_ips` below.
* @property ruleName The name of the resource.
* @property type The type of the rule. Valid values: `OUTBOUND`.
* @property zoneName The name of the forwarding zone.
*/
public data class RuleArgs(
public val endpointId: Output? = null,
public val forwardIps: Output>? = null,
public val ruleName: Output? = null,
public val type: Output? = null,
public val zoneName: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.alicloud.pvtz.RuleArgs =
com.pulumi.alicloud.pvtz.RuleArgs.builder()
.endpointId(endpointId?.applyValue({ args0 -> args0 }))
.forwardIps(
forwardIps?.applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
args0.toJava()
})
})
}),
)
.ruleName(ruleName?.applyValue({ args0 -> args0 }))
.type(type?.applyValue({ args0 -> args0 }))
.zoneName(zoneName?.applyValue({ args0 -> args0 })).build()
}
/**
* Builder for [RuleArgs].
*/
@PulumiTagMarker
public class RuleArgsBuilder internal constructor() {
private var endpointId: Output? = null
private var forwardIps: Output>? = null
private var ruleName: Output? = null
private var type: Output? = null
private var zoneName: Output? = null
/**
* @param value The ID of the Endpoint.
*/
@JvmName("ifarkockgrekpxdv")
public suspend fun endpointId(`value`: Output) {
this.endpointId = value
}
/**
* @param value Forwarding target. See `forward_ips` below.
*/
@JvmName("mbhtegmutvolxmpq")
public suspend fun forwardIps(`value`: Output>) {
this.forwardIps = value
}
@JvmName("rdetkgpbblxlrean")
public suspend fun forwardIps(vararg values: Output) {
this.forwardIps = Output.all(values.asList())
}
/**
* @param values Forwarding target. See `forward_ips` below.
*/
@JvmName("xqplobewradwetii")
public suspend fun forwardIps(values: List