commonMain.aws.sdk.kotlin.services.appflow.model.EventBridgeDestinationProperties.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of appflow-jvm Show documentation
Show all versions of appflow-jvm Show documentation
The AWS SDK for Kotlin client for Appflow
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.appflow.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* The properties that are applied when Amazon EventBridge is being used as a destination.
*/
public class EventBridgeDestinationProperties private constructor(builder: Builder) {
/**
* The settings that determine how Amazon AppFlow handles an error when placing data in the destination. For example, this setting would determine if the flow should fail after one insertion error, or continue and attempt to insert every record regardless of the initial failure. `ErrorHandlingConfig` is a part of the destination connector details.
*/
public val errorHandlingConfig: aws.sdk.kotlin.services.appflow.model.ErrorHandlingConfig? = builder.errorHandlingConfig
/**
* The object specified in the Amazon EventBridge flow destination.
*/
public val `object`: kotlin.String = requireNotNull(builder.`object`) { "A non-null value must be provided for `object`" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.appflow.model.EventBridgeDestinationProperties = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("EventBridgeDestinationProperties(")
append("errorHandlingConfig=$errorHandlingConfig,")
append("object=$`object`")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = errorHandlingConfig?.hashCode() ?: 0
result = 31 * result + (`object`.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 EventBridgeDestinationProperties
if (errorHandlingConfig != other.errorHandlingConfig) return false
if (`object` != other.`object`) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.appflow.model.EventBridgeDestinationProperties = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The settings that determine how Amazon AppFlow handles an error when placing data in the destination. For example, this setting would determine if the flow should fail after one insertion error, or continue and attempt to insert every record regardless of the initial failure. `ErrorHandlingConfig` is a part of the destination connector details.
*/
public var errorHandlingConfig: aws.sdk.kotlin.services.appflow.model.ErrorHandlingConfig? = null
/**
* The object specified in the Amazon EventBridge flow destination.
*/
public var `object`: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.appflow.model.EventBridgeDestinationProperties) : this() {
this.errorHandlingConfig = x.errorHandlingConfig
this.`object` = x.`object`
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.appflow.model.EventBridgeDestinationProperties = EventBridgeDestinationProperties(this)
/**
* construct an [aws.sdk.kotlin.services.appflow.model.ErrorHandlingConfig] inside the given [block]
*/
public fun errorHandlingConfig(block: aws.sdk.kotlin.services.appflow.model.ErrorHandlingConfig.Builder.() -> kotlin.Unit) {
this.errorHandlingConfig = aws.sdk.kotlin.services.appflow.model.ErrorHandlingConfig.invoke(block)
}
internal fun correctErrors(): Builder {
if (`object` == null) `object` = ""
return this
}
}
}