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

commonMain.aws.sdk.kotlin.services.batch.model.NetworkInterface.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.batch.model



/**
 * An object that represents the elastic network interface for a multi-node parallel job node.
 */
public class NetworkInterface private constructor(builder: Builder) {
    /**
     * The attachment ID for the network interface.
     */
    public val attachmentId: kotlin.String? = builder.attachmentId
    /**
     * The private IPv6 address for the network interface.
     */
    public val ipv6Address: kotlin.String? = builder.ipv6Address
    /**
     * The private IPv4 address for the network interface.
     */
    public val privateIpv4Address: kotlin.String? = builder.privateIpv4Address

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

    override fun toString(): kotlin.String = buildString {
        append("NetworkInterface(")
        append("attachmentId=$attachmentId,")
        append("ipv6Address=$ipv6Address,")
        append("privateIpv4Address=$privateIpv4Address")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = attachmentId?.hashCode() ?: 0
        result = 31 * result + (ipv6Address?.hashCode() ?: 0)
        result = 31 * result + (privateIpv4Address?.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 NetworkInterface

        if (attachmentId != other.attachmentId) return false
        if (ipv6Address != other.ipv6Address) return false
        if (privateIpv4Address != other.privateIpv4Address) return false

        return true
    }

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

    public class Builder {
        /**
         * The attachment ID for the network interface.
         */
        public var attachmentId: kotlin.String? = null
        /**
         * The private IPv6 address for the network interface.
         */
        public var ipv6Address: kotlin.String? = null
        /**
         * The private IPv4 address for the network interface.
         */
        public var privateIpv4Address: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.batch.model.NetworkInterface) : this() {
            this.attachmentId = x.attachmentId
            this.ipv6Address = x.ipv6Address
            this.privateIpv4Address = x.privateIpv4Address
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy