
commonMain.aws.sdk.kotlin.services.rum.model.MetricDestinationSummary.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.rum.model
/**
* A structure that displays information about one destination that CloudWatch RUM sends extended metrics to.
*/
public class MetricDestinationSummary private constructor(builder: Builder) {
/**
* Specifies whether the destination is `CloudWatch` or `Evidently`.
*/
public val destination: aws.sdk.kotlin.services.rum.model.MetricDestination? = builder.destination
/**
* If the destination is `Evidently`, this specifies the ARN of the Evidently experiment that receives the metrics.
*/
public val destinationArn: kotlin.String? = builder.destinationArn
/**
* This field appears only when the destination is `Evidently`. It specifies the ARN of the IAM role that is used to write to the Evidently experiment that receives the metrics.
*/
public val iamRoleArn: kotlin.String? = builder.iamRoleArn
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.rum.model.MetricDestinationSummary = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("MetricDestinationSummary(")
append("destination=$destination,")
append("destinationArn=$destinationArn,")
append("iamRoleArn=$iamRoleArn")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = destination?.hashCode() ?: 0
result = 31 * result + (destinationArn?.hashCode() ?: 0)
result = 31 * result + (iamRoleArn?.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 MetricDestinationSummary
if (destination != other.destination) return false
if (destinationArn != other.destinationArn) return false
if (iamRoleArn != other.iamRoleArn) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.rum.model.MetricDestinationSummary = Builder(this).apply(block).build()
public class Builder {
/**
* Specifies whether the destination is `CloudWatch` or `Evidently`.
*/
public var destination: aws.sdk.kotlin.services.rum.model.MetricDestination? = null
/**
* If the destination is `Evidently`, this specifies the ARN of the Evidently experiment that receives the metrics.
*/
public var destinationArn: kotlin.String? = null
/**
* This field appears only when the destination is `Evidently`. It specifies the ARN of the IAM role that is used to write to the Evidently experiment that receives the metrics.
*/
public var iamRoleArn: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.rum.model.MetricDestinationSummary) : this() {
this.destination = x.destination
this.destinationArn = x.destinationArn
this.iamRoleArn = x.iamRoleArn
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.rum.model.MetricDestinationSummary = MetricDestinationSummary(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy