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

commonMain.aws.sdk.kotlin.services.deadline.model.CreateFarmRequest.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

public class CreateFarmRequest private constructor(builder: Builder) {
    /**
     * The unique token which the server uses to recognize retries of the same request.
     */
    public val clientToken: kotlin.String? = builder.clientToken
    /**
     * The description of the farm.
     *
     * This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The display name of the farm.
     *
     * This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
     */
    public val displayName: kotlin.String? = builder.displayName
    /**
     * The ARN of the KMS key to use on the farm.
     */
    public val kmsKeyArn: kotlin.String? = builder.kmsKeyArn
    /**
     * The tags to add to your farm. Each tag consists of a tag key and a tag value. Tag keys and values are both required, but tag values can be empty strings.
     */
    public val tags: Map? = builder.tags

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

    override fun toString(): kotlin.String = buildString {
        append("CreateFarmRequest(")
        append("clientToken=$clientToken,")
        append("description=*** Sensitive Data Redacted ***,")
        append("displayName=$displayName,")
        append("kmsKeyArn=$kmsKeyArn,")
        append("tags=$tags")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = clientToken?.hashCode() ?: 0
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (displayName?.hashCode() ?: 0)
        result = 31 * result + (kmsKeyArn?.hashCode() ?: 0)
        result = 31 * result + (tags?.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 CreateFarmRequest

        if (clientToken != other.clientToken) return false
        if (description != other.description) return false
        if (displayName != other.displayName) return false
        if (kmsKeyArn != other.kmsKeyArn) return false
        if (tags != other.tags) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The unique token which the server uses to recognize retries of the same request.
         */
        public var clientToken: kotlin.String? = null
        /**
         * The description of the farm.
         *
         * This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
         */
        public var description: kotlin.String? = null
        /**
         * The display name of the farm.
         *
         * This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.
         */
        public var displayName: kotlin.String? = null
        /**
         * The ARN of the KMS key to use on the farm.
         */
        public var kmsKeyArn: kotlin.String? = null
        /**
         * The tags to add to your farm. Each tag consists of a tag key and a tag value. Tag keys and values are both required, but tag values can be empty strings.
         */
        public var tags: Map? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.deadline.model.CreateFarmRequest) : this() {
            this.clientToken = x.clientToken
            this.description = x.description
            this.displayName = x.displayName
            this.kmsKeyArn = x.kmsKeyArn
            this.tags = x.tags
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy