commonMain.aws.sdk.kotlin.services.backup.model.DescribeCopyJobResponse.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 DescribeCopyJobResponse private constructor(builder: Builder) {
/**
* Contains detailed information about a copy job.
*/
public val copyJob: aws.sdk.kotlin.services.backup.model.CopyJob? = builder.copyJob
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.backup.model.DescribeCopyJobResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DescribeCopyJobResponse(")
append("copyJob=$copyJob")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = copyJob?.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 DescribeCopyJobResponse
if (copyJob != other.copyJob) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.backup.model.DescribeCopyJobResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Contains detailed information about a copy job.
*/
public var copyJob: aws.sdk.kotlin.services.backup.model.CopyJob? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.backup.model.DescribeCopyJobResponse) : this() {
this.copyJob = x.copyJob
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.backup.model.DescribeCopyJobResponse = DescribeCopyJobResponse(this)
/**
* construct an [aws.sdk.kotlin.services.backup.model.CopyJob] inside the given [block]
*/
public fun copyJob(block: aws.sdk.kotlin.services.backup.model.CopyJob.Builder.() -> kotlin.Unit) {
this.copyJob = aws.sdk.kotlin.services.backup.model.CopyJob.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}