commonMain.aws.sdk.kotlin.services.bedrockagent.model.StartIngestionJobRequest.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 StartIngestionJobRequest private constructor(builder: Builder) {
/**
* A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see [Ensuring idempotency](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
*/
public val clientToken: kotlin.String? = builder.clientToken
/**
* The unique identifier of the data source to ingest.
*/
public val dataSourceId: kotlin.String? = builder.dataSourceId
/**
* A description of the ingestion job.
*/
public val description: kotlin.String? = builder.description
/**
* The unique identifier of the knowledge base to which to add the data source.
*/
public val knowledgeBaseId: kotlin.String? = builder.knowledgeBaseId
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.bedrockagent.model.StartIngestionJobRequest = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("StartIngestionJobRequest(")
append("clientToken=$clientToken,")
append("dataSourceId=$dataSourceId,")
append("description=$description,")
append("knowledgeBaseId=$knowledgeBaseId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = clientToken?.hashCode() ?: 0
result = 31 * result + (dataSourceId?.hashCode() ?: 0)
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (knowledgeBaseId?.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 StartIngestionJobRequest
if (clientToken != other.clientToken) return false
if (dataSourceId != other.dataSourceId) return false
if (description != other.description) return false
if (knowledgeBaseId != other.knowledgeBaseId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.bedrockagent.model.StartIngestionJobRequest = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, Amazon Bedrock ignores the request, but does not return an error. For more information, see [Ensuring idempotency](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html).
*/
public var clientToken: kotlin.String? = null
/**
* The unique identifier of the data source to ingest.
*/
public var dataSourceId: kotlin.String? = null
/**
* A description of the ingestion job.
*/
public var description: kotlin.String? = null
/**
* The unique identifier of the knowledge base to which to add the data source.
*/
public var knowledgeBaseId: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.bedrockagent.model.StartIngestionJobRequest) : this() {
this.clientToken = x.clientToken
this.dataSourceId = x.dataSourceId
this.description = x.description
this.knowledgeBaseId = x.knowledgeBaseId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.bedrockagent.model.StartIngestionJobRequest = StartIngestionJobRequest(this)
internal fun correctErrors(): Builder {
return this
}
}
}