commonMain.aws.sdk.kotlin.services.cleanroomsml.model.MlOutputConfiguration.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cleanroomsml-jvm Show documentation
Show all versions of cleanroomsml-jvm Show documentation
The AWS SDK for Kotlin client for CleanRoomsML
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.cleanroomsml.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Configuration information about how the exported model artifacts are stored.
*/
public class MlOutputConfiguration private constructor(builder: Builder) {
/**
* The Amazon S3 location where exported model artifacts are stored.
*/
public val destination: aws.sdk.kotlin.services.cleanroomsml.model.Destination? = builder.destination
/**
* The Amazon Resource Name (ARN) of the service access role that is used to store the model artifacts.
*/
public val roleArn: kotlin.String = requireNotNull(builder.roleArn) { "A non-null value must be provided for roleArn" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.cleanroomsml.model.MlOutputConfiguration = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("MlOutputConfiguration(")
append("destination=$destination,")
append("roleArn=$roleArn")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = destination?.hashCode() ?: 0
result = 31 * result + (roleArn.hashCode())
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 MlOutputConfiguration
if (destination != other.destination) return false
if (roleArn != other.roleArn) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.cleanroomsml.model.MlOutputConfiguration = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The Amazon S3 location where exported model artifacts are stored.
*/
public var destination: aws.sdk.kotlin.services.cleanroomsml.model.Destination? = null
/**
* The Amazon Resource Name (ARN) of the service access role that is used to store the model artifacts.
*/
public var roleArn: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.cleanroomsml.model.MlOutputConfiguration) : this() {
this.destination = x.destination
this.roleArn = x.roleArn
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.cleanroomsml.model.MlOutputConfiguration = MlOutputConfiguration(this)
/**
* construct an [aws.sdk.kotlin.services.cleanroomsml.model.Destination] inside the given [block]
*/
public fun destination(block: aws.sdk.kotlin.services.cleanroomsml.model.Destination.Builder.() -> kotlin.Unit) {
this.destination = aws.sdk.kotlin.services.cleanroomsml.model.Destination.invoke(block)
}
internal fun correctErrors(): Builder {
if (roleArn == null) roleArn = ""
return this
}
}
}