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

com.pulumi.azurenative.documentdb.kotlin.inputs.RestoreParametersArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 2.82.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.azurenative.documentdb.kotlin.inputs

import com.pulumi.azurenative.documentdb.inputs.RestoreParametersArgs.builder
import com.pulumi.azurenative.documentdb.kotlin.enums.RestoreMode
import com.pulumi.core.Either
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Parameters to indicate the information about the restore.
 * @property databasesToRestore List of specific databases available for restore.
 * @property gremlinDatabasesToRestore List of specific gremlin databases available for restore.
 * @property restoreMode Describes the mode of the restore.
 * @property restoreSource The id of the restorable database account from which the restore has to be initiated. For example: /subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}
 * @property restoreTimestampInUtc Time to which the account has to be restored (ISO-8601 format).
 * @property tablesToRestore List of specific tables available for restore.
 */
public data class RestoreParametersArgs(
    public val databasesToRestore: Output>? = null,
    public val gremlinDatabasesToRestore: Output>? = null,
    public val restoreMode: Output>? = null,
    public val restoreSource: Output? = null,
    public val restoreTimestampInUtc: Output? = null,
    public val tablesToRestore: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.documentdb.inputs.RestoreParametersArgs =
        com.pulumi.azurenative.documentdb.inputs.RestoreParametersArgs.builder()
            .databasesToRestore(
                databasesToRestore?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .gremlinDatabasesToRestore(
                gremlinDatabasesToRestore?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .restoreMode(
                restoreMode?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .restoreSource(restoreSource?.applyValue({ args0 -> args0 }))
            .restoreTimestampInUtc(restoreTimestampInUtc?.applyValue({ args0 -> args0 }))
            .tablesToRestore(tablesToRestore?.applyValue({ args0 -> args0.map({ args0 -> args0 }) })).build()
}

/**
 * Builder for [RestoreParametersArgs].
 */
@PulumiTagMarker
public class RestoreParametersArgsBuilder internal constructor() {
    private var databasesToRestore: Output>? = null

    private var gremlinDatabasesToRestore: Output>? = null

    private var restoreMode: Output>? = null

    private var restoreSource: Output? = null

    private var restoreTimestampInUtc: Output? = null

    private var tablesToRestore: Output>? = null

    /**
     * @param value List of specific databases available for restore.
     */
    @JvmName("lworhxvcrvehetul")
    public suspend fun databasesToRestore(`value`: Output>) {
        this.databasesToRestore = value
    }

    @JvmName("hfmxfbbhahubvpxd")
    public suspend fun databasesToRestore(vararg values: Output) {
        this.databasesToRestore = Output.all(values.asList())
    }

    /**
     * @param values List of specific databases available for restore.
     */
    @JvmName("rdblhdrimkqqxssw")
    public suspend fun databasesToRestore(values: List>) {
        this.databasesToRestore = Output.all(values)
    }

    /**
     * @param value List of specific gremlin databases available for restore.
     */
    @JvmName("sxdxqsyrnorfilqb")
    public suspend fun gremlinDatabasesToRestore(`value`: Output>) {
        this.gremlinDatabasesToRestore = value
    }

    @JvmName("xsjkoxwtrrnxpedg")
    public suspend fun gremlinDatabasesToRestore(vararg values: Output) {
        this.gremlinDatabasesToRestore = Output.all(values.asList())
    }

    /**
     * @param values List of specific gremlin databases available for restore.
     */
    @JvmName("nhkjaliumwognqkp")
    public suspend fun gremlinDatabasesToRestore(values: List>) {
        this.gremlinDatabasesToRestore = Output.all(values)
    }

    /**
     * @param value Describes the mode of the restore.
     */
    @JvmName("ntipglqsimklwuwf")
    public suspend fun restoreMode(`value`: Output>) {
        this.restoreMode = value
    }

    /**
     * @param value The id of the restorable database account from which the restore has to be initiated. For example: /subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}
     */
    @JvmName("kfpoiatthcmqllit")
    public suspend fun restoreSource(`value`: Output) {
        this.restoreSource = value
    }

    /**
     * @param value Time to which the account has to be restored (ISO-8601 format).
     */
    @JvmName("uxluvoixqedxgrci")
    public suspend fun restoreTimestampInUtc(`value`: Output) {
        this.restoreTimestampInUtc = value
    }

    /**
     * @param value List of specific tables available for restore.
     */
    @JvmName("slkgxanqyklxnbjs")
    public suspend fun tablesToRestore(`value`: Output>) {
        this.tablesToRestore = value
    }

    @JvmName("wwcvunkuuqkobtdv")
    public suspend fun tablesToRestore(vararg values: Output) {
        this.tablesToRestore = Output.all(values.asList())
    }

    /**
     * @param values List of specific tables available for restore.
     */
    @JvmName("sfbwapfstlcraxkh")
    public suspend fun tablesToRestore(values: List>) {
        this.tablesToRestore = Output.all(values)
    }

    /**
     * @param value List of specific databases available for restore.
     */
    @JvmName("giyxcpadiqoblnhh")
    public suspend fun databasesToRestore(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.databasesToRestore = mapped
    }

    /**
     * @param argument List of specific databases available for restore.
     */
    @JvmName("ougugmwbjpahwthg")
    public suspend fun databasesToRestore(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            DatabaseRestoreResourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.databasesToRestore = mapped
    }

    /**
     * @param argument List of specific databases available for restore.
     */
    @JvmName("sohdvoiphdfquekh")
    public suspend fun databasesToRestore(vararg argument: suspend DatabaseRestoreResourceArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            DatabaseRestoreResourceArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.databasesToRestore = mapped
    }

    /**
     * @param argument List of specific databases available for restore.
     */
    @JvmName("jrhbudlrexmdvoye")
    public suspend fun databasesToRestore(argument: suspend DatabaseRestoreResourceArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            DatabaseRestoreResourceArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.databasesToRestore = mapped
    }

    /**
     * @param values List of specific databases available for restore.
     */
    @JvmName("umloaqwntnyvqqrj")
    public suspend fun databasesToRestore(vararg values: DatabaseRestoreResourceArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.databasesToRestore = mapped
    }

    /**
     * @param value List of specific gremlin databases available for restore.
     */
    @JvmName("ifwswscdfraxwbbl")
    public suspend fun gremlinDatabasesToRestore(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.gremlinDatabasesToRestore = mapped
    }

    /**
     * @param argument List of specific gremlin databases available for restore.
     */
    @JvmName("dtfwjgwmgxyfcvim")
    public suspend fun gremlinDatabasesToRestore(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            GremlinDatabaseRestoreResourceArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.gremlinDatabasesToRestore = mapped
    }

    /**
     * @param argument List of specific gremlin databases available for restore.
     */
    @JvmName("gawxmwcepixfrqfy")
    public suspend fun gremlinDatabasesToRestore(vararg argument: suspend GremlinDatabaseRestoreResourceArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            GremlinDatabaseRestoreResourceArgsBuilder().applySuspend { it() }.build()
        }
        val mapped = of(toBeMapped)
        this.gremlinDatabasesToRestore = mapped
    }

    /**
     * @param argument List of specific gremlin databases available for restore.
     */
    @JvmName("dxwsjkoaxtwwenhc")
    public suspend fun gremlinDatabasesToRestore(argument: suspend GremlinDatabaseRestoreResourceArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            GremlinDatabaseRestoreResourceArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.gremlinDatabasesToRestore = mapped
    }

    /**
     * @param values List of specific gremlin databases available for restore.
     */
    @JvmName("ajcmawrbxoaudfem")
    public suspend fun gremlinDatabasesToRestore(vararg values: GremlinDatabaseRestoreResourceArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.gremlinDatabasesToRestore = mapped
    }

    /**
     * @param value Describes the mode of the restore.
     */
    @JvmName("tfawjqxjogotcqxf")
    public suspend fun restoreMode(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.restoreMode = mapped
    }

    /**
     * @param value Describes the mode of the restore.
     */
    @JvmName("wdhpddjvafxnqvhf")
    public fun restoreMode(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.restoreMode = mapped
    }

    /**
     * @param value Describes the mode of the restore.
     */
    @JvmName("wfoctfijkljdmnhh")
    public fun restoreMode(`value`: RestoreMode) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.restoreMode = mapped
    }

    /**
     * @param value The id of the restorable database account from which the restore has to be initiated. For example: /subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}
     */
    @JvmName("ybinqynojrtpdfud")
    public suspend fun restoreSource(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.restoreSource = mapped
    }

    /**
     * @param value Time to which the account has to be restored (ISO-8601 format).
     */
    @JvmName("wsbmesxmyentswxw")
    public suspend fun restoreTimestampInUtc(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.restoreTimestampInUtc = mapped
    }

    /**
     * @param value List of specific tables available for restore.
     */
    @JvmName("ereyahdwsgidpuhl")
    public suspend fun tablesToRestore(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tablesToRestore = mapped
    }

    /**
     * @param values List of specific tables available for restore.
     */
    @JvmName("rybtddehiooqorwi")
    public suspend fun tablesToRestore(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tablesToRestore = mapped
    }

    internal fun build(): RestoreParametersArgs = RestoreParametersArgs(
        databasesToRestore = databasesToRestore,
        gremlinDatabasesToRestore = gremlinDatabasesToRestore,
        restoreMode = restoreMode,
        restoreSource = restoreSource,
        restoreTimestampInUtc = restoreTimestampInUtc,
        tablesToRestore = tablesToRestore,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy