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

commonMain.aws.sdk.kotlin.services.appstream.model.UpdateDirectoryConfigRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.appstream.model



class UpdateDirectoryConfigRequest private constructor(builder: Builder) {
    /**
     * The name of the Directory Config object.
     */
    val directoryName: kotlin.String? = builder.directoryName
    /**
     * The distinguished names of the organizational units for computer accounts.
     */
    val organizationalUnitDistinguishedNames: List? = builder.organizationalUnitDistinguishedNames
    /**
     * The credentials for the service account used by the fleet or image builder to connect to the directory.
     */
    val serviceAccountCredentials: aws.sdk.kotlin.services.appstream.model.ServiceAccountCredentials? = builder.serviceAccountCredentials

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

    override fun toString(): kotlin.String = buildString {
        append("UpdateDirectoryConfigRequest(")
        append("directoryName=$directoryName,")
        append("organizationalUnitDistinguishedNames=$organizationalUnitDistinguishedNames,")
        append("serviceAccountCredentials=$serviceAccountCredentials)")
    }

    override fun hashCode(): kotlin.Int {
        var result = directoryName?.hashCode() ?: 0
        result = 31 * result + (organizationalUnitDistinguishedNames?.hashCode() ?: 0)
        result = 31 * result + (serviceAccountCredentials?.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 UpdateDirectoryConfigRequest

        if (directoryName != other.directoryName) return false
        if (organizationalUnitDistinguishedNames != other.organizationalUnitDistinguishedNames) return false
        if (serviceAccountCredentials != other.serviceAccountCredentials) return false

        return true
    }

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

    class Builder {
        /**
         * The name of the Directory Config object.
         */
        var directoryName: kotlin.String? = null
        /**
         * The distinguished names of the organizational units for computer accounts.
         */
        var organizationalUnitDistinguishedNames: List? = null
        /**
         * The credentials for the service account used by the fleet or image builder to connect to the directory.
         */
        var serviceAccountCredentials: aws.sdk.kotlin.services.appstream.model.ServiceAccountCredentials? = null

        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.appstream.model.UpdateDirectoryConfigRequest) : this() {
            this.directoryName = x.directoryName
            this.organizationalUnitDistinguishedNames = x.organizationalUnitDistinguishedNames
            this.serviceAccountCredentials = x.serviceAccountCredentials
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy