All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.awsnative.appsync.kotlin.inputs.FunctionConfigurationSyncConfigArgs.kt Maven / Gradle / Ivy

@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.appsync.kotlin.inputs

import com.pulumi.awsnative.appsync.inputs.FunctionConfigurationSyncConfigArgs.builder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.jvm.JvmName

/**
 * Describes a Sync configuration for a resolver. Specifies which Conflict Detection strategy and Resolution strategy to use when the resolver is invoked.
 * @property conflictDetection The Conflict Detection strategy to use.
 * @property conflictHandler The Conflict Resolution strategy to perform in the event of a conflict.
 * @property lambdaConflictHandlerConfig The `LambdaConflictHandlerConfig` when configuring `LAMBDA` as the Conflict Handler.
 */
public data class FunctionConfigurationSyncConfigArgs(
    public val conflictDetection: Output,
    public val conflictHandler: Output? = null,
    public val lambdaConflictHandlerConfig: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.awsnative.appsync.inputs.FunctionConfigurationSyncConfigArgs =
        com.pulumi.awsnative.appsync.inputs.FunctionConfigurationSyncConfigArgs.builder()
            .conflictDetection(conflictDetection.applyValue({ args0 -> args0 }))
            .conflictHandler(conflictHandler?.applyValue({ args0 -> args0 }))
            .lambdaConflictHandlerConfig(
                lambdaConflictHandlerConfig?.applyValue({ args0 ->
                    args0.let({ args0 ->
                        args0.toJava()
                    })
                }),
            ).build()
}

/**
 * Builder for [FunctionConfigurationSyncConfigArgs].
 */
@PulumiTagMarker
public class FunctionConfigurationSyncConfigArgsBuilder internal constructor() {
    private var conflictDetection: Output? = null

    private var conflictHandler: Output? = null

    private var lambdaConflictHandlerConfig:
        Output? = null

    /**
     * @param value The Conflict Detection strategy to use.
     */
    @JvmName("qdipdvixibkhcflx")
    public suspend fun conflictDetection(`value`: Output) {
        this.conflictDetection = value
    }

    /**
     * @param value The Conflict Resolution strategy to perform in the event of a conflict.
     */
    @JvmName("xaysbfubxrmbbxwi")
    public suspend fun conflictHandler(`value`: Output) {
        this.conflictHandler = value
    }

    /**
     * @param value The `LambdaConflictHandlerConfig` when configuring `LAMBDA` as the Conflict Handler.
     */
    @JvmName("smydjnkxxtknudgq")
    public suspend fun lambdaConflictHandlerConfig(`value`: Output) {
        this.lambdaConflictHandlerConfig = value
    }

    /**
     * @param value The Conflict Detection strategy to use.
     */
    @JvmName("dbfidbnhaychtpfi")
    public suspend fun conflictDetection(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.conflictDetection = mapped
    }

    /**
     * @param value The Conflict Resolution strategy to perform in the event of a conflict.
     */
    @JvmName("bonthrrpppcrjasg")
    public suspend fun conflictHandler(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.conflictHandler = mapped
    }

    /**
     * @param value The `LambdaConflictHandlerConfig` when configuring `LAMBDA` as the Conflict Handler.
     */
    @JvmName("ysqknkpfvvslxsig")
    public suspend fun lambdaConflictHandlerConfig(`value`: FunctionConfigurationLambdaConflictHandlerConfigArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.lambdaConflictHandlerConfig = mapped
    }

    /**
     * @param argument The `LambdaConflictHandlerConfig` when configuring `LAMBDA` as the Conflict Handler.
     */
    @JvmName("khlpbaupvaobesng")
    public suspend fun lambdaConflictHandlerConfig(argument: suspend FunctionConfigurationLambdaConflictHandlerConfigArgsBuilder.() -> Unit) {
        val toBeMapped = FunctionConfigurationLambdaConflictHandlerConfigArgsBuilder().applySuspend {
            argument()
        }.build()
        val mapped = of(toBeMapped)
        this.lambdaConflictHandlerConfig = mapped
    }

    internal fun build(): FunctionConfigurationSyncConfigArgs = FunctionConfigurationSyncConfigArgs(
        conflictDetection = conflictDetection ?: throw PulumiNullFieldException("conflictDetection"),
        conflictHandler = conflictHandler,
        lambdaConflictHandlerConfig = lambdaConflictHandlerConfig,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy