![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.route53profiles.kotlin.ProfileResourceAssociation.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.route53profiles.kotlin
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.String
import kotlin.Suppress
import kotlin.Unit
/**
* Builder for [ProfileResourceAssociation].
*/
@PulumiTagMarker
public class ProfileResourceAssociationResourceBuilder internal constructor() {
public var name: String? = null
public var args: ProfileResourceAssociationArgs = ProfileResourceAssociationArgs()
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 ProfileResourceAssociationArgsBuilder.() -> Unit) {
val builder = ProfileResourceAssociationArgsBuilder()
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(): ProfileResourceAssociation {
val builtJavaResource =
com.pulumi.awsnative.route53profiles.ProfileResourceAssociation(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return ProfileResourceAssociation(builtJavaResource)
}
}
/**
* Resource Type definition for AWS::Route53Profiles::ProfileResourceAssociation
*/
public class ProfileResourceAssociation internal constructor(
override val javaResource: com.pulumi.awsnative.route53profiles.ProfileResourceAssociation,
) : KotlinCustomResource(javaResource, ProfileResourceAssociationMapper) {
/**
* Primary Identifier for Profile Resource Association
*/
public val awsId: Output
get() = javaResource.awsId().applyValue({ args0 -> args0 })
/**
* The name of an association between the Profile and resource.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
/**
* The ID of the profile that you associated the resource to that is specified by ResourceArn.
*/
public val profileId: Output
get() = javaResource.profileId().applyValue({ args0 -> args0 })
/**
* The arn of the resource that you associated to the Profile.
*/
public val resourceArn: Output
get() = javaResource.resourceArn().applyValue({ args0 -> args0 })
/**
* A JSON-formatted string with key-value pairs specifying the properties of the associated resource.
*/
public val resourceProperties: Output?
get() = javaResource.resourceProperties().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The type of the resource associated to the Profile.
*/
public val resourceType: Output
get() = javaResource.resourceType().applyValue({ args0 -> args0 })
}
public object ProfileResourceAssociationMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.awsnative.route53profiles.ProfileResourceAssociation::class == javaResource::class
override fun map(javaResource: Resource): ProfileResourceAssociation =
ProfileResourceAssociation(
javaResource as
com.pulumi.awsnative.route53profiles.ProfileResourceAssociation,
)
}
/**
* @see [ProfileResourceAssociation].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [ProfileResourceAssociation].
*/
public suspend fun profileResourceAssociation(
name: String,
block: suspend ProfileResourceAssociationResourceBuilder.() -> Unit,
): ProfileResourceAssociation {
val builder = ProfileResourceAssociationResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [ProfileResourceAssociation].
* @param name The _unique_ name of the resulting resource.
*/
public fun profileResourceAssociation(name: String): ProfileResourceAssociation {
val builder = ProfileResourceAssociationResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy