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

commonMain.aws.sdk.kotlin.services.route53.model.GetTrafficPolicyInstanceCountResponse.kt Maven / Gradle / Ivy

There is a newer version: 1.3.76
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.route53.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * A complex type that contains information about the resource record sets that Amazon Route 53 created based on a specified traffic policy.
 */
public class GetTrafficPolicyInstanceCountResponse private constructor(builder: Builder) {
    /**
     * The number of traffic policy instances that are associated with the current Amazon Web Services account.
     */
    public val trafficPolicyInstanceCount: kotlin.Int = requireNotNull(builder.trafficPolicyInstanceCount) { "A non-null value must be provided for trafficPolicyInstanceCount" }

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

    override fun toString(): kotlin.String = buildString {
        append("GetTrafficPolicyInstanceCountResponse(")
        append("trafficPolicyInstanceCount=$trafficPolicyInstanceCount")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = trafficPolicyInstanceCount
        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 GetTrafficPolicyInstanceCountResponse

        if (trafficPolicyInstanceCount != other.trafficPolicyInstanceCount) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The number of traffic policy instances that are associated with the current Amazon Web Services account.
         */
        public var trafficPolicyInstanceCount: kotlin.Int? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.route53.model.GetTrafficPolicyInstanceCountResponse) : this() {
            this.trafficPolicyInstanceCount = x.trafficPolicyInstanceCount
        }

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

        internal fun correctErrors(): Builder {
            if (trafficPolicyInstanceCount == null) trafficPolicyInstanceCount = 0
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy