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

commonMain.aws.sdk.kotlin.services.qbusiness.model.UsersAndGroups.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.qbusiness.model



/**
 * Provides information about users and groups associated with a topic control rule.
 */
public class UsersAndGroups private constructor(builder: Builder) {
    /**
     * The user groups associated with a topic control rule.
     */
    public val userGroups: List? = builder.userGroups
    /**
     * The user ids associated with a topic control rule.
     */
    public val userIds: List? = builder.userIds

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

    override fun toString(): kotlin.String = buildString {
        append("UsersAndGroups(")
        append("userGroups=$userGroups,")
        append("userIds=$userIds")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = userGroups?.hashCode() ?: 0
        result = 31 * result + (userIds?.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 UsersAndGroups

        if (userGroups != other.userGroups) return false
        if (userIds != other.userIds) return false

        return true
    }

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

    public class Builder {
        /**
         * The user groups associated with a topic control rule.
         */
        public var userGroups: List? = null
        /**
         * The user ids associated with a topic control rule.
         */
        public var userIds: List? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.qbusiness.model.UsersAndGroups) : this() {
            this.userGroups = x.userGroups
            this.userIds = x.userIds
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy