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

commonMain.aws.sdk.kotlin.services.medicalimaging.model.ImageSetsMetadataSummary.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.medicalimaging.model

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

/**
 * Summary of the image set metadata.
 */
public class ImageSetsMetadataSummary private constructor(builder: Builder) {
    /**
     * The time an image set is created. Sample creation date is provided in `1985-04-12T23:20:50.52Z` format.
     */
    public val createdAt: aws.smithy.kotlin.runtime.time.Instant? = builder.createdAt
    /**
     * The DICOM tags associated with the image set.
     */
    public val dicomTags: aws.sdk.kotlin.services.medicalimaging.model.DicomTags? = builder.dicomTags
    /**
     * The image set identifier.
     */
    public val imageSetId: kotlin.String = requireNotNull(builder.imageSetId) { "A non-null value must be provided for imageSetId" }
    /**
     * The time an image set was last updated.
     */
    public val updatedAt: aws.smithy.kotlin.runtime.time.Instant? = builder.updatedAt
    /**
     * The image set version.
     */
    public val version: kotlin.Int? = builder.version

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

    override fun toString(): kotlin.String = buildString {
        append("ImageSetsMetadataSummary(")
        append("createdAt=$createdAt,")
        append("dicomTags=$dicomTags,")
        append("imageSetId=$imageSetId,")
        append("updatedAt=$updatedAt,")
        append("version=$version")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = createdAt?.hashCode() ?: 0
        result = 31 * result + (dicomTags?.hashCode() ?: 0)
        result = 31 * result + (imageSetId.hashCode())
        result = 31 * result + (updatedAt?.hashCode() ?: 0)
        result = 31 * result + (version ?: 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 ImageSetsMetadataSummary

        if (createdAt != other.createdAt) return false
        if (dicomTags != other.dicomTags) return false
        if (imageSetId != other.imageSetId) return false
        if (updatedAt != other.updatedAt) return false
        if (version != other.version) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The time an image set is created. Sample creation date is provided in `1985-04-12T23:20:50.52Z` format.
         */
        public var createdAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The DICOM tags associated with the image set.
         */
        public var dicomTags: aws.sdk.kotlin.services.medicalimaging.model.DicomTags? = null
        /**
         * The image set identifier.
         */
        public var imageSetId: kotlin.String? = null
        /**
         * The time an image set was last updated.
         */
        public var updatedAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The image set version.
         */
        public var version: kotlin.Int? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.medicalimaging.model.ImageSetsMetadataSummary) : this() {
            this.createdAt = x.createdAt
            this.dicomTags = x.dicomTags
            this.imageSetId = x.imageSetId
            this.updatedAt = x.updatedAt
            this.version = x.version
        }

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

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

        internal fun correctErrors(): Builder {
            if (imageSetId == null) imageSetId = ""
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy