commonMain.aws.sdk.kotlin.services.computeoptimizer.model.S3Destination.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of computeoptimizer-jvm Show documentation
Show all versions of computeoptimizer-jvm Show documentation
The AWS SDK for Kotlin client for Compute Optimizer
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.computeoptimizer.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Describes the destination Amazon Simple Storage Service (Amazon S3) bucket name and object keys of a recommendations export file, and its associated metadata file.
*/
public class S3Destination private constructor(builder: Builder) {
/**
* The name of the Amazon S3 bucket used as the destination of an export file.
*/
public val bucket: kotlin.String? = builder.bucket
/**
* The Amazon S3 bucket key of an export file.
*
* The key uniquely identifies the object, or export file, in the S3 bucket.
*/
public val key: kotlin.String? = builder.key
/**
* The Amazon S3 bucket key of a metadata file.
*
* The key uniquely identifies the object, or metadata file, in the S3 bucket.
*/
public val metadataKey: kotlin.String? = builder.metadataKey
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.computeoptimizer.model.S3Destination = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("S3Destination(")
append("bucket=$bucket,")
append("key=$key,")
append("metadataKey=$metadataKey")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = bucket?.hashCode() ?: 0
result = 31 * result + (key?.hashCode() ?: 0)
result = 31 * result + (metadataKey?.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 S3Destination
if (bucket != other.bucket) return false
if (key != other.key) return false
if (metadataKey != other.metadataKey) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.computeoptimizer.model.S3Destination = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The name of the Amazon S3 bucket used as the destination of an export file.
*/
public var bucket: kotlin.String? = null
/**
* The Amazon S3 bucket key of an export file.
*
* The key uniquely identifies the object, or export file, in the S3 bucket.
*/
public var key: kotlin.String? = null
/**
* The Amazon S3 bucket key of a metadata file.
*
* The key uniquely identifies the object, or metadata file, in the S3 bucket.
*/
public var metadataKey: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.computeoptimizer.model.S3Destination) : this() {
this.bucket = x.bucket
this.key = x.key
this.metadataKey = x.metadataKey
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.computeoptimizer.model.S3Destination = S3Destination(this)
internal fun correctErrors(): Builder {
return this
}
}
}