commonMain.aws.sdk.kotlin.services.glue.model.BatchUpdatePartitionRequestEntry.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
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* A structure that contains the values and structure used to update a partition.
*/
public class BatchUpdatePartitionRequestEntry private constructor(builder: Builder) {
/**
* The structure used to update a partition.
*/
public val partitionInput: aws.sdk.kotlin.services.glue.model.PartitionInput? = builder.partitionInput
/**
* A list of values defining the partitions.
*/
public val partitionValueList: List = requireNotNull(builder.partitionValueList) { "A non-null value must be provided for partitionValueList" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.BatchUpdatePartitionRequestEntry = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("BatchUpdatePartitionRequestEntry(")
append("partitionInput=$partitionInput,")
append("partitionValueList=$partitionValueList")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = partitionInput?.hashCode() ?: 0
result = 31 * result + (partitionValueList.hashCode())
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 BatchUpdatePartitionRequestEntry
if (partitionInput != other.partitionInput) return false
if (partitionValueList != other.partitionValueList) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.BatchUpdatePartitionRequestEntry = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The structure used to update a partition.
*/
public var partitionInput: aws.sdk.kotlin.services.glue.model.PartitionInput? = null
/**
* A list of values defining the partitions.
*/
public var partitionValueList: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.BatchUpdatePartitionRequestEntry) : this() {
this.partitionInput = x.partitionInput
this.partitionValueList = x.partitionValueList
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.BatchUpdatePartitionRequestEntry = BatchUpdatePartitionRequestEntry(this)
/**
* construct an [aws.sdk.kotlin.services.glue.model.PartitionInput] inside the given [block]
*/
public fun partitionInput(block: aws.sdk.kotlin.services.glue.model.PartitionInput.Builder.() -> kotlin.Unit) {
this.partitionInput = aws.sdk.kotlin.services.glue.model.PartitionInput.invoke(block)
}
internal fun correctErrors(): Builder {
if (partitionValueList == null) partitionValueList = emptyList()
return this
}
}
}