commonMain.aws.sdk.kotlin.services.redshiftserverless.model.Endpoint.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of redshiftserverless-jvm Show documentation
Show all versions of redshiftserverless-jvm Show documentation
The AWS SDK for Kotlin client for Redshift Serverless
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.redshiftserverless.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* The VPC endpoint object.
*/
public class Endpoint private constructor(builder: Builder) {
/**
* The DNS address of the VPC endpoint.
*/
public val address: kotlin.String? = builder.address
/**
* The port that Amazon Redshift Serverless listens on.
*/
public val port: kotlin.Int? = builder.port
/**
* An array of `VpcEndpoint` objects.
*/
public val vpcEndpoints: List? = builder.vpcEndpoints
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.redshiftserverless.model.Endpoint = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("Endpoint(")
append("address=$address,")
append("port=$port,")
append("vpcEndpoints=$vpcEndpoints")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = address?.hashCode() ?: 0
result = 31 * result + (port ?: 0)
result = 31 * result + (vpcEndpoints?.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 Endpoint
if (address != other.address) return false
if (port != other.port) return false
if (vpcEndpoints != other.vpcEndpoints) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.redshiftserverless.model.Endpoint = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The DNS address of the VPC endpoint.
*/
public var address: kotlin.String? = null
/**
* The port that Amazon Redshift Serverless listens on.
*/
public var port: kotlin.Int? = null
/**
* An array of `VpcEndpoint` objects.
*/
public var vpcEndpoints: List? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.redshiftserverless.model.Endpoint) : this() {
this.address = x.address
this.port = x.port
this.vpcEndpoints = x.vpcEndpoints
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.redshiftserverless.model.Endpoint = Endpoint(this)
internal fun correctErrors(): Builder {
return this
}
}
}