commonMain.aws.sdk.kotlin.services.proton.model.ServiceInstanceState.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
/**
* The detailed data about the current state of this service instance.
*/
public class ServiceInstanceState private constructor(builder: Builder) {
/**
* The IDs for the last successful components deployed for this service instance.
*/
public val lastSuccessfulComponentDeploymentIds: List? = builder.lastSuccessfulComponentDeploymentIds
/**
* The ID for the last successful environment deployed for this service instance.
*/
public val lastSuccessfulEnvironmentDeploymentId: kotlin.String? = builder.lastSuccessfulEnvironmentDeploymentId
/**
* The ID for the last successful service pipeline deployed for this service instance.
*/
public val lastSuccessfulServicePipelineDeploymentId: kotlin.String? = builder.lastSuccessfulServicePipelineDeploymentId
/**
* The service spec that was used to create the service instance.
*/
public val spec: kotlin.String = requireNotNull(builder.spec) { "A non-null value must be provided for spec" }
/**
* The major version of the service template that was used to create the service pipeline.
*/
public val templateMajorVersion: kotlin.String = requireNotNull(builder.templateMajorVersion) { "A non-null value must be provided for templateMajorVersion" }
/**
* The minor version of the service template that was used to create the service pipeline.
*/
public val templateMinorVersion: kotlin.String = requireNotNull(builder.templateMinorVersion) { "A non-null value must be provided for templateMinorVersion" }
/**
* The name of the service template that was used to create the service instance.
*/
public val templateName: kotlin.String = requireNotNull(builder.templateName) { "A non-null value must be provided for templateName" }
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.proton.model.ServiceInstanceState = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ServiceInstanceState(")
append("lastSuccessfulComponentDeploymentIds=$lastSuccessfulComponentDeploymentIds,")
append("lastSuccessfulEnvironmentDeploymentId=$lastSuccessfulEnvironmentDeploymentId,")
append("lastSuccessfulServicePipelineDeploymentId=$lastSuccessfulServicePipelineDeploymentId,")
append("spec=*** Sensitive Data Redacted ***,")
append("templateMajorVersion=$templateMajorVersion,")
append("templateMinorVersion=$templateMinorVersion,")
append("templateName=$templateName")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = lastSuccessfulComponentDeploymentIds?.hashCode() ?: 0
result = 31 * result + (lastSuccessfulEnvironmentDeploymentId?.hashCode() ?: 0)
result = 31 * result + (lastSuccessfulServicePipelineDeploymentId?.hashCode() ?: 0)
result = 31 * result + (spec.hashCode())
result = 31 * result + (templateMajorVersion.hashCode())
result = 31 * result + (templateMinorVersion.hashCode())
result = 31 * result + (templateName.hashCode())
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 ServiceInstanceState
if (lastSuccessfulComponentDeploymentIds != other.lastSuccessfulComponentDeploymentIds) return false
if (lastSuccessfulEnvironmentDeploymentId != other.lastSuccessfulEnvironmentDeploymentId) return false
if (lastSuccessfulServicePipelineDeploymentId != other.lastSuccessfulServicePipelineDeploymentId) return false
if (spec != other.spec) return false
if (templateMajorVersion != other.templateMajorVersion) return false
if (templateMinorVersion != other.templateMinorVersion) return false
if (templateName != other.templateName) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.proton.model.ServiceInstanceState = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The IDs for the last successful components deployed for this service instance.
*/
public var lastSuccessfulComponentDeploymentIds: List? = null
/**
* The ID for the last successful environment deployed for this service instance.
*/
public var lastSuccessfulEnvironmentDeploymentId: kotlin.String? = null
/**
* The ID for the last successful service pipeline deployed for this service instance.
*/
public var lastSuccessfulServicePipelineDeploymentId: kotlin.String? = null
/**
* The service spec that was used to create the service instance.
*/
public var spec: kotlin.String? = null
/**
* The major version of the service template that was used to create the service pipeline.
*/
public var templateMajorVersion: kotlin.String? = null
/**
* The minor version of the service template that was used to create the service pipeline.
*/
public var templateMinorVersion: kotlin.String? = null
/**
* The name of the service template that was used to create the service instance.
*/
public var templateName: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.proton.model.ServiceInstanceState) : this() {
this.lastSuccessfulComponentDeploymentIds = x.lastSuccessfulComponentDeploymentIds
this.lastSuccessfulEnvironmentDeploymentId = x.lastSuccessfulEnvironmentDeploymentId
this.lastSuccessfulServicePipelineDeploymentId = x.lastSuccessfulServicePipelineDeploymentId
this.spec = x.spec
this.templateMajorVersion = x.templateMajorVersion
this.templateMinorVersion = x.templateMinorVersion
this.templateName = x.templateName
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.proton.model.ServiceInstanceState = ServiceInstanceState(this)
internal fun correctErrors(): Builder {
if (spec == null) spec = ""
if (templateMajorVersion == null) templateMajorVersion = ""
if (templateMinorVersion == null) templateMinorVersion = ""
if (templateName == null) templateName = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy