com.pulumi.awsnative.s3outposts.kotlin.inputs.BucketRuleArgs.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-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.awsnative.s3outposts.kotlin.inputs
import com.pulumi.awsnative.s3outposts.inputs.BucketRuleArgs.builder
import com.pulumi.awsnative.s3outposts.kotlin.enums.BucketRuleStatus
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.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName
/**
* Specifies lifecycle rules for an Amazon S3Outposts bucket. You must specify at least one of the following: AbortIncompleteMultipartUpload, ExpirationDate, ExpirationInDays.
* @property abortIncompleteMultipartUpload Specifies a lifecycle rule that stops incomplete multipart uploads to an Amazon S3Outposts bucket.
* @property expirationDate Indicates when objects are deleted from Amazon S3Outposts. The date value must be in ISO 8601 format. The time is always midnight UTC.
* @property expirationInDays Indicates the number of days after creation when objects are deleted from Amazon S3Outposts.
* @property filter The container for the filter of the lifecycle rule.
* @property id Unique identifier for the lifecycle rule. The value can't be longer than 255 characters.
* @property status If `Enabled` , the rule is currently being applied. If `Disabled` , the rule is not currently being applied.
*/
public data class BucketRuleArgs(
public val abortIncompleteMultipartUpload: Output? =
null,
public val expirationDate: Output? = null,
public val expirationInDays: Output? = null,
public val filter: Output? = null,
public val id: Output? = null,
public val status: Output? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.awsnative.s3outposts.inputs.BucketRuleArgs =
com.pulumi.awsnative.s3outposts.inputs.BucketRuleArgs.builder()
.abortIncompleteMultipartUpload(
abortIncompleteMultipartUpload?.applyValue({ args0 ->
args0.let({ args0 -> args0.toJava() })
}),
)
.expirationDate(expirationDate?.applyValue({ args0 -> args0 }))
.expirationInDays(expirationInDays?.applyValue({ args0 -> args0 }))
.filter(filter?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
.id(id?.applyValue({ args0 -> args0 }))
.status(status?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) })).build()
}
/**
* Builder for [BucketRuleArgs].
*/
@PulumiTagMarker
public class BucketRuleArgsBuilder internal constructor() {
private var abortIncompleteMultipartUpload: Output? =
null
private var expirationDate: Output? = null
private var expirationInDays: Output? = null
private var filter: Output? = null
private var id: Output? = null
private var status: Output? = null
/**
* @param value Specifies a lifecycle rule that stops incomplete multipart uploads to an Amazon S3Outposts bucket.
*/
@JvmName("xbisaymecssqnuht")
public suspend fun abortIncompleteMultipartUpload(`value`: Output) {
this.abortIncompleteMultipartUpload = value
}
/**
* @param value Indicates when objects are deleted from Amazon S3Outposts. The date value must be in ISO 8601 format. The time is always midnight UTC.
*/
@JvmName("kxoiweybjfqfkkhu")
public suspend fun expirationDate(`value`: Output) {
this.expirationDate = value
}
/**
* @param value Indicates the number of days after creation when objects are deleted from Amazon S3Outposts.
*/
@JvmName("mgygjijdonumchsh")
public suspend fun expirationInDays(`value`: Output) {
this.expirationInDays = value
}
/**
* @param value The container for the filter of the lifecycle rule.
*/
@JvmName("npjbkvuvlrpnryah")
public suspend fun filter(`value`: Output) {
this.filter = value
}
/**
* @param value Unique identifier for the lifecycle rule. The value can't be longer than 255 characters.
*/
@JvmName("rhojhsesxdmdbopa")
public suspend fun id(`value`: Output) {
this.id = value
}
/**
* @param value If `Enabled` , the rule is currently being applied. If `Disabled` , the rule is not currently being applied.
*/
@JvmName("ckcyntpodhtonsok")
public suspend fun status(`value`: Output) {
this.status = value
}
/**
* @param value Specifies a lifecycle rule that stops incomplete multipart uploads to an Amazon S3Outposts bucket.
*/
@JvmName("mfbiacysxngucjbe")
public suspend fun abortIncompleteMultipartUpload(`value`: BucketAbortIncompleteMultipartUploadArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.abortIncompleteMultipartUpload = mapped
}
/**
* @param argument Specifies a lifecycle rule that stops incomplete multipart uploads to an Amazon S3Outposts bucket.
*/
@JvmName("spbbxojgufeldgor")
public suspend fun abortIncompleteMultipartUpload(argument: suspend BucketAbortIncompleteMultipartUploadArgsBuilder.() -> Unit) {
val toBeMapped = BucketAbortIncompleteMultipartUploadArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.abortIncompleteMultipartUpload = mapped
}
/**
* @param value Indicates when objects are deleted from Amazon S3Outposts. The date value must be in ISO 8601 format. The time is always midnight UTC.
*/
@JvmName("bijanndhxldwskgp")
public suspend fun expirationDate(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.expirationDate = mapped
}
/**
* @param value Indicates the number of days after creation when objects are deleted from Amazon S3Outposts.
*/
@JvmName("aumculdnppoctpsu")
public suspend fun expirationInDays(`value`: Int?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.expirationInDays = mapped
}
/**
* @param value The container for the filter of the lifecycle rule.
*/
@JvmName("qimxibrnerbgxsvn")
public suspend fun filter(`value`: BucketRuleFilterPropertiesArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.filter = mapped
}
/**
* @param argument The container for the filter of the lifecycle rule.
*/
@JvmName("jogyklmuufqmjihl")
public suspend fun filter(argument: suspend BucketRuleFilterPropertiesArgsBuilder.() -> Unit) {
val toBeMapped = BucketRuleFilterPropertiesArgsBuilder().applySuspend { argument() }.build()
val mapped = of(toBeMapped)
this.filter = mapped
}
/**
* @param value Unique identifier for the lifecycle rule. The value can't be longer than 255 characters.
*/
@JvmName("whwffeqbtipamkle")
public suspend fun id(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.id = mapped
}
/**
* @param value If `Enabled` , the rule is currently being applied. If `Disabled` , the rule is not currently being applied.
*/
@JvmName("lhestckhafgmdsmo")
public suspend fun status(`value`: BucketRuleStatus?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.status = mapped
}
internal fun build(): BucketRuleArgs = BucketRuleArgs(
abortIncompleteMultipartUpload = abortIncompleteMultipartUpload,
expirationDate = expirationDate,
expirationInDays = expirationInDays,
filter = filter,
id = id,
status = status,
)
}