commonMain.aws.sdk.kotlin.services.bedrockagent.model.CreateDataSourceResponse.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of bedrockagent-jvm Show documentation
Show all versions of bedrockagent-jvm Show documentation
The AWS SDK for Kotlin client for Bedrock Agent
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.bedrockagent.model
import aws.smithy.kotlin.runtime.SdkDsl
public class CreateDataSourceResponse private constructor(builder: Builder) {
/**
* Contains details about the data source.
*/
public val dataSource: aws.sdk.kotlin.services.bedrockagent.model.DataSource? = builder.dataSource
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.bedrockagent.model.CreateDataSourceResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("CreateDataSourceResponse(")
append("dataSource=$dataSource")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = dataSource?.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 CreateDataSourceResponse
if (dataSource != other.dataSource) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.bedrockagent.model.CreateDataSourceResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Contains details about the data source.
*/
public var dataSource: aws.sdk.kotlin.services.bedrockagent.model.DataSource? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.bedrockagent.model.CreateDataSourceResponse) : this() {
this.dataSource = x.dataSource
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.bedrockagent.model.CreateDataSourceResponse = CreateDataSourceResponse(this)
/**
* construct an [aws.sdk.kotlin.services.bedrockagent.model.DataSource] inside the given [block]
*/
public fun dataSource(block: aws.sdk.kotlin.services.bedrockagent.model.DataSource.Builder.() -> kotlin.Unit) {
this.dataSource = aws.sdk.kotlin.services.bedrockagent.model.DataSource.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}