
commonMain.aws.sdk.kotlin.services.cloudhsmv2.model.ModifyBackupAttributesRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cloudhsmv2.model
public class ModifyBackupAttributesRequest private constructor(builder: Builder) {
/**
* The identifier (ID) of the backup to modify. To find the ID of a backup, use the DescribeBackups operation.
*/
public val backupId: kotlin.String? = builder.backupId
/**
* Specifies whether the service should exempt a backup from the retention policy for the cluster. `True` exempts a backup from the retention policy. `False` means the service applies the backup retention policy defined at the cluster.
*/
public val neverExpires: kotlin.Boolean? = builder.neverExpires
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cloudhsmv2.model.ModifyBackupAttributesRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ModifyBackupAttributesRequest(")
append("backupId=$backupId,")
append("neverExpires=$neverExpires")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = backupId?.hashCode() ?: 0
result = 31 * result + (neverExpires?.hashCode() ?: 0)
return result
}
override fun equals(other: kotlin.Any?): kotlin.Boolean {
if (this === other) return true
if (other == null || this::class != other::class) return false
other as ModifyBackupAttributesRequest
if (backupId != other.backupId) return false
if (neverExpires != other.neverExpires) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cloudhsmv2.model.ModifyBackupAttributesRequest = Builder(this).apply(block).build()
public class Builder {
/**
* The identifier (ID) of the backup to modify. To find the ID of a backup, use the DescribeBackups operation.
*/
public var backupId: kotlin.String? = null
/**
* Specifies whether the service should exempt a backup from the retention policy for the cluster. `True` exempts a backup from the retention policy. `False` means the service applies the backup retention policy defined at the cluster.
*/
public var neverExpires: kotlin.Boolean? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cloudhsmv2.model.ModifyBackupAttributesRequest) : this() {
this.backupId = x.backupId
this.neverExpires = x.neverExpires
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cloudhsmv2.model.ModifyBackupAttributesRequest = ModifyBackupAttributesRequest(this)
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy