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

commonMain.aws.sdk.kotlin.services.iotfleetwise.model.DecoderManifestSummary.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.iotfleetwise.model

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

/**
 * Information about a created decoder manifest. You can use the API operation to return this information about multiple decoder manifests.
 */
public class DecoderManifestSummary private constructor(builder: Builder) {
    /**
     * The ARN of a vehicle model (model manifest) associated with the decoder manifest.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * The time the decoder manifest was created in seconds since epoch (January 1, 1970 at midnight UTC time).
     */
    public val creationTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.creationTime) { "A non-null value must be provided for creationTime" }
    /**
     * A brief description of the decoder manifest.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The time the decoder manifest was last updated in seconds since epoch (January 1, 1970 at midnight UTC time).
     */
    public val lastModificationTime: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.lastModificationTime) { "A non-null value must be provided for lastModificationTime" }
    /**
     * The detailed message for the decoder manifest. When a decoder manifest is in an `INVALID` status, the message contains detailed reason and help information.
     */
    public val message: kotlin.String? = builder.message
    /**
     * The ARN of a vehicle model (model manifest) associated with the decoder manifest.
     */
    public val modelManifestArn: kotlin.String? = builder.modelManifestArn
    /**
     * The name of the decoder manifest.
     */
    public val name: kotlin.String? = builder.name
    /**
     * The state of the decoder manifest. If the status is `ACTIVE`, the decoder manifest can't be edited. If the status is marked `DRAFT`, you can edit the decoder manifest.
     */
    public val status: aws.sdk.kotlin.services.iotfleetwise.model.ManifestStatus? = builder.status

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

    override fun toString(): kotlin.String = buildString {
        append("DecoderManifestSummary(")
        append("arn=$arn,")
        append("creationTime=$creationTime,")
        append("description=$description,")
        append("lastModificationTime=$lastModificationTime,")
        append("message=$message,")
        append("modelManifestArn=$modelManifestArn,")
        append("name=$name,")
        append("status=$status")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (creationTime.hashCode())
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (lastModificationTime.hashCode())
        result = 31 * result + (message?.hashCode() ?: 0)
        result = 31 * result + (modelManifestArn?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (status?.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 DecoderManifestSummary

        if (arn != other.arn) return false
        if (creationTime != other.creationTime) return false
        if (description != other.description) return false
        if (lastModificationTime != other.lastModificationTime) return false
        if (message != other.message) return false
        if (modelManifestArn != other.modelManifestArn) return false
        if (name != other.name) return false
        if (status != other.status) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The ARN of a vehicle model (model manifest) associated with the decoder manifest.
         */
        public var arn: kotlin.String? = null
        /**
         * The time the decoder manifest was created in seconds since epoch (January 1, 1970 at midnight UTC time).
         */
        public var creationTime: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * A brief description of the decoder manifest.
         */
        public var description: kotlin.String? = null
        /**
         * The time the decoder manifest was last updated in seconds since epoch (January 1, 1970 at midnight UTC time).
         */
        public var lastModificationTime: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The detailed message for the decoder manifest. When a decoder manifest is in an `INVALID` status, the message contains detailed reason and help information.
         */
        public var message: kotlin.String? = null
        /**
         * The ARN of a vehicle model (model manifest) associated with the decoder manifest.
         */
        public var modelManifestArn: kotlin.String? = null
        /**
         * The name of the decoder manifest.
         */
        public var name: kotlin.String? = null
        /**
         * The state of the decoder manifest. If the status is `ACTIVE`, the decoder manifest can't be edited. If the status is marked `DRAFT`, you can edit the decoder manifest.
         */
        public var status: aws.sdk.kotlin.services.iotfleetwise.model.ManifestStatus? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.iotfleetwise.model.DecoderManifestSummary) : this() {
            this.arn = x.arn
            this.creationTime = x.creationTime
            this.description = x.description
            this.lastModificationTime = x.lastModificationTime
            this.message = x.message
            this.modelManifestArn = x.modelManifestArn
            this.name = x.name
            this.status = x.status
        }

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

        internal fun correctErrors(): Builder {
            if (creationTime == null) creationTime = Instant.fromEpochSeconds(0)
            if (lastModificationTime == null) lastModificationTime = Instant.fromEpochSeconds(0)
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy