commonMain.aws.sdk.kotlin.services.glue.model.MetricBasedObservation.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of glue-jvm Show documentation
Show all versions of glue-jvm Show documentation
The AWS SDK for Kotlin client for Glue
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.glue.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Describes the metric based observation generated based on evaluated data quality metrics.
*/
public class MetricBasedObservation private constructor(builder: Builder) {
/**
* The name of the data quality metric used for generating the observation.
*/
public val metricName: kotlin.String? = builder.metricName
/**
* An object of type `DataQualityMetricValues` representing the analysis of the data quality metric value.
*/
public val metricValues: aws.sdk.kotlin.services.glue.model.DataQualityMetricValues? = builder.metricValues
/**
* A list of new data quality rules generated as part of the observation based on the data quality metric value.
*/
public val newRules: List? = builder.newRules
/**
* The Statistic ID.
*/
public val statisticId: kotlin.String? = builder.statisticId
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.glue.model.MetricBasedObservation = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("MetricBasedObservation(")
append("metricName=$metricName,")
append("metricValues=$metricValues,")
append("newRules=$newRules,")
append("statisticId=$statisticId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = metricName?.hashCode() ?: 0
result = 31 * result + (metricValues?.hashCode() ?: 0)
result = 31 * result + (newRules?.hashCode() ?: 0)
result = 31 * result + (statisticId?.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 MetricBasedObservation
if (metricName != other.metricName) return false
if (metricValues != other.metricValues) return false
if (newRules != other.newRules) return false
if (statisticId != other.statisticId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.glue.model.MetricBasedObservation = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The name of the data quality metric used for generating the observation.
*/
public var metricName: kotlin.String? = null
/**
* An object of type `DataQualityMetricValues` representing the analysis of the data quality metric value.
*/
public var metricValues: aws.sdk.kotlin.services.glue.model.DataQualityMetricValues? = null
/**
* A list of new data quality rules generated as part of the observation based on the data quality metric value.
*/
public var newRules: List? = null
/**
* The Statistic ID.
*/
public var statisticId: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.glue.model.MetricBasedObservation) : this() {
this.metricName = x.metricName
this.metricValues = x.metricValues
this.newRules = x.newRules
this.statisticId = x.statisticId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.glue.model.MetricBasedObservation = MetricBasedObservation(this)
/**
* construct an [aws.sdk.kotlin.services.glue.model.DataQualityMetricValues] inside the given [block]
*/
public fun metricValues(block: aws.sdk.kotlin.services.glue.model.DataQualityMetricValues.Builder.() -> kotlin.Unit) {
this.metricValues = aws.sdk.kotlin.services.glue.model.DataQualityMetricValues.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}