Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.pulumi.azure.mobile.kotlin.NetworkSliceArgs.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.azure.mobile.kotlin
import com.pulumi.azure.mobile.NetworkSliceArgs.builder
import com.pulumi.azure.mobile.kotlin.inputs.NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs
import com.pulumi.azure.mobile.kotlin.inputs.NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgsBuilder
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.Pair
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.Map
import kotlin.jvm.JvmName
/**
* Manages a Mobile Network Slice.
* ## Example Usage
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as azure from "@pulumi/azure";
* const example = new azure.core.ResourceGroup("example", {
* name: "example-resources",
* location: "West Europe",
* });
* const exampleNetwork = new azure.mobile.Network("example", {
* name: "example-mn",
* location: example.location,
* resourceGroupName: example.name,
* mobileCountryCode: "001",
* mobileNetworkCode: "01",
* });
* const exampleNetworkSlice = new azure.mobile.NetworkSlice("example", {
* name: "example-mns",
* mobileNetworkId: exampleNetwork.id,
* location: example.location,
* description: "an example slice",
* singleNetworkSliceSelectionAssistanceInformation: {
* sliceServiceType: 1,
* },
* tags: {
* key: "value",
* },
* });
* ```
* ```python
* import pulumi
* import pulumi_azure as azure
* example = azure.core.ResourceGroup("example",
* name="example-resources",
* location="West Europe")
* example_network = azure.mobile.Network("example",
* name="example-mn",
* location=example.location,
* resource_group_name=example.name,
* mobile_country_code="001",
* mobile_network_code="01")
* example_network_slice = azure.mobile.NetworkSlice("example",
* name="example-mns",
* mobile_network_id=example_network.id,
* location=example.location,
* description="an example slice",
* single_network_slice_selection_assistance_information={
* "slice_service_type": 1,
* },
* tags={
* "key": "value",
* })
* ```
* ```csharp
* using System.Collections.Generic;
* using System.Linq;
* using Pulumi;
* using Azure = Pulumi.Azure;
* return await Deployment.RunAsync(() =>
* {
* var example = new Azure.Core.ResourceGroup("example", new()
* {
* Name = "example-resources",
* Location = "West Europe",
* });
* var exampleNetwork = new Azure.Mobile.Network("example", new()
* {
* Name = "example-mn",
* Location = example.Location,
* ResourceGroupName = example.Name,
* MobileCountryCode = "001",
* MobileNetworkCode = "01",
* });
* var exampleNetworkSlice = new Azure.Mobile.NetworkSlice("example", new()
* {
* Name = "example-mns",
* MobileNetworkId = exampleNetwork.Id,
* Location = example.Location,
* Description = "an example slice",
* SingleNetworkSliceSelectionAssistanceInformation = new Azure.Mobile.Inputs.NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs
* {
* SliceServiceType = 1,
* },
* Tags =
* {
* { "key", "value" },
* },
* });
* });
* ```
* ```go
* package main
* import (
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
* "github.com/pulumi/pulumi-azure/sdk/v5/go/azure/mobile"
* "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
* )
* func main() {
* pulumi.Run(func(ctx *pulumi.Context) error {
* example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
* Name: pulumi.String("example-resources"),
* Location: pulumi.String("West Europe"),
* })
* if err != nil {
* return err
* }
* exampleNetwork, err := mobile.NewNetwork(ctx, "example", &mobile.NetworkArgs{
* Name: pulumi.String("example-mn"),
* Location: example.Location,
* ResourceGroupName: example.Name,
* MobileCountryCode: pulumi.String("001"),
* MobileNetworkCode: pulumi.String("01"),
* })
* if err != nil {
* return err
* }
* _, err = mobile.NewNetworkSlice(ctx, "example", &mobile.NetworkSliceArgs{
* Name: pulumi.String("example-mns"),
* MobileNetworkId: exampleNetwork.ID(),
* Location: example.Location,
* Description: pulumi.String("an example slice"),
* SingleNetworkSliceSelectionAssistanceInformation: &mobile.NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs{
* SliceServiceType: pulumi.Int(1),
* },
* Tags: pulumi.StringMap{
* "key": pulumi.String("value"),
* },
* })
* 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.azure.core.ResourceGroup;
* import com.pulumi.azure.core.ResourceGroupArgs;
* import com.pulumi.azure.mobile.Network;
* import com.pulumi.azure.mobile.NetworkArgs;
* import com.pulumi.azure.mobile.NetworkSlice;
* import com.pulumi.azure.mobile.NetworkSliceArgs;
* import com.pulumi.azure.mobile.inputs.NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs;
* 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 example = new ResourceGroup("example", ResourceGroupArgs.builder()
* .name("example-resources")
* .location("West Europe")
* .build());
* var exampleNetwork = new Network("exampleNetwork", NetworkArgs.builder()
* .name("example-mn")
* .location(example.location())
* .resourceGroupName(example.name())
* .mobileCountryCode("001")
* .mobileNetworkCode("01")
* .build());
* var exampleNetworkSlice = new NetworkSlice("exampleNetworkSlice", NetworkSliceArgs.builder()
* .name("example-mns")
* .mobileNetworkId(exampleNetwork.id())
* .location(example.location())
* .description("an example slice")
* .singleNetworkSliceSelectionAssistanceInformation(NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs.builder()
* .sliceServiceType(1)
* .build())
* .tags(Map.of("key", "value"))
* .build());
* }
* }
* ```
* ```yaml
* resources:
* example:
* type: azure:core:ResourceGroup
* properties:
* name: example-resources
* location: West Europe
* exampleNetwork:
* type: azure:mobile:Network
* name: example
* properties:
* name: example-mn
* location: ${example.location}
* resourceGroupName: ${example.name}
* mobileCountryCode: '001'
* mobileNetworkCode: '01'
* exampleNetworkSlice:
* type: azure:mobile:NetworkSlice
* name: example
* properties:
* name: example-mns
* mobileNetworkId: ${exampleNetwork.id}
* location: ${example.location}
* description: an example slice
* singleNetworkSliceSelectionAssistanceInformation:
* sliceServiceType: 1
* tags:
* key: value
* ```
*
* ## Import
* Mobile Network Slice can be imported using the `resource id`, e.g.
* ```sh
* $ pulumi import azure:mobile/networkSlice:NetworkSlice example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/resourceGroup1/providers/Microsoft.MobileNetwork/mobileNetworks/mobileNetwork1/slices/slice1
* ```
* @property description A description for this Mobile Network Slice.
* @property location Specifies the Azure Region where the Mobile Network Slice should exist. Changing this forces a new Mobile Network Slice to be created.
* @property mobileNetworkId The ID of Mobile Network which the Mobile Network Slice belongs to. Changing this forces a new Mobile Network Slice to be created.
* @property name Specifies the name which should be used for this Mobile Network Slice. Changing this forces a new Mobile Network Slice to be created.
* @property singleNetworkSliceSelectionAssistanceInformation A `single_network_slice_selection_assistance_information` block as defined below. Single-network slice selection assistance information (S-NSSAI). Unique at the scope of a mobile network.
* @property tags A mapping of tags which should be assigned to the Mobile Network Slice.
*/
public data class NetworkSliceArgs(
public val description: Output? = null,
public val location: Output? = null,
public val mobileNetworkId: Output? = null,
public val name: Output? = null,
public val singleNetworkSliceSelectionAssistanceInformation: Output? = null,
public val tags: Output>? = null,
) : ConvertibleToJava {
override fun toJava(): com.pulumi.azure.mobile.NetworkSliceArgs =
com.pulumi.azure.mobile.NetworkSliceArgs.builder()
.description(description?.applyValue({ args0 -> args0 }))
.location(location?.applyValue({ args0 -> args0 }))
.mobileNetworkId(mobileNetworkId?.applyValue({ args0 -> args0 }))
.name(name?.applyValue({ args0 -> args0 }))
.singleNetworkSliceSelectionAssistanceInformation(
singleNetworkSliceSelectionAssistanceInformation?.applyValue({ args0 ->
args0.let({ args0 -> args0.toJava() })
}),
)
.tags(
tags?.applyValue({ args0 ->
args0.map({ args0 ->
args0.key.to(args0.value)
}).toMap()
}),
).build()
}
/**
* Builder for [NetworkSliceArgs].
*/
@PulumiTagMarker
public class NetworkSliceArgsBuilder internal constructor() {
private var description: Output? = null
private var location: Output? = null
private var mobileNetworkId: Output? = null
private var name: Output? = null
private var singleNetworkSliceSelectionAssistanceInformation:
Output? = null
private var tags: Output>? = null
/**
* @param value A description for this Mobile Network Slice.
*/
@JvmName("wydtvmqywdbouwsp")
public suspend fun description(`value`: Output) {
this.description = value
}
/**
* @param value Specifies the Azure Region where the Mobile Network Slice should exist. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("ohocllbpesnoqpnd")
public suspend fun location(`value`: Output) {
this.location = value
}
/**
* @param value The ID of Mobile Network which the Mobile Network Slice belongs to. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("uuvvpjooacwbaeyw")
public suspend fun mobileNetworkId(`value`: Output) {
this.mobileNetworkId = value
}
/**
* @param value Specifies the name which should be used for this Mobile Network Slice. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("nlhvibbetqjjiuve")
public suspend fun name(`value`: Output) {
this.name = value
}
/**
* @param value A `single_network_slice_selection_assistance_information` block as defined below. Single-network slice selection assistance information (S-NSSAI). Unique at the scope of a mobile network.
*/
@JvmName("ijejhnnqrwkdxndg")
public suspend fun singleNetworkSliceSelectionAssistanceInformation(`value`: Output) {
this.singleNetworkSliceSelectionAssistanceInformation = value
}
/**
* @param value A mapping of tags which should be assigned to the Mobile Network Slice.
*/
@JvmName("httsnmhelwjeivmb")
public suspend fun tags(`value`: Output>) {
this.tags = value
}
/**
* @param value A description for this Mobile Network Slice.
*/
@JvmName("dejnxcupxvctgcwa")
public suspend fun description(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.description = mapped
}
/**
* @param value Specifies the Azure Region where the Mobile Network Slice should exist. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("cyfesjtiwdyiqljo")
public suspend fun location(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.location = mapped
}
/**
* @param value The ID of Mobile Network which the Mobile Network Slice belongs to. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("ehmcvexljdyibqfw")
public suspend fun mobileNetworkId(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.mobileNetworkId = mapped
}
/**
* @param value Specifies the name which should be used for this Mobile Network Slice. Changing this forces a new Mobile Network Slice to be created.
*/
@JvmName("kalngdnekwpslrhw")
public suspend fun name(`value`: String?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.name = mapped
}
/**
* @param value A `single_network_slice_selection_assistance_information` block as defined below. Single-network slice selection assistance information (S-NSSAI). Unique at the scope of a mobile network.
*/
@JvmName("twdwtcriglkkqljj")
public suspend fun singleNetworkSliceSelectionAssistanceInformation(`value`: NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgs?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.singleNetworkSliceSelectionAssistanceInformation = mapped
}
/**
* @param argument A `single_network_slice_selection_assistance_information` block as defined below. Single-network slice selection assistance information (S-NSSAI). Unique at the scope of a mobile network.
*/
@JvmName("nsttdygdwyuvbipt")
public suspend fun singleNetworkSliceSelectionAssistanceInformation(argument: suspend NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgsBuilder.() -> Unit) {
val toBeMapped =
NetworkSliceSingleNetworkSliceSelectionAssistanceInformationArgsBuilder().applySuspend {
argument()
}.build()
val mapped = of(toBeMapped)
this.singleNetworkSliceSelectionAssistanceInformation = mapped
}
/**
* @param value A mapping of tags which should be assigned to the Mobile Network Slice.
*/
@JvmName("vebsublqdxbgoyue")
public suspend fun tags(`value`: Map?) {
val toBeMapped = value
val mapped = toBeMapped?.let({ args0 -> of(args0) })
this.tags = mapped
}
/**
* @param values A mapping of tags which should be assigned to the Mobile Network Slice.
*/
@JvmName("llulmayyddangboj")
public fun tags(vararg values: Pair) {
val toBeMapped = values.toMap()
val mapped = toBeMapped.let({ args0 -> of(args0) })
this.tags = mapped
}
internal fun build(): NetworkSliceArgs = NetworkSliceArgs(
description = description,
location = location,
mobileNetworkId = mobileNetworkId,
name = name,
singleNetworkSliceSelectionAssistanceInformation = singleNetworkSliceSelectionAssistanceInformation,
tags = tags,
)
}