commonMain.aws.sdk.kotlin.services.snowball.model.UpdateLongTermPricingRequest.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of snowball-jvm Show documentation
Show all versions of snowball-jvm Show documentation
The AWS SDK for Kotlin client for Snowball
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.snowball.model
import aws.smithy.kotlin.runtime.SdkDsl
public class UpdateLongTermPricingRequest private constructor(builder: Builder) {
/**
* If set to `true`, specifies that the current long-term pricing type for the device should be automatically renewed before the long-term pricing contract expires.
*/
public val isLongTermPricingAutoRenew: kotlin.Boolean? = builder.isLongTermPricingAutoRenew
/**
* The ID of the long-term pricing type for the device.
*/
public val longTermPricingId: kotlin.String? = builder.longTermPricingId
/**
* Specifies that a device that is ordered with long-term pricing should be replaced with a new device.
*/
public val replacementJob: kotlin.String? = builder.replacementJob
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.snowball.model.UpdateLongTermPricingRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("UpdateLongTermPricingRequest(")
append("isLongTermPricingAutoRenew=$isLongTermPricingAutoRenew,")
append("longTermPricingId=$longTermPricingId,")
append("replacementJob=$replacementJob")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = isLongTermPricingAutoRenew?.hashCode() ?: 0
result = 31 * result + (longTermPricingId?.hashCode() ?: 0)
result = 31 * result + (replacementJob?.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 UpdateLongTermPricingRequest
if (isLongTermPricingAutoRenew != other.isLongTermPricingAutoRenew) return false
if (longTermPricingId != other.longTermPricingId) return false
if (replacementJob != other.replacementJob) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.snowball.model.UpdateLongTermPricingRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* If set to `true`, specifies that the current long-term pricing type for the device should be automatically renewed before the long-term pricing contract expires.
*/
public var isLongTermPricingAutoRenew: kotlin.Boolean? = null
/**
* The ID of the long-term pricing type for the device.
*/
public var longTermPricingId: kotlin.String? = null
/**
* Specifies that a device that is ordered with long-term pricing should be replaced with a new device.
*/
public var replacementJob: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.snowball.model.UpdateLongTermPricingRequest) : this() {
this.isLongTermPricingAutoRenew = x.isLongTermPricingAutoRenew
this.longTermPricingId = x.longTermPricingId
this.replacementJob = x.replacementJob
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.snowball.model.UpdateLongTermPricingRequest = UpdateLongTermPricingRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}