All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.iottwinmaker.model.UpdatePricingPlanRequest.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.iottwinmaker.model



public class UpdatePricingPlanRequest private constructor(builder: Builder) {
    /**
     * The bundle names.
     */
    public val bundleNames: List? = builder.bundleNames
    /**
     * The pricing mode.
     */
    public val pricingMode: aws.sdk.kotlin.services.iottwinmaker.model.PricingMode = requireNotNull(builder.pricingMode) { "A non-null value must be provided for pricingMode" }

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.iottwinmaker.model.UpdatePricingPlanRequest = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("UpdatePricingPlanRequest(")
        append("bundleNames=$bundleNames,")
        append("pricingMode=$pricingMode")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = bundleNames?.hashCode() ?: 0
        result = 31 * result + (pricingMode.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 UpdatePricingPlanRequest

        if (bundleNames != other.bundleNames) return false
        if (pricingMode != other.pricingMode) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.iottwinmaker.model.UpdatePricingPlanRequest = Builder(this).apply(block).build()

    public class Builder {
        /**
         * The bundle names.
         */
        public var bundleNames: List? = null
        /**
         * The pricing mode.
         */
        public var pricingMode: aws.sdk.kotlin.services.iottwinmaker.model.PricingMode? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.iottwinmaker.model.UpdatePricingPlanRequest) : this() {
            this.bundleNames = x.bundleNames
            this.pricingMode = x.pricingMode
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.iottwinmaker.model.UpdatePricingPlanRequest = UpdatePricingPlanRequest(this)

        internal fun correctErrors(): Builder {
            if (pricingMode == null) pricingMode = PricingMode.SdkUnknown("no value provided")
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy