commonMain.aws.sdk.kotlin.services.bedrockagent.model.DeleteAgentVersionResponse.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 DeleteAgentVersionResponse private constructor(builder: Builder) {
/**
* The unique identifier of the agent that the version belongs to.
*/
public val agentId: kotlin.String = requireNotNull(builder.agentId) { "A non-null value must be provided for agentId" }
/**
* The status of the agent version.
*/
public val agentStatus: aws.sdk.kotlin.services.bedrockagent.model.AgentStatus = requireNotNull(builder.agentStatus) { "A non-null value must be provided for agentStatus" }
/**
* The version that was deleted.
*/
public val agentVersion: kotlin.String = requireNotNull(builder.agentVersion) { "A non-null value must be provided for agentVersion" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.bedrockagent.model.DeleteAgentVersionResponse = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("DeleteAgentVersionResponse(")
append("agentId=$agentId,")
append("agentStatus=$agentStatus,")
append("agentVersion=$agentVersion")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = agentId.hashCode()
result = 31 * result + (agentStatus.hashCode())
result = 31 * result + (agentVersion.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 DeleteAgentVersionResponse
if (agentId != other.agentId) return false
if (agentStatus != other.agentStatus) return false
if (agentVersion != other.agentVersion) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.bedrockagent.model.DeleteAgentVersionResponse = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The unique identifier of the agent that the version belongs to.
*/
public var agentId: kotlin.String? = null
/**
* The status of the agent version.
*/
public var agentStatus: aws.sdk.kotlin.services.bedrockagent.model.AgentStatus? = null
/**
* The version that was deleted.
*/
public var agentVersion: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.bedrockagent.model.DeleteAgentVersionResponse) : this() {
this.agentId = x.agentId
this.agentStatus = x.agentStatus
this.agentVersion = x.agentVersion
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.bedrockagent.model.DeleteAgentVersionResponse = DeleteAgentVersionResponse(this)
internal fun correctErrors(): Builder {
if (agentId == null) agentId = ""
if (agentStatus == null) agentStatus = AgentStatus.SdkUnknown("no value provided")
if (agentVersion == null) agentVersion = ""
return this
}
}
}