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

commonMain.aws.sdk.kotlin.services.deadline.model.GetQueueEnvironmentResponse.kt Maven / Gradle / Ivy

There is a newer version: 1.3.34
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.deadline.model

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

public class GetQueueEnvironmentResponse private constructor(builder: Builder) {
    /**
     * The date and time the resource was created.
     */
    public val createdAt: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createdAt) { "A non-null value must be provided for createdAt" }
    /**
     * The user or system that created this resource.>
     */
    public val createdBy: kotlin.String = requireNotNull(builder.createdBy) { "A non-null value must be provided for createdBy" }
    /**
     * The name of the queue environment.
     */
    public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
    /**
     * The priority of the queue environment.
     */
    public val priority: kotlin.Int = requireNotNull(builder.priority) { "A non-null value must be provided for priority" }
    /**
     * The queue environment ID.
     */
    public val queueEnvironmentId: kotlin.String = requireNotNull(builder.queueEnvironmentId) { "A non-null value must be provided for queueEnvironmentId" }
    /**
     * The template for the queue environment.
     */
    public val template: kotlin.String = requireNotNull(builder.template) { "A non-null value must be provided for template" }
    /**
     * The type of template for the queue environment.
     */
    public val templateType: aws.sdk.kotlin.services.deadline.model.EnvironmentTemplateType = requireNotNull(builder.templateType) { "A non-null value must be provided for templateType" }
    /**
     * The date and time the resource was updated.
     */
    public val updatedAt: aws.smithy.kotlin.runtime.time.Instant? = builder.updatedAt
    /**
     * The user or system that updated this resource.
     */
    public val updatedBy: kotlin.String? = builder.updatedBy

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

    override fun toString(): kotlin.String = buildString {
        append("GetQueueEnvironmentResponse(")
        append("createdAt=$createdAt,")
        append("createdBy=$createdBy,")
        append("name=$name,")
        append("priority=$priority,")
        append("queueEnvironmentId=$queueEnvironmentId,")
        append("template=*** Sensitive Data Redacted ***,")
        append("templateType=$templateType,")
        append("updatedAt=$updatedAt,")
        append("updatedBy=$updatedBy")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = createdAt.hashCode()
        result = 31 * result + (createdBy.hashCode())
        result = 31 * result + (name.hashCode())
        result = 31 * result + (priority)
        result = 31 * result + (queueEnvironmentId.hashCode())
        result = 31 * result + (template.hashCode())
        result = 31 * result + (templateType.hashCode())
        result = 31 * result + (updatedAt?.hashCode() ?: 0)
        result = 31 * result + (updatedBy?.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 GetQueueEnvironmentResponse

        if (createdAt != other.createdAt) return false
        if (createdBy != other.createdBy) return false
        if (name != other.name) return false
        if (priority != other.priority) return false
        if (queueEnvironmentId != other.queueEnvironmentId) return false
        if (template != other.template) return false
        if (templateType != other.templateType) return false
        if (updatedAt != other.updatedAt) return false
        if (updatedBy != other.updatedBy) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The date and time the resource was created.
         */
        public var createdAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The user or system that created this resource.>
         */
        public var createdBy: kotlin.String? = null
        /**
         * The name of the queue environment.
         */
        public var name: kotlin.String? = null
        /**
         * The priority of the queue environment.
         */
        public var priority: kotlin.Int? = null
        /**
         * The queue environment ID.
         */
        public var queueEnvironmentId: kotlin.String? = null
        /**
         * The template for the queue environment.
         */
        public var template: kotlin.String? = null
        /**
         * The type of template for the queue environment.
         */
        public var templateType: aws.sdk.kotlin.services.deadline.model.EnvironmentTemplateType? = null
        /**
         * The date and time the resource was updated.
         */
        public var updatedAt: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The user or system that updated this resource.
         */
        public var updatedBy: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.deadline.model.GetQueueEnvironmentResponse) : this() {
            this.createdAt = x.createdAt
            this.createdBy = x.createdBy
            this.name = x.name
            this.priority = x.priority
            this.queueEnvironmentId = x.queueEnvironmentId
            this.template = x.template
            this.templateType = x.templateType
            this.updatedAt = x.updatedAt
            this.updatedBy = x.updatedBy
        }

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

        internal fun correctErrors(): Builder {
            if (createdAt == null) createdAt = Instant.fromEpochSeconds(0)
            if (createdBy == null) createdBy = ""
            if (name == null) name = ""
            if (priority == null) priority = 0
            if (queueEnvironmentId == null) queueEnvironmentId = ""
            if (template == null) template = ""
            if (templateType == null) templateType = EnvironmentTemplateType.SdkUnknown("no value provided")
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy