commonMain.aws.sdk.kotlin.services.backup.model.GetBackupPlanRequest.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.backup.model
import aws.smithy.kotlin.runtime.SdkDsl
public class GetBackupPlanRequest private constructor(builder: Builder) {
/**
* Uniquely identifies a backup plan.
*/
public val backupPlanId: kotlin.String? = builder.backupPlanId
/**
* Unique, randomly generated, Unicode, UTF-8 encoded strings that are at most 1,024 bytes long. Version IDs cannot be edited.
*/
public val versionId: kotlin.String? = builder.versionId
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.backup.model.GetBackupPlanRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("GetBackupPlanRequest(")
append("backupPlanId=$backupPlanId,")
append("versionId=$versionId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = backupPlanId?.hashCode() ?: 0
result = 31 * result + (versionId?.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 GetBackupPlanRequest
if (backupPlanId != other.backupPlanId) return false
if (versionId != other.versionId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.backup.model.GetBackupPlanRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Uniquely identifies a backup plan.
*/
public var backupPlanId: kotlin.String? = null
/**
* Unique, randomly generated, Unicode, UTF-8 encoded strings that are at most 1,024 bytes long. Version IDs cannot be edited.
*/
public var versionId: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.backup.model.GetBackupPlanRequest) : this() {
this.backupPlanId = x.backupPlanId
this.versionId = x.versionId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.backup.model.GetBackupPlanRequest = GetBackupPlanRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}