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

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

There is a newer version: 1.3.37
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

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

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Identifies an Config rule that evaluated an Amazon Web Services resource, and provides the type and ID of the resource that the rule evaluated.
 */
public class EvaluationResultQualifier private constructor(builder: Builder) {
    /**
     * The name of the Config rule that was used in the evaluation.
     */
    public val configRuleName: kotlin.String? = builder.configRuleName
    /**
     * The mode of an evaluation. The valid values are Detective or Proactive.
     */
    public val evaluationMode: aws.sdk.kotlin.services.configservice.model.EvaluationMode? = builder.evaluationMode
    /**
     * The ID of the evaluated Amazon Web Services resource.
     */
    public val resourceId: kotlin.String? = builder.resourceId
    /**
     * The type of Amazon Web Services resource that was evaluated.
     */
    public val resourceType: kotlin.String? = builder.resourceType

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

    override fun toString(): kotlin.String = buildString {
        append("EvaluationResultQualifier(")
        append("configRuleName=$configRuleName,")
        append("evaluationMode=$evaluationMode,")
        append("resourceId=$resourceId,")
        append("resourceType=$resourceType")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = configRuleName?.hashCode() ?: 0
        result = 31 * result + (evaluationMode?.hashCode() ?: 0)
        result = 31 * result + (resourceId?.hashCode() ?: 0)
        result = 31 * result + (resourceType?.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 EvaluationResultQualifier

        if (configRuleName != other.configRuleName) return false
        if (evaluationMode != other.evaluationMode) return false
        if (resourceId != other.resourceId) return false
        if (resourceType != other.resourceType) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The name of the Config rule that was used in the evaluation.
         */
        public var configRuleName: kotlin.String? = null
        /**
         * The mode of an evaluation. The valid values are Detective or Proactive.
         */
        public var evaluationMode: aws.sdk.kotlin.services.configservice.model.EvaluationMode? = null
        /**
         * The ID of the evaluated Amazon Web Services resource.
         */
        public var resourceId: kotlin.String? = null
        /**
         * The type of Amazon Web Services resource that was evaluated.
         */
        public var resourceType: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.configservice.model.EvaluationResultQualifier) : this() {
            this.configRuleName = x.configRuleName
            this.evaluationMode = x.evaluationMode
            this.resourceId = x.resourceId
            this.resourceType = x.resourceType
        }

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

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy