commonMain.aws.sdk.kotlin.services.proton.model.ResourceCountsSummary.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of proton-jvm Show documentation
Show all versions of proton-jvm Show documentation
The AWS SDK for Kotlin client for Proton
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.proton.model
import aws.smithy.kotlin.runtime.SdkDsl
/**
* Summary counts of each Proton resource types.
*/
public class ResourceCountsSummary private constructor(builder: Builder) {
/**
* The number of resources of this type in the Amazon Web Services account that need a major template version update.
*/
public val behindMajor: kotlin.Int? = builder.behindMajor
/**
* The number of resources of this type in the Amazon Web Services account that need a minor template version update.
*/
public val behindMinor: kotlin.Int? = builder.behindMinor
/**
* The number of resources of this type in the Amazon Web Services account that failed to deploy.
*/
public val failed: kotlin.Int? = builder.failed
/**
* The total number of resources of this type in the Amazon Web Services account.
*/
public val total: kotlin.Int = requireNotNull(builder.total) { "A non-null value must be provided for total" }
/**
* The number of resources of this type in the Amazon Web Services account that are up-to-date with their template.
*/
public val upToDate: kotlin.Int? = builder.upToDate
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.proton.model.ResourceCountsSummary = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ResourceCountsSummary(")
append("behindMajor=$behindMajor,")
append("behindMinor=$behindMinor,")
append("failed=$failed,")
append("total=$total,")
append("upToDate=$upToDate")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = behindMajor ?: 0
result = 31 * result + (behindMinor ?: 0)
result = 31 * result + (failed ?: 0)
result = 31 * result + (total)
result = 31 * result + (upToDate ?: 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 ResourceCountsSummary
if (behindMajor != other.behindMajor) return false
if (behindMinor != other.behindMinor) return false
if (failed != other.failed) return false
if (total != other.total) return false
if (upToDate != other.upToDate) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.proton.model.ResourceCountsSummary = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The number of resources of this type in the Amazon Web Services account that need a major template version update.
*/
public var behindMajor: kotlin.Int? = null
/**
* The number of resources of this type in the Amazon Web Services account that need a minor template version update.
*/
public var behindMinor: kotlin.Int? = null
/**
* The number of resources of this type in the Amazon Web Services account that failed to deploy.
*/
public var failed: kotlin.Int? = null
/**
* The total number of resources of this type in the Amazon Web Services account.
*/
public var total: kotlin.Int? = null
/**
* The number of resources of this type in the Amazon Web Services account that are up-to-date with their template.
*/
public var upToDate: kotlin.Int? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.proton.model.ResourceCountsSummary) : this() {
this.behindMajor = x.behindMajor
this.behindMinor = x.behindMinor
this.failed = x.failed
this.total = x.total
this.upToDate = x.upToDate
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.proton.model.ResourceCountsSummary = ResourceCountsSummary(this)
internal fun correctErrors(): Builder {
if (total == null) total = 0
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy