commonMain.aws.sdk.kotlin.services.proton.model.EnvironmentSummary.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
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.proton.model
import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant
/**
* Summary data of an Proton environment resource. An Proton environment is a set of resources shared across Proton services.
*/
public class EnvironmentSummary private constructor(builder: Builder) {
/**
* The Amazon Resource Name (ARN) of the environment.
*/
public val arn: kotlin.String = requireNotNull(builder.arn) { "A non-null value must be provided for arn" }
/**
* The Amazon Resource Name (ARN) of the IAM service role that Proton uses when provisioning directly defined components in this environment. It determines the scope of infrastructure that a component can provision.
*
* The environment must have a `componentRoleArn` to allow directly defined components to be associated with the environment.
*
* For more information about components, see [Proton components](https://docs.aws.amazon.com/proton/latest/userguide/ag-components.html) in the *Proton User Guide*.
*/
public val componentRoleArn: kotlin.String? = builder.componentRoleArn
/**
* The time when the environment was created.
*/
public val createdAt: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.createdAt) { "A non-null value must be provided for createdAt" }
/**
* The environment deployment status.
*/
public val deploymentStatus: aws.sdk.kotlin.services.proton.model.DeploymentStatus = requireNotNull(builder.deploymentStatus) { "A non-null value must be provided for deploymentStatus" }
/**
* An environment deployment status message.
*/
public val deploymentStatusMessage: kotlin.String? = builder.deploymentStatusMessage
/**
* The description of the environment.
*/
public val description: kotlin.String? = builder.description
/**
* The ID of the environment account connection that the environment is associated with.
*/
public val environmentAccountConnectionId: kotlin.String? = builder.environmentAccountConnectionId
/**
* The ID of the environment account that the environment infrastructure resources are provisioned in.
*/
public val environmentAccountId: kotlin.String? = builder.environmentAccountId
/**
* The ID of the last attempted deployment of this environment.
*/
public val lastAttemptedDeploymentId: kotlin.String? = builder.lastAttemptedDeploymentId
/**
* The time when a deployment of the environment was last attempted.
*/
public val lastDeploymentAttemptedAt: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.lastDeploymentAttemptedAt) { "A non-null value must be provided for lastDeploymentAttemptedAt" }
/**
* The time when the environment was last deployed successfully.
*/
public val lastDeploymentSucceededAt: aws.smithy.kotlin.runtime.time.Instant = requireNotNull(builder.lastDeploymentSucceededAt) { "A non-null value must be provided for lastDeploymentSucceededAt" }
/**
* The ID of the last successful deployment of this environment.
*/
public val lastSucceededDeploymentId: kotlin.String? = builder.lastSucceededDeploymentId
/**
* The name of the environment.
*/
public val name: kotlin.String = requireNotNull(builder.name) { "A non-null value must be provided for name" }
/**
* The Amazon Resource Name (ARN) of the Proton service role that allows Proton to make calls to other services on your behalf.
*/
public val protonServiceRoleArn: kotlin.String? = builder.protonServiceRoleArn
/**
* When included, indicates that the environment template is for customer provisioned and managed infrastructure.
*/
public val provisioning: aws.sdk.kotlin.services.proton.model.Provisioning? = builder.provisioning
/**
* The major version of the environment template.
*/
public val templateMajorVersion: kotlin.String = requireNotNull(builder.templateMajorVersion) { "A non-null value must be provided for templateMajorVersion" }
/**
* The minor version of the environment template.
*/
public val templateMinorVersion: kotlin.String = requireNotNull(builder.templateMinorVersion) { "A non-null value must be provided for templateMinorVersion" }
/**
* The name of the environment template.
*/
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.EnvironmentSummary = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("EnvironmentSummary(")
append("arn=$arn,")
append("componentRoleArn=$componentRoleArn,")
append("createdAt=$createdAt,")
append("deploymentStatus=$deploymentStatus,")
append("deploymentStatusMessage=*** Sensitive Data Redacted ***,")
append("description=*** Sensitive Data Redacted ***,")
append("environmentAccountConnectionId=$environmentAccountConnectionId,")
append("environmentAccountId=$environmentAccountId,")
append("lastAttemptedDeploymentId=$lastAttemptedDeploymentId,")
append("lastDeploymentAttemptedAt=$lastDeploymentAttemptedAt,")
append("lastDeploymentSucceededAt=$lastDeploymentSucceededAt,")
append("lastSucceededDeploymentId=$lastSucceededDeploymentId,")
append("name=$name,")
append("protonServiceRoleArn=$protonServiceRoleArn,")
append("provisioning=$provisioning,")
append("templateMajorVersion=$templateMajorVersion,")
append("templateMinorVersion=$templateMinorVersion,")
append("templateName=$templateName")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = arn.hashCode()
result = 31 * result + (componentRoleArn?.hashCode() ?: 0)
result = 31 * result + (createdAt.hashCode())
result = 31 * result + (deploymentStatus.hashCode())
result = 31 * result + (deploymentStatusMessage?.hashCode() ?: 0)
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (environmentAccountConnectionId?.hashCode() ?: 0)
result = 31 * result + (environmentAccountId?.hashCode() ?: 0)
result = 31 * result + (lastAttemptedDeploymentId?.hashCode() ?: 0)
result = 31 * result + (lastDeploymentAttemptedAt.hashCode())
result = 31 * result + (lastDeploymentSucceededAt.hashCode())
result = 31 * result + (lastSucceededDeploymentId?.hashCode() ?: 0)
result = 31 * result + (name.hashCode())
result = 31 * result + (protonServiceRoleArn?.hashCode() ?: 0)
result = 31 * result + (provisioning?.hashCode() ?: 0)
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 EnvironmentSummary
if (arn != other.arn) return false
if (componentRoleArn != other.componentRoleArn) return false
if (createdAt != other.createdAt) return false
if (deploymentStatus != other.deploymentStatus) return false
if (deploymentStatusMessage != other.deploymentStatusMessage) return false
if (description != other.description) return false
if (environmentAccountConnectionId != other.environmentAccountConnectionId) return false
if (environmentAccountId != other.environmentAccountId) return false
if (lastAttemptedDeploymentId != other.lastAttemptedDeploymentId) return false
if (lastDeploymentAttemptedAt != other.lastDeploymentAttemptedAt) return false
if (lastDeploymentSucceededAt != other.lastDeploymentSucceededAt) return false
if (lastSucceededDeploymentId != other.lastSucceededDeploymentId) return false
if (name != other.name) return false
if (protonServiceRoleArn != other.protonServiceRoleArn) return false
if (provisioning != other.provisioning) 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.EnvironmentSummary = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The Amazon Resource Name (ARN) of the environment.
*/
public var arn: kotlin.String? = null
/**
* The Amazon Resource Name (ARN) of the IAM service role that Proton uses when provisioning directly defined components in this environment. It determines the scope of infrastructure that a component can provision.
*
* The environment must have a `componentRoleArn` to allow directly defined components to be associated with the environment.
*
* For more information about components, see [Proton components](https://docs.aws.amazon.com/proton/latest/userguide/ag-components.html) in the *Proton User Guide*.
*/
public var componentRoleArn: kotlin.String? = null
/**
* The time when the environment was created.
*/
public var createdAt: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The environment deployment status.
*/
public var deploymentStatus: aws.sdk.kotlin.services.proton.model.DeploymentStatus? = null
/**
* An environment deployment status message.
*/
public var deploymentStatusMessage: kotlin.String? = null
/**
* The description of the environment.
*/
public var description: kotlin.String? = null
/**
* The ID of the environment account connection that the environment is associated with.
*/
public var environmentAccountConnectionId: kotlin.String? = null
/**
* The ID of the environment account that the environment infrastructure resources are provisioned in.
*/
public var environmentAccountId: kotlin.String? = null
/**
* The ID of the last attempted deployment of this environment.
*/
public var lastAttemptedDeploymentId: kotlin.String? = null
/**
* The time when a deployment of the environment was last attempted.
*/
public var lastDeploymentAttemptedAt: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The time when the environment was last deployed successfully.
*/
public var lastDeploymentSucceededAt: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The ID of the last successful deployment of this environment.
*/
public var lastSucceededDeploymentId: kotlin.String? = null
/**
* The name of the environment.
*/
public var name: kotlin.String? = null
/**
* The Amazon Resource Name (ARN) of the Proton service role that allows Proton to make calls to other services on your behalf.
*/
public var protonServiceRoleArn: kotlin.String? = null
/**
* When included, indicates that the environment template is for customer provisioned and managed infrastructure.
*/
public var provisioning: aws.sdk.kotlin.services.proton.model.Provisioning? = null
/**
* The major version of the environment template.
*/
public var templateMajorVersion: kotlin.String? = null
/**
* The minor version of the environment template.
*/
public var templateMinorVersion: kotlin.String? = null
/**
* The name of the environment template.
*/
public var templateName: kotlin.String? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.proton.model.EnvironmentSummary) : this() {
this.arn = x.arn
this.componentRoleArn = x.componentRoleArn
this.createdAt = x.createdAt
this.deploymentStatus = x.deploymentStatus
this.deploymentStatusMessage = x.deploymentStatusMessage
this.description = x.description
this.environmentAccountConnectionId = x.environmentAccountConnectionId
this.environmentAccountId = x.environmentAccountId
this.lastAttemptedDeploymentId = x.lastAttemptedDeploymentId
this.lastDeploymentAttemptedAt = x.lastDeploymentAttemptedAt
this.lastDeploymentSucceededAt = x.lastDeploymentSucceededAt
this.lastSucceededDeploymentId = x.lastSucceededDeploymentId
this.name = x.name
this.protonServiceRoleArn = x.protonServiceRoleArn
this.provisioning = x.provisioning
this.templateMajorVersion = x.templateMajorVersion
this.templateMinorVersion = x.templateMinorVersion
this.templateName = x.templateName
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.proton.model.EnvironmentSummary = EnvironmentSummary(this)
internal fun correctErrors(): Builder {
if (arn == null) arn = ""
if (createdAt == null) createdAt = Instant.fromEpochSeconds(0)
if (deploymentStatus == null) deploymentStatus = DeploymentStatus.SdkUnknown("no value provided")
if (lastDeploymentAttemptedAt == null) lastDeploymentAttemptedAt = Instant.fromEpochSeconds(0)
if (lastDeploymentSucceededAt == null) lastDeploymentSucceededAt = Instant.fromEpochSeconds(0)
if (name == null) name = ""
if (templateMajorVersion == null) templateMajorVersion = ""
if (templateMinorVersion == null) templateMinorVersion = ""
if (templateName == null) templateName = ""
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy