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

commonMain.aws.sdk.kotlin.services.configservice.model.OrganizationManagedRuleMetadata.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.configservice.model



/**
 * An object that specifies organization managed rule metadata such as resource type and ID of Amazon Web Services resource along with the rule identifier. It also provides the frequency with which you want Config to run evaluations for the rule if the trigger type is periodic.
 */
class OrganizationManagedRuleMetadata private constructor(builder: Builder) {
    /**
     * The description that you provide for your organization Config rule.
     */
    val description: kotlin.String? = builder.description
    /**
     * A string, in JSON format, that is passed to your organization Config rule Lambda function.
     */
    val inputParameters: kotlin.String? = builder.inputParameters
    /**
     * The maximum frequency with which Config runs evaluations for a rule. You are using an Config managed rule that is triggered at a periodic frequency.
     *
     * By default, rules with a periodic trigger are evaluated every 24 hours. To change the frequency, specify a valid value for the `MaximumExecutionFrequency` parameter.
     */
    val maximumExecutionFrequency: aws.sdk.kotlin.services.configservice.model.MaximumExecutionFrequency? = builder.maximumExecutionFrequency
    /**
     * The ID of the Amazon Web Services resource that was evaluated.
     */
    val resourceIdScope: kotlin.String? = builder.resourceIdScope
    /**
     * The type of the Amazon Web Services resource that was evaluated.
     */
    val resourceTypesScope: List? = builder.resourceTypesScope
    /**
     * For organization config managed rules, a predefined identifier from a list. For example, `IAM_PASSWORD_POLICY` is a managed rule. To reference a managed rule, see [Using Config managed rules](https://docs.aws.amazon.com/config/latest/developerguide/evaluate-config_use-managed-rules.html).
     */
    val ruleIdentifier: kotlin.String? = builder.ruleIdentifier
    /**
     * One part of a key-value pair that make up a tag. A key is a general label that acts like a category for more specific tag values.
     */
    val tagKeyScope: kotlin.String? = builder.tagKeyScope
    /**
     * The optional part of a key-value pair that make up a tag. A value acts as a descriptor within a tag category (key).
     */
    val tagValueScope: kotlin.String? = builder.tagValueScope

    companion object {
        operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.configservice.model.OrganizationManagedRuleMetadata = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("OrganizationManagedRuleMetadata(")
        append("description=$description,")
        append("inputParameters=$inputParameters,")
        append("maximumExecutionFrequency=$maximumExecutionFrequency,")
        append("resourceIdScope=$resourceIdScope,")
        append("resourceTypesScope=$resourceTypesScope,")
        append("ruleIdentifier=$ruleIdentifier,")
        append("tagKeyScope=$tagKeyScope,")
        append("tagValueScope=$tagValueScope)")
    }

    override fun hashCode(): kotlin.Int {
        var result = description?.hashCode() ?: 0
        result = 31 * result + (inputParameters?.hashCode() ?: 0)
        result = 31 * result + (maximumExecutionFrequency?.hashCode() ?: 0)
        result = 31 * result + (resourceIdScope?.hashCode() ?: 0)
        result = 31 * result + (resourceTypesScope?.hashCode() ?: 0)
        result = 31 * result + (ruleIdentifier?.hashCode() ?: 0)
        result = 31 * result + (tagKeyScope?.hashCode() ?: 0)
        result = 31 * result + (tagValueScope?.hashCode() ?: 0)
        return result
    }

    override fun equals(other: kotlin.Any?): kotlin.Boolean {
        if (this === other) return true
        if (other == null || this::class != other::class) return false

        other as OrganizationManagedRuleMetadata

        if (description != other.description) return false
        if (inputParameters != other.inputParameters) return false
        if (maximumExecutionFrequency != other.maximumExecutionFrequency) return false
        if (resourceIdScope != other.resourceIdScope) return false
        if (resourceTypesScope != other.resourceTypesScope) return false
        if (ruleIdentifier != other.ruleIdentifier) return false
        if (tagKeyScope != other.tagKeyScope) return false
        if (tagValueScope != other.tagValueScope) return false

        return true
    }

    inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.configservice.model.OrganizationManagedRuleMetadata = Builder(this).apply(block).build()

    class Builder {
        /**
         * The description that you provide for your organization Config rule.
         */
        var description: kotlin.String? = null
        /**
         * A string, in JSON format, that is passed to your organization Config rule Lambda function.
         */
        var inputParameters: kotlin.String? = null
        /**
         * The maximum frequency with which Config runs evaluations for a rule. You are using an Config managed rule that is triggered at a periodic frequency.
         *
         * By default, rules with a periodic trigger are evaluated every 24 hours. To change the frequency, specify a valid value for the `MaximumExecutionFrequency` parameter.
         */
        var maximumExecutionFrequency: aws.sdk.kotlin.services.configservice.model.MaximumExecutionFrequency? = null
        /**
         * The ID of the Amazon Web Services resource that was evaluated.
         */
        var resourceIdScope: kotlin.String? = null
        /**
         * The type of the Amazon Web Services resource that was evaluated.
         */
        var resourceTypesScope: List? = null
        /**
         * For organization config managed rules, a predefined identifier from a list. For example, `IAM_PASSWORD_POLICY` is a managed rule. To reference a managed rule, see [Using Config managed rules](https://docs.aws.amazon.com/config/latest/developerguide/evaluate-config_use-managed-rules.html).
         */
        var ruleIdentifier: kotlin.String? = null
        /**
         * One part of a key-value pair that make up a tag. A key is a general label that acts like a category for more specific tag values.
         */
        var tagKeyScope: kotlin.String? = null
        /**
         * The optional part of a key-value pair that make up a tag. A value acts as a descriptor within a tag category (key).
         */
        var tagValueScope: kotlin.String? = null

        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.configservice.model.OrganizationManagedRuleMetadata) : this() {
            this.description = x.description
            this.inputParameters = x.inputParameters
            this.maximumExecutionFrequency = x.maximumExecutionFrequency
            this.resourceIdScope = x.resourceIdScope
            this.resourceTypesScope = x.resourceTypesScope
            this.ruleIdentifier = x.ruleIdentifier
            this.tagKeyScope = x.tagKeyScope
            this.tagValueScope = x.tagValueScope
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.configservice.model.OrganizationManagedRuleMetadata = OrganizationManagedRuleMetadata(this)
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy