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

commonMain.aws.sdk.kotlin.services.tnb.model.GetSolFunctionInstanceResponse.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.tnb.model

import aws.smithy.kotlin.runtime.SdkDsl

public class GetSolFunctionInstanceResponse private constructor(builder: Builder) {
    /**
     * Network function instance ARN.
     */
    public val arn: kotlin.String = requireNotNull(builder.arn) { "A non-null value must be provided for arn" }
    /**
     * Network function instance ID.
     */
    public val id: kotlin.String = requireNotNull(builder.id) { "A non-null value must be provided for id" }
    /**
     * Information about the network function.
     *
     * A network function instance is a function in a function package .
     */
    public val instantiatedVnfInfo: aws.sdk.kotlin.services.tnb.model.GetSolVnfInfo? = builder.instantiatedVnfInfo
    /**
     * Network function instantiation state.
     */
    public val instantiationState: aws.sdk.kotlin.services.tnb.model.VnfInstantiationState = requireNotNull(builder.instantiationState) { "A non-null value must be provided for instantiationState" }
    /**
     * The metadata of a network function instance.
     *
     * A network function instance is a function in a function package .
     */
    public val metadata: aws.sdk.kotlin.services.tnb.model.GetSolFunctionInstanceMetadata? = builder.metadata
    /**
     * Network instance ID.
     */
    public val nsInstanceId: kotlin.String = requireNotNull(builder.nsInstanceId) { "A non-null value must be provided for nsInstanceId" }
    /**
     * A tag is a label that you assign to an Amazon Web Services resource. Each tag consists of a key and an optional value. You can use tags to search and filter your resources or track your Amazon Web Services costs.
     */
    public val tags: Map? = builder.tags
    /**
     * Function package ID.
     */
    public val vnfPkgId: kotlin.String = requireNotNull(builder.vnfPkgId) { "A non-null value must be provided for vnfPkgId" }
    /**
     * Network function product name.
     */
    public val vnfProductName: kotlin.String? = builder.vnfProductName
    /**
     * Network function provider.
     */
    public val vnfProvider: kotlin.String? = builder.vnfProvider
    /**
     * Function package descriptor ID.
     */
    public val vnfdId: kotlin.String = requireNotNull(builder.vnfdId) { "A non-null value must be provided for vnfdId" }
    /**
     * Function package descriptor version.
     */
    public val vnfdVersion: kotlin.String? = builder.vnfdVersion

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

    override fun toString(): kotlin.String = buildString {
        append("GetSolFunctionInstanceResponse(")
        append("arn=$arn,")
        append("id=$id,")
        append("instantiatedVnfInfo=$instantiatedVnfInfo,")
        append("instantiationState=$instantiationState,")
        append("metadata=$metadata,")
        append("nsInstanceId=$nsInstanceId,")
        append("tags=*** Sensitive Data Redacted ***,")
        append("vnfPkgId=$vnfPkgId,")
        append("vnfProductName=$vnfProductName,")
        append("vnfProvider=$vnfProvider,")
        append("vnfdId=$vnfdId,")
        append("vnfdVersion=$vnfdVersion")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn.hashCode()
        result = 31 * result + (id.hashCode())
        result = 31 * result + (instantiatedVnfInfo?.hashCode() ?: 0)
        result = 31 * result + (instantiationState.hashCode())
        result = 31 * result + (metadata?.hashCode() ?: 0)
        result = 31 * result + (nsInstanceId.hashCode())
        result = 31 * result + (tags?.hashCode() ?: 0)
        result = 31 * result + (vnfPkgId.hashCode())
        result = 31 * result + (vnfProductName?.hashCode() ?: 0)
        result = 31 * result + (vnfProvider?.hashCode() ?: 0)
        result = 31 * result + (vnfdId.hashCode())
        result = 31 * result + (vnfdVersion?.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 GetSolFunctionInstanceResponse

        if (arn != other.arn) return false
        if (id != other.id) return false
        if (instantiatedVnfInfo != other.instantiatedVnfInfo) return false
        if (instantiationState != other.instantiationState) return false
        if (metadata != other.metadata) return false
        if (nsInstanceId != other.nsInstanceId) return false
        if (tags != other.tags) return false
        if (vnfPkgId != other.vnfPkgId) return false
        if (vnfProductName != other.vnfProductName) return false
        if (vnfProvider != other.vnfProvider) return false
        if (vnfdId != other.vnfdId) return false
        if (vnfdVersion != other.vnfdVersion) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * Network function instance ARN.
         */
        public var arn: kotlin.String? = null
        /**
         * Network function instance ID.
         */
        public var id: kotlin.String? = null
        /**
         * Information about the network function.
         *
         * A network function instance is a function in a function package .
         */
        public var instantiatedVnfInfo: aws.sdk.kotlin.services.tnb.model.GetSolVnfInfo? = null
        /**
         * Network function instantiation state.
         */
        public var instantiationState: aws.sdk.kotlin.services.tnb.model.VnfInstantiationState? = null
        /**
         * The metadata of a network function instance.
         *
         * A network function instance is a function in a function package .
         */
        public var metadata: aws.sdk.kotlin.services.tnb.model.GetSolFunctionInstanceMetadata? = null
        /**
         * Network instance ID.
         */
        public var nsInstanceId: kotlin.String? = null
        /**
         * A tag is a label that you assign to an Amazon Web Services resource. Each tag consists of a key and an optional value. You can use tags to search and filter your resources or track your Amazon Web Services costs.
         */
        public var tags: Map? = null
        /**
         * Function package ID.
         */
        public var vnfPkgId: kotlin.String? = null
        /**
         * Network function product name.
         */
        public var vnfProductName: kotlin.String? = null
        /**
         * Network function provider.
         */
        public var vnfProvider: kotlin.String? = null
        /**
         * Function package descriptor ID.
         */
        public var vnfdId: kotlin.String? = null
        /**
         * Function package descriptor version.
         */
        public var vnfdVersion: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.tnb.model.GetSolFunctionInstanceResponse) : this() {
            this.arn = x.arn
            this.id = x.id
            this.instantiatedVnfInfo = x.instantiatedVnfInfo
            this.instantiationState = x.instantiationState
            this.metadata = x.metadata
            this.nsInstanceId = x.nsInstanceId
            this.tags = x.tags
            this.vnfPkgId = x.vnfPkgId
            this.vnfProductName = x.vnfProductName
            this.vnfProvider = x.vnfProvider
            this.vnfdId = x.vnfdId
            this.vnfdVersion = x.vnfdVersion
        }

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

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

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

        internal fun correctErrors(): Builder {
            if (arn == null) arn = ""
            if (id == null) id = ""
            if (instantiationState == null) instantiationState = VnfInstantiationState.SdkUnknown("no value provided")
            if (nsInstanceId == null) nsInstanceId = ""
            if (vnfPkgId == null) vnfPkgId = ""
            if (vnfdId == null) vnfdId = ""
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy