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

commonMain.aws.sdk.kotlin.services.vpclattice.model.UpdateTargetGroupResponse.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.vpclattice.model

import aws.smithy.kotlin.runtime.SdkDsl

public class UpdateTargetGroupResponse private constructor(builder: Builder) {
    /**
     * The Amazon Resource Name (ARN) of the target group.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * The target group configuration.
     */
    public val config: aws.sdk.kotlin.services.vpclattice.model.TargetGroupConfig? = builder.config
    /**
     * The ID of the target group.
     */
    public val id: kotlin.String? = builder.id
    /**
     * The name of the target group.
     */
    public val name: kotlin.String? = builder.name
    /**
     * The status.
     */
    public val status: aws.sdk.kotlin.services.vpclattice.model.TargetGroupStatus? = builder.status
    /**
     * The target group type.
     */
    public val type: aws.sdk.kotlin.services.vpclattice.model.TargetGroupType? = builder.type

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

    override fun toString(): kotlin.String = buildString {
        append("UpdateTargetGroupResponse(")
        append("arn=$arn,")
        append("config=$config,")
        append("id=$id,")
        append("name=$name,")
        append("status=$status,")
        append("type=$type")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (config?.hashCode() ?: 0)
        result = 31 * result + (id?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (status?.hashCode() ?: 0)
        result = 31 * result + (type?.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 UpdateTargetGroupResponse

        if (arn != other.arn) return false
        if (config != other.config) return false
        if (id != other.id) return false
        if (name != other.name) return false
        if (status != other.status) return false
        if (type != other.type) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The Amazon Resource Name (ARN) of the target group.
         */
        public var arn: kotlin.String? = null
        /**
         * The target group configuration.
         */
        public var config: aws.sdk.kotlin.services.vpclattice.model.TargetGroupConfig? = null
        /**
         * The ID of the target group.
         */
        public var id: kotlin.String? = null
        /**
         * The name of the target group.
         */
        public var name: kotlin.String? = null
        /**
         * The status.
         */
        public var status: aws.sdk.kotlin.services.vpclattice.model.TargetGroupStatus? = null
        /**
         * The target group type.
         */
        public var type: aws.sdk.kotlin.services.vpclattice.model.TargetGroupType? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.vpclattice.model.UpdateTargetGroupResponse) : this() {
            this.arn = x.arn
            this.config = x.config
            this.id = x.id
            this.name = x.name
            this.status = x.status
            this.type = x.type
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.vpclattice.model.TargetGroupConfig] inside the given [block]
         */
        public fun config(block: aws.sdk.kotlin.services.vpclattice.model.TargetGroupConfig.Builder.() -> kotlin.Unit) {
            this.config = aws.sdk.kotlin.services.vpclattice.model.TargetGroupConfig.invoke(block)
        }

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy