commonMain.aws.sdk.kotlin.services.route53.model.HealthCheckObservation.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of route53-jvm Show documentation
Show all versions of route53-jvm Show documentation
The AWS SDK for Kotlin client for Route 53
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.route53.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker.
*/
public class HealthCheckObservation private constructor(builder: Builder) {
/**
* The IP address of the Amazon Route 53 health checker that provided the failure reason in `StatusReport`.
*/
public val ipAddress: kotlin.String? = builder.ipAddress
/**
* The region of the Amazon Route 53 health checker that provided the status in `StatusReport`.
*/
public val region: aws.sdk.kotlin.services.route53.model.HealthCheckRegion? = builder.region
/**
* A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.
*/
public val statusReport: aws.sdk.kotlin.services.route53.model.StatusReport? = builder.statusReport
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.route53.model.HealthCheckObservation = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("HealthCheckObservation(")
append("ipAddress=$ipAddress,")
append("region=$region,")
append("statusReport=$statusReport")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = ipAddress?.hashCode() ?: 0
result = 31 * result + (region?.hashCode() ?: 0)
result = 31 * result + (statusReport?.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 HealthCheckObservation
if (ipAddress != other.ipAddress) return false
if (region != other.region) return false
if (statusReport != other.statusReport) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.route53.model.HealthCheckObservation = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The IP address of the Amazon Route 53 health checker that provided the failure reason in `StatusReport`.
*/
public var ipAddress: kotlin.String? = null
/**
* The region of the Amazon Route 53 health checker that provided the status in `StatusReport`.
*/
public var region: aws.sdk.kotlin.services.route53.model.HealthCheckRegion? = null
/**
* A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.
*/
public var statusReport: aws.sdk.kotlin.services.route53.model.StatusReport? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.route53.model.HealthCheckObservation) : this() {
this.ipAddress = x.ipAddress
this.region = x.region
this.statusReport = x.statusReport
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.route53.model.HealthCheckObservation = HealthCheckObservation(this)
/**
* construct an [aws.sdk.kotlin.services.route53.model.StatusReport] inside the given [block]
*/
public fun statusReport(block: aws.sdk.kotlin.services.route53.model.StatusReport.Builder.() -> kotlin.Unit) {
this.statusReport = aws.sdk.kotlin.services.route53.model.StatusReport.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}