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

commonMain.aws.sdk.kotlin.services.xray.model.Group.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.xray.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Details and metadata for a group.
 */
public class Group private constructor(builder: Builder) {
    /**
     * The filter expression defining the parameters to include traces.
     */
    public val filterExpression: kotlin.String? = builder.filterExpression
    /**
     * The Amazon Resource Name (ARN) of the group generated based on the GroupName.
     */
    public val groupArn: kotlin.String? = builder.groupArn
    /**
     * The unique case-sensitive name of the group.
     */
    public val groupName: kotlin.String? = builder.groupName
    /**
     * The structure containing configurations related to insights.
     * + The InsightsEnabled boolean can be set to true to enable insights for the group or false to disable insights for the group.
     * + The NotificationsEnabled boolean can be set to true to enable insights notifications through Amazon EventBridge for the group.
     */
    public val insightsConfiguration: aws.sdk.kotlin.services.xray.model.InsightsConfiguration? = builder.insightsConfiguration

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

    override fun toString(): kotlin.String = buildString {
        append("Group(")
        append("filterExpression=$filterExpression,")
        append("groupArn=$groupArn,")
        append("groupName=$groupName,")
        append("insightsConfiguration=$insightsConfiguration")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = filterExpression?.hashCode() ?: 0
        result = 31 * result + (groupArn?.hashCode() ?: 0)
        result = 31 * result + (groupName?.hashCode() ?: 0)
        result = 31 * result + (insightsConfiguration?.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 Group

        if (filterExpression != other.filterExpression) return false
        if (groupArn != other.groupArn) return false
        if (groupName != other.groupName) return false
        if (insightsConfiguration != other.insightsConfiguration) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The filter expression defining the parameters to include traces.
         */
        public var filterExpression: kotlin.String? = null
        /**
         * The Amazon Resource Name (ARN) of the group generated based on the GroupName.
         */
        public var groupArn: kotlin.String? = null
        /**
         * The unique case-sensitive name of the group.
         */
        public var groupName: kotlin.String? = null
        /**
         * The structure containing configurations related to insights.
         * + The InsightsEnabled boolean can be set to true to enable insights for the group or false to disable insights for the group.
         * + The NotificationsEnabled boolean can be set to true to enable insights notifications through Amazon EventBridge for the group.
         */
        public var insightsConfiguration: aws.sdk.kotlin.services.xray.model.InsightsConfiguration? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.xray.model.Group) : this() {
            this.filterExpression = x.filterExpression
            this.groupArn = x.groupArn
            this.groupName = x.groupName
            this.insightsConfiguration = x.insightsConfiguration
        }

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy