![JAR search and dependency download from the Maven repository](/logo.png)
com.pulumi.awsnative.personalize.kotlin.Solution.kt Maven / Gradle / Ivy
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.personalize.kotlin
import com.pulumi.awsnative.personalize.kotlin.outputs.SolutionConfig
import com.pulumi.awsnative.personalize.kotlin.outputs.SolutionConfig.Companion.toKotlin
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 [Solution].
*/
@PulumiTagMarker
public class SolutionResourceBuilder internal constructor() {
public var name: String? = null
public var args: SolutionArgs = SolutionArgs()
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 SolutionArgsBuilder.() -> Unit) {
val builder = SolutionArgsBuilder()
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(): Solution {
val builtJavaResource = com.pulumi.awsnative.personalize.Solution(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return Solution(builtJavaResource)
}
}
/**
* Resource schema for AWS::Personalize::Solution.
* ## Example Usage
* ### Example
* No Java example available.
* ### Example
* No Java example available.
*/
public class Solution internal constructor(
override val javaResource: com.pulumi.awsnative.personalize.Solution,
) : KotlinCustomResource(javaResource, SolutionMapper) {
/**
* The ARN of the dataset group that provides the training data.
*/
public val datasetGroupArn: Output
get() = javaResource.datasetGroupArn().applyValue({ args0 -> args0 })
/**
* When your have multiple event types (using an EVENT_TYPE schema field), this parameter specifies which event type (for example, 'click' or 'like') is used for training the model. If you do not provide an eventType, Amazon Personalize will use all interactions for training with equal weight regardless of type.
*/
public val eventType: Output?
get() = javaResource.eventType().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The name for the solution
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
/**
* Whether to perform automated machine learning (AutoML). The default is false. For this case, you must specify recipeArn.
*/
public val performAutoMl: Output?
get() = javaResource.performAutoMl().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* Whether to perform hyperparameter optimization (HPO) on the specified or selected recipe. The default is false. When performing AutoML, this parameter is always true and you should not set it to false.
*/
public val performHpo: Output?
get() = javaResource.performHpo().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The ARN of the recipe to use for model training. Only specified when performAutoML is false.
*/
public val recipeArn: Output?
get() = javaResource.recipeArn().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The Amazon Resource Name (ARN) of the solution.
*/
public val solutionArn: Output
get() = javaResource.solutionArn().applyValue({ args0 -> args0 })
/**
* Describes the configuration properties for the solution.
*/
public val solutionConfig: Output?
get() = javaResource.solutionConfig().applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> toKotlin(args0) })
}).orElse(null)
})
}
public object SolutionMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.awsnative.personalize.Solution::class == javaResource::class
override fun map(javaResource: Resource): Solution = Solution(
javaResource as
com.pulumi.awsnative.personalize.Solution,
)
}
/**
* @see [Solution].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [Solution].
*/
public suspend fun solution(name: String, block: suspend SolutionResourceBuilder.() -> Unit): Solution {
val builder = SolutionResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [Solution].
* @param name The _unique_ name of the resulting resource.
*/
public fun solution(name: String): Solution {
val builder = SolutionResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy