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

commonMain.aws.sdk.kotlin.services.mwaa.model.UpdateNetworkConfigurationInput.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.mwaa.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Defines the VPC networking components used to secure and enable network traffic between the Amazon Web Services resources for your environment. For more information, see [About networking on Amazon MWAA](https://docs.aws.amazon.com/mwaa/latest/userguide/networking-about.html).
 */
public class UpdateNetworkConfigurationInput private constructor(builder: Builder) {
    /**
     * A list of security group IDs. A security group must be attached to the same VPC as the subnets. For more information, see [Security in your VPC on Amazon MWAA](https://docs.aws.amazon.com/mwaa/latest/userguide/vpc-security.html).
     */
    public val securityGroupIds: List = requireNotNull(builder.securityGroupIds) { "A non-null value must be provided for securityGroupIds" }

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

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

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

        if (securityGroupIds != other.securityGroupIds) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * A list of security group IDs. A security group must be attached to the same VPC as the subnets. For more information, see [Security in your VPC on Amazon MWAA](https://docs.aws.amazon.com/mwaa/latest/userguide/vpc-security.html).
         */
        public var securityGroupIds: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.mwaa.model.UpdateNetworkConfigurationInput) : this() {
            this.securityGroupIds = x.securityGroupIds
        }

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

        internal fun correctErrors(): Builder {
            if (securityGroupIds == null) securityGroupIds = emptyList()
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy