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

com.pulumi.azurenative.logic.kotlin.IntegrationAccountPartnerArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.logic.kotlin

import com.pulumi.azurenative.logic.IntegrationAccountPartnerArgs.builder
import com.pulumi.azurenative.logic.kotlin.enums.PartnerType
import com.pulumi.azurenative.logic.kotlin.inputs.PartnerContentArgs
import com.pulumi.azurenative.logic.kotlin.inputs.PartnerContentArgsBuilder
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.Any
import kotlin.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.Map
import kotlin.jvm.JvmName

/**
 * The integration account partner.
 * Azure REST API version: 2019-05-01. Prior API version in Azure Native 1.x: 2019-05-01.
 * Other available API versions: 2015-08-01-preview.
 * ## Example Usage
 * ### Create or update a partner
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AzureNative = Pulumi.AzureNative;
 * return await Deployment.RunAsync(() =>
 * {
 *     var integrationAccountPartner = new AzureNative.Logic.IntegrationAccountPartner("integrationAccountPartner", new()
 *     {
 *         Content = new AzureNative.Logic.Inputs.PartnerContentArgs
 *         {
 *             B2b = new AzureNative.Logic.Inputs.B2BPartnerContentArgs
 *             {
 *                 BusinessIdentities = new[]
 *                 {
 *                     new AzureNative.Logic.Inputs.BusinessIdentityArgs
 *                     {
 *                         Qualifier = "AA",
 *                         Value = "ZZ",
 *                     },
 *                 },
 *             },
 *         },
 *         IntegrationAccountName = "testIntegrationAccount",
 *         Location = "westus",
 *         Metadata = null,
 *         PartnerName = "testPartner",
 *         PartnerType = AzureNative.Logic.PartnerType.B2B,
 *         ResourceGroupName = "testResourceGroup",
 *         Tags = null,
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	logic "github.com/pulumi/pulumi-azure-native-sdk/logic/v2"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := logic.NewIntegrationAccountPartner(ctx, "integrationAccountPartner", &logic.IntegrationAccountPartnerArgs{
 * 			Content: &logic.PartnerContentArgs{
 * 				B2b: &logic.B2BPartnerContentArgs{
 * 					BusinessIdentities: logic.BusinessIdentityArray{
 * 						&logic.BusinessIdentityArgs{
 * 							Qualifier: pulumi.String("AA"),
 * 							Value:     pulumi.String("ZZ"),
 * 						},
 * 					},
 * 				},
 * 			},
 * 			IntegrationAccountName: pulumi.String("testIntegrationAccount"),
 * 			Location:               pulumi.String("westus"),
 * 			Metadata:               pulumi.Any(nil),
 * 			PartnerName:            pulumi.String("testPartner"),
 * 			PartnerType:            pulumi.String(logic.PartnerTypeB2B),
 * 			ResourceGroupName:      pulumi.String("testResourceGroup"),
 * 			Tags:                   nil,
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.azurenative.logic.IntegrationAccountPartner;
 * import com.pulumi.azurenative.logic.IntegrationAccountPartnerArgs;
 * import com.pulumi.azurenative.logic.inputs.PartnerContentArgs;
 * import com.pulumi.azurenative.logic.inputs.B2BPartnerContentArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 *     public static void stack(Context ctx) {
 *         var integrationAccountPartner = new IntegrationAccountPartner("integrationAccountPartner", IntegrationAccountPartnerArgs.builder()
 *             .content(PartnerContentArgs.builder()
 *                 .b2b(B2BPartnerContentArgs.builder()
 *                     .businessIdentities(BusinessIdentityArgs.builder()
 *                         .qualifier("AA")
 *                         .value("ZZ")
 *                         .build())
 *                     .build())
 *                 .build())
 *             .integrationAccountName("testIntegrationAccount")
 *             .location("westus")
 *             .metadata()
 *             .partnerName("testPartner")
 *             .partnerType("B2B")
 *             .resourceGroupName("testResourceGroup")
 *             .tags()
 *             .build());
 *     }
 * }
 * ```
 * ## Import
 * An existing resource can be imported using its type token, name, and identifier, e.g.
 * ```sh
 * $ pulumi import azure-native:logic:IntegrationAccountPartner testPartner /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners/{partnerName}
 * ```
 * @property content The partner content.
 * @property integrationAccountName The integration account name.
 * @property location The resource location.
 * @property metadata The metadata.
 * @property partnerName The integration account partner name.
 * @property partnerType The partner type.
 * @property resourceGroupName The resource group name.
 * @property tags The resource tags.
 */
public data class IntegrationAccountPartnerArgs(
    public val content: Output? = null,
    public val integrationAccountName: Output? = null,
    public val location: Output? = null,
    public val metadata: Output? = null,
    public val partnerName: Output? = null,
    public val partnerType: Output>? = null,
    public val resourceGroupName: Output? = null,
    public val tags: Output>? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.logic.IntegrationAccountPartnerArgs =
        com.pulumi.azurenative.logic.IntegrationAccountPartnerArgs.builder()
            .content(content?.applyValue({ args0 -> args0.let({ args0 -> args0.toJava() }) }))
            .integrationAccountName(integrationAccountName?.applyValue({ args0 -> args0 }))
            .location(location?.applyValue({ args0 -> args0 }))
            .metadata(metadata?.applyValue({ args0 -> args0 }))
            .partnerName(partnerName?.applyValue({ args0 -> args0 }))
            .partnerType(
                partnerType?.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .resourceGroupName(resourceGroupName?.applyValue({ args0 -> args0 }))
            .tags(
                tags?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.key.to(args0.value)
                    }).toMap()
                }),
            ).build()
}

/**
 * Builder for [IntegrationAccountPartnerArgs].
 */
@PulumiTagMarker
public class IntegrationAccountPartnerArgsBuilder internal constructor() {
    private var content: Output? = null

    private var integrationAccountName: Output? = null

    private var location: Output? = null

    private var metadata: Output? = null

    private var partnerName: Output? = null

    private var partnerType: Output>? = null

    private var resourceGroupName: Output? = null

    private var tags: Output>? = null

    /**
     * @param value The partner content.
     */
    @JvmName("ckppyljeecsjicmx")
    public suspend fun content(`value`: Output) {
        this.content = value
    }

    /**
     * @param value The integration account name.
     */
    @JvmName("ebbqvvgatqadngje")
    public suspend fun integrationAccountName(`value`: Output) {
        this.integrationAccountName = value
    }

    /**
     * @param value The resource location.
     */
    @JvmName("qkuqgvhyqtuggefr")
    public suspend fun location(`value`: Output) {
        this.location = value
    }

    /**
     * @param value The metadata.
     */
    @JvmName("dbmbtkvbqtijysfs")
    public suspend fun metadata(`value`: Output) {
        this.metadata = value
    }

    /**
     * @param value The integration account partner name.
     */
    @JvmName("aqtdytbfkmyhggpj")
    public suspend fun partnerName(`value`: Output) {
        this.partnerName = value
    }

    /**
     * @param value The partner type.
     */
    @JvmName("dbarktnpwxkrbcft")
    public suspend fun partnerType(`value`: Output>) {
        this.partnerType = value
    }

    /**
     * @param value The resource group name.
     */
    @JvmName("gvtfygieftqrlgkx")
    public suspend fun resourceGroupName(`value`: Output) {
        this.resourceGroupName = value
    }

    /**
     * @param value The resource tags.
     */
    @JvmName("gmndhxvefnnrmrlb")
    public suspend fun tags(`value`: Output>) {
        this.tags = value
    }

    /**
     * @param value The partner content.
     */
    @JvmName("jpahijqrgyleksui")
    public suspend fun content(`value`: PartnerContentArgs?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.content = mapped
    }

    /**
     * @param argument The partner content.
     */
    @JvmName("mjxqeesoptxkcoot")
    public suspend fun content(argument: suspend PartnerContentArgsBuilder.() -> Unit) {
        val toBeMapped = PartnerContentArgsBuilder().applySuspend { argument() }.build()
        val mapped = of(toBeMapped)
        this.content = mapped
    }

    /**
     * @param value The integration account name.
     */
    @JvmName("igwptmxjudhbkxco")
    public suspend fun integrationAccountName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.integrationAccountName = mapped
    }

    /**
     * @param value The resource location.
     */
    @JvmName("ajpvmdmcvclshyqt")
    public suspend fun location(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.location = mapped
    }

    /**
     * @param value The metadata.
     */
    @JvmName("ijogcfdgxadrphbi")
    public suspend fun metadata(`value`: Any?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.metadata = mapped
    }

    /**
     * @param value The integration account partner name.
     */
    @JvmName("yiqhubyqwtpmrlnv")
    public suspend fun partnerName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.partnerName = mapped
    }

    /**
     * @param value The partner type.
     */
    @JvmName("cdqtwrdmjjmjdhox")
    public suspend fun partnerType(`value`: Either?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.partnerType = mapped
    }

    /**
     * @param value The partner type.
     */
    @JvmName("ptcbdkgikuwtrcqy")
    public fun partnerType(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.partnerType = mapped
    }

    /**
     * @param value The partner type.
     */
    @JvmName("xnpxxbmmaimabufh")
    public fun partnerType(`value`: PartnerType) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.partnerType = mapped
    }

    /**
     * @param value The resource group name.
     */
    @JvmName("cbygtpsngjferfqs")
    public suspend fun resourceGroupName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.resourceGroupName = mapped
    }

    /**
     * @param value The resource tags.
     */
    @JvmName("rfewudtwjvwnufnk")
    public suspend fun tags(`value`: Map?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    /**
     * @param values The resource tags.
     */
    @JvmName("ebhicmfsvcwwhtsr")
    public fun tags(vararg values: Pair) {
        val toBeMapped = values.toMap()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.tags = mapped
    }

    internal fun build(): IntegrationAccountPartnerArgs = IntegrationAccountPartnerArgs(
        content = content,
        integrationAccountName = integrationAccountName,
        location = location,
        metadata = metadata,
        partnerName = partnerName,
        partnerType = partnerType,
        resourceGroupName = resourceGroupName,
        tags = tags,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy