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

com.pulumi.awsnative.connect.kotlin.SecurityProfile.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: 1.11.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.awsnative.connect.kotlin

import com.pulumi.awsnative.connect.kotlin.outputs.SecurityProfileApplication
import com.pulumi.awsnative.connect.kotlin.outputs.SecurityProfileTag
import com.pulumi.awsnative.kotlin.outputs.Tag
import com.pulumi.core.Output
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Boolean
import kotlin.Double
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import com.pulumi.awsnative.connect.kotlin.outputs.SecurityProfileApplication.Companion.toKotlin as securityProfileApplicationToKotlin
import com.pulumi.awsnative.connect.kotlin.outputs.SecurityProfileTag.Companion.toKotlin as securityProfileTagToKotlin
import com.pulumi.awsnative.kotlin.outputs.Tag.Companion.toKotlin as tagToKotlin

/**
 * Builder for [SecurityProfile].
 */
@PulumiTagMarker
public class SecurityProfileResourceBuilder internal constructor() {
    public var name: String? = null

    public var args: SecurityProfileArgs = SecurityProfileArgs()

    public var opts: CustomResourceOptions = CustomResourceOptions()

    /**
     * @param name The _unique_ name of the resulting resource.
     */
    public fun name(`value`: String) {
        this.name = value
    }

    /**
     * @param block The arguments to use to populate this resource's properties.
     */
    public suspend fun args(block: suspend SecurityProfileArgsBuilder.() -> Unit) {
        val builder = SecurityProfileArgsBuilder()
        block(builder)
        this.args = builder.build()
    }

    /**
     * @param block A bag of options that control this resource's behavior.
     */
    public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
        this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
    }

    internal fun build(): SecurityProfile {
        val builtJavaResource = com.pulumi.awsnative.connect.SecurityProfile(
            this.name,
            this.args.toJava(),
            this.opts.toJava(),
        )
        return SecurityProfile(builtJavaResource)
    }
}

/**
 * Resource Type definition for AWS::Connect::SecurityProfile
 */
public class SecurityProfile internal constructor(
    override val javaResource: com.pulumi.awsnative.connect.SecurityProfile,
) : KotlinCustomResource(javaResource, SecurityProfileMapper) {
    /**
     * The identifier of the hierarchy group that a security profile uses to restrict access to resources in Amazon Connect.
     */
    public val allowedAccessControlHierarchyGroupId: Output?
        get() = javaResource.allowedAccessControlHierarchyGroupId().applyValue({ args0 ->
            args0.map({ args0 -> args0 }).orElse(null)
        })

    /**
     * The list of tags that a security profile uses to restrict access to resources in Amazon Connect.
     */
    public val allowedAccessControlTags: Output>?
        get() = javaResource.allowedAccessControlTags().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.let({ args0 ->
                        securityProfileTagToKotlin(args0)
                    })
                })
            }).orElse(null)
        })

    /**
     * A list of third-party applications that the security profile will give access to.
     */
    public val applications: Output>?
        get() = javaResource.applications().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.let({ args0 -> securityProfileApplicationToKotlin(args0) })
                })
            }).orElse(null)
        })

    /**
     * The description of the security profile.
     */
    public val description: Output?
        get() = javaResource.description().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * The list of resources that a security profile applies hierarchy restrictions to in Amazon Connect.
     */
    public val hierarchyRestrictedResources: Output>?
        get() = javaResource.hierarchyRestrictedResources().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 -> args0 })
            }).orElse(null)
        })

    /**
     * The identifier of the Amazon Connect instance.
     */
    public val instanceArn: Output
        get() = javaResource.instanceArn().applyValue({ args0 -> args0 })

    /**
     * The AWS Region where this resource was last modified.
     */
    public val lastModifiedRegion: Output
        get() = javaResource.lastModifiedRegion().applyValue({ args0 -> args0 })

    /**
     * The timestamp when this resource was last modified.
     */
    public val lastModifiedTime: Output
        get() = javaResource.lastModifiedTime().applyValue({ args0 -> args0 })

    /**
     * Permissions assigned to the security profile.
     */
    public val permissions: Output>?
        get() = javaResource.permissions().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0
                })
            }).orElse(null)
        })

    /**
     * The Amazon Resource Name (ARN) for the security profile.
     */
    public val securityProfileArn: Output
        get() = javaResource.securityProfileArn().applyValue({ args0 -> args0 })

    /**
     * The name of the security profile.
     */
    public val securityProfileName: Output
        get() = javaResource.securityProfileName().applyValue({ args0 -> args0 })

    /**
     * The list of resources that a security profile applies tag restrictions to in Amazon Connect.
     */
    public val tagRestrictedResources: Output>?
        get() = javaResource.tagRestrictedResources().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 -> args0 })
            }).orElse(null)
        })

    /**
     * The tags used to organize, track, or control access for this resource.
     */
    public val tags: Output>?
        get() = javaResource.tags().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.map({ args0 ->
                    args0.let({ args0 -> tagToKotlin(args0) })
                })
            }).orElse(null)
        })
}

public object SecurityProfileMapper : ResourceMapper {
    override fun supportsMappingOfType(javaResource: Resource): Boolean =
        com.pulumi.awsnative.connect.SecurityProfile::class == javaResource::class

    override fun map(javaResource: Resource): SecurityProfile = SecurityProfile(
        javaResource as
            com.pulumi.awsnative.connect.SecurityProfile,
    )
}

/**
 * @see [SecurityProfile].
 * @param name The _unique_ name of the resulting resource.
 * @param block Builder for [SecurityProfile].
 */
public suspend fun securityProfile(
    name: String,
    block: suspend SecurityProfileResourceBuilder.() -> Unit,
): SecurityProfile {
    val builder = SecurityProfileResourceBuilder()
    builder.name(name)
    block(builder)
    return builder.build()
}

/**
 * @see [SecurityProfile].
 * @param name The _unique_ name of the resulting resource.
 */
public fun securityProfile(name: String): SecurityProfile {
    val builder = SecurityProfileResourceBuilder()
    builder.name(name)
    return builder.build()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy