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

com.pulumi.azurenative.dbforpostgresql.kotlin.inputs.MigrationSecretParametersArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.dbforpostgresql.kotlin.inputs

import com.pulumi.azurenative.dbforpostgresql.inputs.MigrationSecretParametersArgs.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

/**
 * Migration secret parameters.
 * @property adminCredentials Admin credentials for source and target servers
 * @property sourceServerUsername Gets or sets the username for the source server. This user need not be an admin.
 * @property targetServerUsername Gets or sets the username for the target server. This user need not be an admin.
 */
public data class MigrationSecretParametersArgs(
    public val adminCredentials: Output,
    public val sourceServerUsername: Output? = null,
    public val targetServerUsername: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.dbforpostgresql.inputs.MigrationSecretParametersArgs = com.pulumi.azurenative.dbforpostgresql.inputs.MigrationSecretParametersArgs.builder()
        .adminCredentials(adminCredentials.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
        .sourceServerUsername(sourceServerUsername?.applyValue({ args0 -> args0 }))
        .targetServerUsername(targetServerUsername?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [MigrationSecretParametersArgs].
 */
@PulumiTagMarker
public class MigrationSecretParametersArgsBuilder internal constructor() {
    private var adminCredentials: Output? = null

    private var sourceServerUsername: Output? = null

    private var targetServerUsername: Output? = null

    /**
     * @param value Admin credentials for source and target servers
     */
    @JvmName("tfvogfeqsdyytuwh")
    public suspend fun adminCredentials(`value`: Output) {
        this.adminCredentials = value
    }

    /**
     * @param value Gets or sets the username for the source server. This user need not be an admin.
     */
    @JvmName("ldjsccdcbirbqgmx")
    public suspend fun sourceServerUsername(`value`: Output) {
        this.sourceServerUsername = value
    }

    /**
     * @param value Gets or sets the username for the target server. This user need not be an admin.
     */
    @JvmName("jrsydtlovqatvyen")
    public suspend fun targetServerUsername(`value`: Output) {
        this.targetServerUsername = value
    }

    /**
     * @param value Admin credentials for source and target servers
     */
    @JvmName("qqfrfrhqxbvrnldd")
    public suspend fun adminCredentials(`value`: AdminCredentialsArgs) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.adminCredentials = mapped
    }

    /**
     * @param argument Admin credentials for source and target servers
     */
    @JvmName("djybepepyrqjqugn")
    public suspend fun adminCredentials(argument: suspend AdminCredentialsArgsBuilder.() -> Unit) {
        val toBeMapped = AdminCredentialsArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.adminCredentials = mapped
    }

    /**
     * @param value Gets or sets the username for the source server. This user need not be an admin.
     */
    @JvmName("iihuqwomfiwulchi")
    public suspend fun sourceServerUsername(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.sourceServerUsername = mapped
    }

    /**
     * @param value Gets or sets the username for the target server. This user need not be an admin.
     */
    @JvmName("evpmrbumuufrinqo")
    public suspend fun targetServerUsername(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.targetServerUsername = mapped
    }

    internal fun build(): MigrationSecretParametersArgs = MigrationSecretParametersArgs(
        adminCredentials = adminCredentials ?: throw PulumiNullFieldException("adminCredentials"),
        sourceServerUsername = sourceServerUsername,
        targetServerUsername = targetServerUsername,
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy