commonMain.aws.sdk.kotlin.services.configservice.model.ComplianceSummary.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.configservice.model
import aws.smithy.kotlin.runtime.time.Instant
/**
* The number of Config rules or Amazon Web Services resources that are compliant and noncompliant.
*/
public class ComplianceSummary private constructor(builder: Builder) {
/**
* The time that Config created the compliance summary.
*/
public val complianceSummaryTimestamp: aws.smithy.kotlin.runtime.time.Instant? = builder.complianceSummaryTimestamp
/**
* The number of Config rules or Amazon Web Services resources that are compliant, up to a maximum of 25 for rules and 100 for resources.
*/
public val compliantResourceCount: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount? = builder.compliantResourceCount
/**
* The number of Config rules or Amazon Web Services resources that are noncompliant, up to a maximum of 25 for rules and 100 for resources.
*/
public val nonCompliantResourceCount: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount? = builder.nonCompliantResourceCount
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.configservice.model.ComplianceSummary = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ComplianceSummary(")
append("complianceSummaryTimestamp=$complianceSummaryTimestamp,")
append("compliantResourceCount=$compliantResourceCount,")
append("nonCompliantResourceCount=$nonCompliantResourceCount")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = complianceSummaryTimestamp?.hashCode() ?: 0
result = 31 * result + (compliantResourceCount?.hashCode() ?: 0)
result = 31 * result + (nonCompliantResourceCount?.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 ComplianceSummary
if (complianceSummaryTimestamp != other.complianceSummaryTimestamp) return false
if (compliantResourceCount != other.compliantResourceCount) return false
if (nonCompliantResourceCount != other.nonCompliantResourceCount) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.configservice.model.ComplianceSummary = Builder(this).apply(block).build()
public class Builder {
/**
* The time that Config created the compliance summary.
*/
public var complianceSummaryTimestamp: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The number of Config rules or Amazon Web Services resources that are compliant, up to a maximum of 25 for rules and 100 for resources.
*/
public var compliantResourceCount: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount? = null
/**
* The number of Config rules or Amazon Web Services resources that are noncompliant, up to a maximum of 25 for rules and 100 for resources.
*/
public var nonCompliantResourceCount: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.configservice.model.ComplianceSummary) : this() {
this.complianceSummaryTimestamp = x.complianceSummaryTimestamp
this.compliantResourceCount = x.compliantResourceCount
this.nonCompliantResourceCount = x.nonCompliantResourceCount
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.configservice.model.ComplianceSummary = ComplianceSummary(this)
/**
* construct an [aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount] inside the given [block]
*/
public fun compliantResourceCount(block: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount.Builder.() -> kotlin.Unit) {
this.compliantResourceCount = aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount.invoke(block)
}
/**
* construct an [aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount] inside the given [block]
*/
public fun nonCompliantResourceCount(block: aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount.Builder.() -> kotlin.Unit) {
this.nonCompliantResourceCount = aws.sdk.kotlin.services.configservice.model.ComplianceContributorCount.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy