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

commonMain.aws.sdk.kotlin.services.ssm.model.NonCompliantSummary.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.ssm.model



/**
 * A summary of resources that aren't compliant. The summary is organized according to resource type.
 */
public class NonCompliantSummary private constructor(builder: Builder) {
    /**
     * The total number of compliance items that aren't compliant.
     */
    public val nonCompliantCount: kotlin.Int = builder.nonCompliantCount
    /**
     * A summary of the non-compliance severity by compliance type
     */
    public val severitySummary: aws.sdk.kotlin.services.ssm.model.SeveritySummary? = builder.severitySummary

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

    override fun toString(): kotlin.String = buildString {
        append("NonCompliantSummary(")
        append("nonCompliantCount=$nonCompliantCount,")
        append("severitySummary=$severitySummary")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = nonCompliantCount
        result = 31 * result + (severitySummary?.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 NonCompliantSummary

        if (nonCompliantCount != other.nonCompliantCount) return false
        if (severitySummary != other.severitySummary) return false

        return true
    }

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

    public class Builder {
        /**
         * The total number of compliance items that aren't compliant.
         */
        public var nonCompliantCount: kotlin.Int = 0
        /**
         * A summary of the non-compliance severity by compliance type
         */
        public var severitySummary: aws.sdk.kotlin.services.ssm.model.SeveritySummary? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.ssm.model.NonCompliantSummary) : this() {
            this.nonCompliantCount = x.nonCompliantCount
            this.severitySummary = x.severitySummary
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.ssm.model.SeveritySummary] inside the given [block]
         */
        public fun severitySummary(block: aws.sdk.kotlin.services.ssm.model.SeveritySummary.Builder.() -> kotlin.Unit) {
            this.severitySummary = aws.sdk.kotlin.services.ssm.model.SeveritySummary.invoke(block)
        }

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy