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

commonMain.aws.sdk.kotlin.services.cloudwatch.model.DescribeAnomalyDetectorsRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.cloudwatch.model



public class DescribeAnomalyDetectorsRequest private constructor(builder: Builder) {
    /**
     * The anomaly detector types to request when using `DescribeAnomalyDetectorsInput`. If empty, defaults to `SINGLE_METRIC`.
     */
    public val anomalyDetectorTypes: List? = builder.anomalyDetectorTypes
    /**
     * Limits the results to only the anomaly detection models that are associated with the specified metric dimensions. If there are multiple metrics that have these dimensions and have anomaly detection models associated, they're all returned.
     */
    public val dimensions: List? = builder.dimensions
    /**
     * The maximum number of results to return in one operation. The maximum value that you can specify is 100.
     *
     * To retrieve the remaining results, make another call with the returned `NextToken` value.
     */
    public val maxResults: kotlin.Int? = builder.maxResults
    /**
     * Limits the results to only the anomaly detection models that are associated with the specified metric name. If there are multiple metrics with this name in different namespaces that have anomaly detection models, they're all returned.
     */
    public val metricName: kotlin.String? = builder.metricName
    /**
     * Limits the results to only the anomaly detection models that are associated with the specified namespace.
     */
    public val namespace: kotlin.String? = builder.namespace
    /**
     * Use the token returned by the previous operation to request the next page of results.
     */
    public val nextToken: kotlin.String? = builder.nextToken

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

    override fun toString(): kotlin.String = buildString {
        append("DescribeAnomalyDetectorsRequest(")
        append("anomalyDetectorTypes=$anomalyDetectorTypes,")
        append("dimensions=$dimensions,")
        append("maxResults=$maxResults,")
        append("metricName=$metricName,")
        append("namespace=$namespace,")
        append("nextToken=$nextToken")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = anomalyDetectorTypes?.hashCode() ?: 0
        result = 31 * result + (dimensions?.hashCode() ?: 0)
        result = 31 * result + (maxResults ?: 0)
        result = 31 * result + (metricName?.hashCode() ?: 0)
        result = 31 * result + (namespace?.hashCode() ?: 0)
        result = 31 * result + (nextToken?.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 DescribeAnomalyDetectorsRequest

        if (anomalyDetectorTypes != other.anomalyDetectorTypes) return false
        if (dimensions != other.dimensions) return false
        if (maxResults != other.maxResults) return false
        if (metricName != other.metricName) return false
        if (namespace != other.namespace) return false
        if (nextToken != other.nextToken) return false

        return true
    }

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

    public class Builder {
        /**
         * The anomaly detector types to request when using `DescribeAnomalyDetectorsInput`. If empty, defaults to `SINGLE_METRIC`.
         */
        public var anomalyDetectorTypes: List? = null
        /**
         * Limits the results to only the anomaly detection models that are associated with the specified metric dimensions. If there are multiple metrics that have these dimensions and have anomaly detection models associated, they're all returned.
         */
        public var dimensions: List? = null
        /**
         * The maximum number of results to return in one operation. The maximum value that you can specify is 100.
         *
         * To retrieve the remaining results, make another call with the returned `NextToken` value.
         */
        public var maxResults: kotlin.Int? = null
        /**
         * Limits the results to only the anomaly detection models that are associated with the specified metric name. If there are multiple metrics with this name in different namespaces that have anomaly detection models, they're all returned.
         */
        public var metricName: kotlin.String? = null
        /**
         * Limits the results to only the anomaly detection models that are associated with the specified namespace.
         */
        public var namespace: kotlin.String? = null
        /**
         * Use the token returned by the previous operation to request the next page of results.
         */
        public var nextToken: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.cloudwatch.model.DescribeAnomalyDetectorsRequest) : this() {
            this.anomalyDetectorTypes = x.anomalyDetectorTypes
            this.dimensions = x.dimensions
            this.maxResults = x.maxResults
            this.metricName = x.metricName
            this.namespace = x.namespace
            this.nextToken = x.nextToken
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy