commonMain.aws.sdk.kotlin.services.lookoutmetrics.model.CloudWatchConfig.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of lookoutmetrics-jvm Show documentation
Show all versions of lookoutmetrics-jvm Show documentation
The AWS SDK for Kotlin client for LookoutMetrics
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.lookoutmetrics.model
/**
* Details about an Amazon CloudWatch datasource.
*/
public class CloudWatchConfig private constructor(builder: Builder) {
/**
* Settings for backtest mode.
*/
public val backTestConfiguration: aws.sdk.kotlin.services.lookoutmetrics.model.BackTestConfiguration? = builder.backTestConfiguration
/**
* An IAM role that gives Amazon Lookout for Metrics permission to access data in Amazon CloudWatch.
*/
public val roleArn: kotlin.String? = builder.roleArn
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.lookoutmetrics.model.CloudWatchConfig = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CloudWatchConfig(")
append("backTestConfiguration=$backTestConfiguration,")
append("roleArn=$roleArn")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = backTestConfiguration?.hashCode() ?: 0
result = 31 * result + (roleArn?.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 CloudWatchConfig
if (backTestConfiguration != other.backTestConfiguration) return false
if (roleArn != other.roleArn) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.lookoutmetrics.model.CloudWatchConfig = Builder(this).apply(block).build()
public class Builder {
/**
* Settings for backtest mode.
*/
public var backTestConfiguration: aws.sdk.kotlin.services.lookoutmetrics.model.BackTestConfiguration? = null
/**
* An IAM role that gives Amazon Lookout for Metrics permission to access data in Amazon CloudWatch.
*/
public var roleArn: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.lookoutmetrics.model.CloudWatchConfig) : this() {
this.backTestConfiguration = x.backTestConfiguration
this.roleArn = x.roleArn
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.lookoutmetrics.model.CloudWatchConfig = CloudWatchConfig(this)
/**
* construct an [aws.sdk.kotlin.services.lookoutmetrics.model.BackTestConfiguration] inside the given [block]
*/
public fun backTestConfiguration(block: aws.sdk.kotlin.services.lookoutmetrics.model.BackTestConfiguration.Builder.() -> kotlin.Unit) {
this.backTestConfiguration = aws.sdk.kotlin.services.lookoutmetrics.model.BackTestConfiguration.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy