commonMain.aws.sdk.kotlin.services.glue.model.SchemaChangePolicy.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of glue-jvm Show documentation
Show all versions of glue-jvm Show documentation
The AWS SDK for Kotlin client for Glue
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* A policy that specifies update and deletion behaviors for the crawler.
*/
public class SchemaChangePolicy private constructor(builder: Builder) {
/**
* The deletion behavior when the crawler finds a deleted object.
*/
public val deleteBehavior: aws.sdk.kotlin.services.glue.model.DeleteBehavior? = builder.deleteBehavior
/**
* The update behavior when the crawler finds a changed schema.
*/
public val updateBehavior: aws.sdk.kotlin.services.glue.model.UpdateBehavior? = builder.updateBehavior
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.SchemaChangePolicy = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("SchemaChangePolicy(")
append("deleteBehavior=$deleteBehavior,")
append("updateBehavior=$updateBehavior")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = deleteBehavior?.hashCode() ?: 0
result = 31 * result + (updateBehavior?.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 SchemaChangePolicy
if (deleteBehavior != other.deleteBehavior) return false
if (updateBehavior != other.updateBehavior) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.SchemaChangePolicy = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The deletion behavior when the crawler finds a deleted object.
*/
public var deleteBehavior: aws.sdk.kotlin.services.glue.model.DeleteBehavior? = null
/**
* The update behavior when the crawler finds a changed schema.
*/
public var updateBehavior: aws.sdk.kotlin.services.glue.model.UpdateBehavior? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.SchemaChangePolicy) : this() {
this.deleteBehavior = x.deleteBehavior
this.updateBehavior = x.updateBehavior
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.SchemaChangePolicy = SchemaChangePolicy(this)
internal fun correctErrors(): Builder {
return this
}
}
}