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

com.pulumi.azurenative.securityinsights.kotlin.inputs.GroupingConfigurationArgs.kt Maven / Gradle / Ivy

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

package com.pulumi.azurenative.securityinsights.kotlin.inputs

import com.pulumi.azurenative.securityinsights.inputs.GroupingConfigurationArgs.builder
import com.pulumi.azurenative.securityinsights.kotlin.enums.AlertDetail
import com.pulumi.azurenative.securityinsights.kotlin.enums.EntityMappingType
import com.pulumi.azurenative.securityinsights.kotlin.enums.MatchingMethod
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.PulumiNullFieldException
import com.pulumi.kotlin.PulumiTagMarker
import kotlin.Boolean
import kotlin.String
import kotlin.Suppress
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Grouping configuration property bag.
 * @property enabled Grouping enabled
 * @property groupByAlertDetails A list of alert details to group by (when matchingMethod is Selected)
 * @property groupByCustomDetails A list of custom details keys to group by (when matchingMethod is Selected). Only keys defined in the current alert rule may be used.
 * @property groupByEntities A list of entity types to group by (when matchingMethod is Selected). Only entities defined in the current alert rule may be used.
 * @property lookbackDuration Limit the group to alerts created within the lookback duration (in ISO 8601 duration format)
 * @property matchingMethod Grouping matching method. When method is Selected at least one of groupByEntities, groupByAlertDetails, groupByCustomDetails must be provided and not empty.
 * @property reopenClosedIncident Re-open closed matching incidents
 */
public data class GroupingConfigurationArgs(
    public val enabled: Output,
    public val groupByAlertDetails: Output>>? = null,
    public val groupByCustomDetails: Output>? = null,
    public val groupByEntities: Output>>? = null,
    public val lookbackDuration: Output,
    public val matchingMethod: Output>,
    public val reopenClosedIncident: Output,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.azurenative.securityinsights.inputs.GroupingConfigurationArgs =
        com.pulumi.azurenative.securityinsights.inputs.GroupingConfigurationArgs.builder()
            .enabled(enabled.applyValue({ args0 -> args0 }))
            .groupByAlertDetails(
                groupByAlertDetails?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.transform({ args0 -> args0 }, { args0 -> args0.let({ args0 -> args0.toJava() }) })
                    })
                }),
            )
            .groupByCustomDetails(groupByCustomDetails?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .groupByEntities(
                groupByEntities?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.transform({ args0 -> args0 }, { args0 -> args0.let({ args0 -> args0.toJava() }) })
                    })
                }),
            )
            .lookbackDuration(lookbackDuration.applyValue({ args0 -> args0 }))
            .matchingMethod(
                matchingMethod.applyValue({ args0 ->
                    args0.transform({ args0 -> args0 }, { args0 ->
                        args0.let({ args0 -> args0.toJava() })
                    })
                }),
            )
            .reopenClosedIncident(reopenClosedIncident.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [GroupingConfigurationArgs].
 */
@PulumiTagMarker
public class GroupingConfigurationArgsBuilder internal constructor() {
    private var enabled: Output? = null

    private var groupByAlertDetails: Output>>? = null

    private var groupByCustomDetails: Output>? = null

    private var groupByEntities: Output>>? = null

    private var lookbackDuration: Output? = null

    private var matchingMethod: Output>? = null

    private var reopenClosedIncident: Output? = null

    /**
     * @param value Grouping enabled
     */
    @JvmName("ajabkajtjlqckoyq")
    public suspend fun enabled(`value`: Output) {
        this.enabled = value
    }

    /**
     * @param value A list of alert details to group by (when matchingMethod is Selected)
     */
    @JvmName("atmwnjoumvlepxfl")
    public suspend fun groupByAlertDetails(`value`: Output>>) {
        this.groupByAlertDetails = value
    }

    @JvmName("ynxpwnjkbcsgrabm")
    public suspend fun groupByAlertDetails(vararg values: Output>) {
        this.groupByAlertDetails = Output.all(values.asList())
    }

    /**
     * @param values A list of alert details to group by (when matchingMethod is Selected)
     */
    @JvmName("dfupnrvepnolgnto")
    public suspend fun groupByAlertDetails(values: List>>) {
        this.groupByAlertDetails = Output.all(values)
    }

    /**
     * @param value A list of custom details keys to group by (when matchingMethod is Selected). Only keys defined in the current alert rule may be used.
     */
    @JvmName("hsmfpyaqhcyjrhot")
    public suspend fun groupByCustomDetails(`value`: Output>) {
        this.groupByCustomDetails = value
    }

    @JvmName("vbxqilltbtvwjxkg")
    public suspend fun groupByCustomDetails(vararg values: Output) {
        this.groupByCustomDetails = Output.all(values.asList())
    }

    /**
     * @param values A list of custom details keys to group by (when matchingMethod is Selected). Only keys defined in the current alert rule may be used.
     */
    @JvmName("wgdxwlwahcktmsjn")
    public suspend fun groupByCustomDetails(values: List>) {
        this.groupByCustomDetails = Output.all(values)
    }

    /**
     * @param value A list of entity types to group by (when matchingMethod is Selected). Only entities defined in the current alert rule may be used.
     */
    @JvmName("rwudfebrdmehjeab")
    public suspend fun groupByEntities(`value`: Output>>) {
        this.groupByEntities = value
    }

    @JvmName("ewhlgtbwpncnuxbo")
    public suspend fun groupByEntities(vararg values: Output>) {
        this.groupByEntities = Output.all(values.asList())
    }

    /**
     * @param values A list of entity types to group by (when matchingMethod is Selected). Only entities defined in the current alert rule may be used.
     */
    @JvmName("ymijnvypoijillat")
    public suspend fun groupByEntities(values: List>>) {
        this.groupByEntities = Output.all(values)
    }

    /**
     * @param value Limit the group to alerts created within the lookback duration (in ISO 8601 duration format)
     */
    @JvmName("wmaxwqccehqwqqls")
    public suspend fun lookbackDuration(`value`: Output) {
        this.lookbackDuration = value
    }

    /**
     * @param value Grouping matching method. When method is Selected at least one of groupByEntities, groupByAlertDetails, groupByCustomDetails must be provided and not empty.
     */
    @JvmName("ovwoequqysrbngoq")
    public suspend fun matchingMethod(`value`: Output>) {
        this.matchingMethod = value
    }

    /**
     * @param value Re-open closed matching incidents
     */
    @JvmName("hwhjjgaxbnptvxkt")
    public suspend fun reopenClosedIncident(`value`: Output) {
        this.reopenClosedIncident = value
    }

    /**
     * @param value Grouping enabled
     */
    @JvmName("odjqurgjcimpmpef")
    public suspend fun enabled(`value`: Boolean) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.enabled = mapped
    }

    /**
     * @param value A list of alert details to group by (when matchingMethod is Selected)
     */
    @JvmName("tseoxtmjnqyusjnk")
    public suspend fun groupByAlertDetails(`value`: List>?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.groupByAlertDetails = mapped
    }

    /**
     * @param values A list of alert details to group by (when matchingMethod is Selected)
     */
    @JvmName("puiuirhogailpcea")
    public suspend fun groupByAlertDetails(vararg values: Either) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.groupByAlertDetails = mapped
    }

    /**
     * @param value A list of custom details keys to group by (when matchingMethod is Selected). Only keys defined in the current alert rule may be used.
     */
    @JvmName("lkcocixkhdxahevj")
    public suspend fun groupByCustomDetails(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.groupByCustomDetails = mapped
    }

    /**
     * @param values A list of custom details keys to group by (when matchingMethod is Selected). Only keys defined in the current alert rule may be used.
     */
    @JvmName("jciabmviriaxgxym")
    public suspend fun groupByCustomDetails(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.groupByCustomDetails = mapped
    }

    /**
     * @param value A list of entity types to group by (when matchingMethod is Selected). Only entities defined in the current alert rule may be used.
     */
    @JvmName("psdwbvqurgkdjnxf")
    public suspend fun groupByEntities(`value`: List>?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.groupByEntities = mapped
    }

    /**
     * @param values A list of entity types to group by (when matchingMethod is Selected). Only entities defined in the current alert rule may be used.
     */
    @JvmName("iksxmamalickmyjs")
    public suspend fun groupByEntities(vararg values: Either) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.groupByEntities = mapped
    }

    /**
     * @param value Limit the group to alerts created within the lookback duration (in ISO 8601 duration format)
     */
    @JvmName("nhuiskvglpcboorc")
    public suspend fun lookbackDuration(`value`: String) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.lookbackDuration = mapped
    }

    /**
     * @param value Grouping matching method. When method is Selected at least one of groupByEntities, groupByAlertDetails, groupByCustomDetails must be provided and not empty.
     */
    @JvmName("slldelqbgbirwlii")
    public suspend fun matchingMethod(`value`: Either) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.matchingMethod = mapped
    }

    /**
     * @param value Grouping matching method. When method is Selected at least one of groupByEntities, groupByAlertDetails, groupByCustomDetails must be provided and not empty.
     */
    @JvmName("kydfnfhsfqhmrmru")
    public fun matchingMethod(`value`: String) {
        val toBeMapped = Either.ofLeft(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.matchingMethod = mapped
    }

    /**
     * @param value Grouping matching method. When method is Selected at least one of groupByEntities, groupByAlertDetails, groupByCustomDetails must be provided and not empty.
     */
    @JvmName("cniflhybkdtseysl")
    public fun matchingMethod(`value`: MatchingMethod) {
        val toBeMapped = Either.ofRight(value)
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.matchingMethod = mapped
    }

    /**
     * @param value Re-open closed matching incidents
     */
    @JvmName("vxbpqkjydksygvxr")
    public suspend fun reopenClosedIncident(`value`: Boolean) {
        val toBeMapped = value
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.reopenClosedIncident = mapped
    }

    internal fun build(): GroupingConfigurationArgs = GroupingConfigurationArgs(
        enabled = enabled ?: throw PulumiNullFieldException("enabled"),
        groupByAlertDetails = groupByAlertDetails,
        groupByCustomDetails = groupByCustomDetails,
        groupByEntities = groupByEntities,
        lookbackDuration = lookbackDuration ?: throw PulumiNullFieldException("lookbackDuration"),
        matchingMethod = matchingMethod ?: throw PulumiNullFieldException("matchingMethod"),
        reopenClosedIncident = reopenClosedIncident ?: throw
            PulumiNullFieldException("reopenClosedIncident"),
    )
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy