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

commonMain.aws.sdk.kotlin.services.migrationhub.model.ApplicationState.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.migrationhub.model

import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant

/**
 * The state of an application discovered through Migration Hub import, the AWS Agentless Discovery Connector, or the AWS Application Discovery Agent.
 */
public class ApplicationState private constructor(builder: Builder) {
    /**
     * The configurationId from the Application Discovery Service that uniquely identifies an application.
     */
    public val applicationId: kotlin.String? = builder.applicationId
    /**
     * The current status of an application.
     */
    public val applicationStatus: aws.sdk.kotlin.services.migrationhub.model.ApplicationStatus? = builder.applicationStatus
    /**
     * The timestamp when the application status was last updated.
     */
    public val lastUpdatedTime: aws.smithy.kotlin.runtime.time.Instant? = builder.lastUpdatedTime

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

    override fun toString(): kotlin.String = buildString {
        append("ApplicationState(")
        append("applicationId=$applicationId,")
        append("applicationStatus=$applicationStatus,")
        append("lastUpdatedTime=$lastUpdatedTime")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = applicationId?.hashCode() ?: 0
        result = 31 * result + (applicationStatus?.hashCode() ?: 0)
        result = 31 * result + (lastUpdatedTime?.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 ApplicationState

        if (applicationId != other.applicationId) return false
        if (applicationStatus != other.applicationStatus) return false
        if (lastUpdatedTime != other.lastUpdatedTime) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The configurationId from the Application Discovery Service that uniquely identifies an application.
         */
        public var applicationId: kotlin.String? = null
        /**
         * The current status of an application.
         */
        public var applicationStatus: aws.sdk.kotlin.services.migrationhub.model.ApplicationStatus? = null
        /**
         * The timestamp when the application status was last updated.
         */
        public var lastUpdatedTime: aws.smithy.kotlin.runtime.time.Instant? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.migrationhub.model.ApplicationState) : this() {
            this.applicationId = x.applicationId
            this.applicationStatus = x.applicationStatus
            this.lastUpdatedTime = x.lastUpdatedTime
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy