
commonMain.aws.sdk.kotlin.services.opensearch.model.AwsDomainInformation.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.opensearch.model
/**
* Information about an Amazon OpenSearch Service domain.
*/
public class AwsDomainInformation private constructor(builder: Builder) {
/**
* Name of the domain.
*/
public val domainName: kotlin.String = requireNotNull(builder.domainName) { "A non-null value must be provided for domainName" }
/**
* The Amazon Web Services account ID of the domain owner.
*/
public val ownerId: kotlin.String? = builder.ownerId
/**
* The Amazon Web Services Region in which the domain is located.
*/
public val region: kotlin.String? = builder.region
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.opensearch.model.AwsDomainInformation = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("AwsDomainInformation(")
append("domainName=$domainName,")
append("ownerId=$ownerId,")
append("region=$region")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = domainName.hashCode()
result = 31 * result + (ownerId?.hashCode() ?: 0)
result = 31 * result + (region?.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 AwsDomainInformation
if (domainName != other.domainName) return false
if (ownerId != other.ownerId) return false
if (region != other.region) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.opensearch.model.AwsDomainInformation = Builder(this).apply(block).build()
public class Builder {
/**
* Name of the domain.
*/
public var domainName: kotlin.String? = null
/**
* The Amazon Web Services account ID of the domain owner.
*/
public var ownerId: kotlin.String? = null
/**
* The Amazon Web Services Region in which the domain is located.
*/
public var region: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.opensearch.model.AwsDomainInformation) : this() {
this.domainName = x.domainName
this.ownerId = x.ownerId
this.region = x.region
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.opensearch.model.AwsDomainInformation = AwsDomainInformation(this)
internal fun correctErrors(): Builder {
if (domainName == null) domainName = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy