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

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

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

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

import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant

public class GetDocumentResponse private constructor(builder: Builder) {
    /**
     * A description of the document attachments, including names, locations, sizes, and so on.
     */
    public val attachmentsContent: List? = builder.attachmentsContent
    /**
     * The contents of the SSM document.
     */
    public val content: kotlin.String? = builder.content
    /**
     * The date the SSM document was created.
     */
    public val createdDate: aws.smithy.kotlin.runtime.time.Instant? = builder.createdDate
    /**
     * The friendly name of the SSM document. This value can differ for each version of the document. If you want to update this value, see UpdateDocument.
     */
    public val displayName: kotlin.String? = builder.displayName
    /**
     * The document format, either JSON or YAML.
     */
    public val documentFormat: aws.sdk.kotlin.services.ssm.model.DocumentFormat? = builder.documentFormat
    /**
     * The document type.
     */
    public val documentType: aws.sdk.kotlin.services.ssm.model.DocumentType? = builder.documentType
    /**
     * The document version.
     */
    public val documentVersion: kotlin.String? = builder.documentVersion
    /**
     * The name of the SSM document.
     */
    public val name: kotlin.String? = builder.name
    /**
     * A list of SSM documents required by a document. For example, an `ApplicationConfiguration` document requires an `ApplicationConfigurationSchema` document.
     */
    public val requires: List? = builder.requires
    /**
     * The current review status of a new custom Systems Manager document (SSM document) created by a member of your organization, or of the latest version of an existing SSM document.
     *
     * Only one version of an SSM document can be in the APPROVED state at a time. When a new version is approved, the status of the previous version changes to REJECTED.
     *
     * Only one version of an SSM document can be in review, or PENDING, at a time.
     */
    public val reviewStatus: aws.sdk.kotlin.services.ssm.model.ReviewStatus? = builder.reviewStatus
    /**
     * The status of the SSM document, such as `Creating`, `Active`, `Updating`, `Failed`, and `Deleting`.
     */
    public val status: aws.sdk.kotlin.services.ssm.model.DocumentStatus? = builder.status
    /**
     * A message returned by Amazon Web Services Systems Manager that explains the `Status` value. For example, a `Failed` status might be explained by the `StatusInformation` message, "The specified S3 bucket doesn't exist. Verify that the URL of the S3 bucket is correct."
     */
    public val statusInformation: kotlin.String? = builder.statusInformation
    /**
     * The version of the artifact associated with the document. For example, 12.6. This value is unique across all versions of a document, and can't be changed.
     */
    public val versionName: kotlin.String? = builder.versionName

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

    override fun toString(): kotlin.String = buildString {
        append("GetDocumentResponse(")
        append("attachmentsContent=$attachmentsContent,")
        append("content=$content,")
        append("createdDate=$createdDate,")
        append("displayName=$displayName,")
        append("documentFormat=$documentFormat,")
        append("documentType=$documentType,")
        append("documentVersion=$documentVersion,")
        append("name=$name,")
        append("requires=$requires,")
        append("reviewStatus=$reviewStatus,")
        append("status=$status,")
        append("statusInformation=$statusInformation,")
        append("versionName=$versionName")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = attachmentsContent?.hashCode() ?: 0
        result = 31 * result + (content?.hashCode() ?: 0)
        result = 31 * result + (createdDate?.hashCode() ?: 0)
        result = 31 * result + (displayName?.hashCode() ?: 0)
        result = 31 * result + (documentFormat?.hashCode() ?: 0)
        result = 31 * result + (documentType?.hashCode() ?: 0)
        result = 31 * result + (documentVersion?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (requires?.hashCode() ?: 0)
        result = 31 * result + (reviewStatus?.hashCode() ?: 0)
        result = 31 * result + (status?.hashCode() ?: 0)
        result = 31 * result + (statusInformation?.hashCode() ?: 0)
        result = 31 * result + (versionName?.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 GetDocumentResponse

        if (attachmentsContent != other.attachmentsContent) return false
        if (content != other.content) return false
        if (createdDate != other.createdDate) return false
        if (displayName != other.displayName) return false
        if (documentFormat != other.documentFormat) return false
        if (documentType != other.documentType) return false
        if (documentVersion != other.documentVersion) return false
        if (name != other.name) return false
        if (requires != other.requires) return false
        if (reviewStatus != other.reviewStatus) return false
        if (status != other.status) return false
        if (statusInformation != other.statusInformation) return false
        if (versionName != other.versionName) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * A description of the document attachments, including names, locations, sizes, and so on.
         */
        public var attachmentsContent: List? = null
        /**
         * The contents of the SSM document.
         */
        public var content: kotlin.String? = null
        /**
         * The date the SSM document was created.
         */
        public var createdDate: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The friendly name of the SSM document. This value can differ for each version of the document. If you want to update this value, see UpdateDocument.
         */
        public var displayName: kotlin.String? = null
        /**
         * The document format, either JSON or YAML.
         */
        public var documentFormat: aws.sdk.kotlin.services.ssm.model.DocumentFormat? = null
        /**
         * The document type.
         */
        public var documentType: aws.sdk.kotlin.services.ssm.model.DocumentType? = null
        /**
         * The document version.
         */
        public var documentVersion: kotlin.String? = null
        /**
         * The name of the SSM document.
         */
        public var name: kotlin.String? = null
        /**
         * A list of SSM documents required by a document. For example, an `ApplicationConfiguration` document requires an `ApplicationConfigurationSchema` document.
         */
        public var requires: List? = null
        /**
         * The current review status of a new custom Systems Manager document (SSM document) created by a member of your organization, or of the latest version of an existing SSM document.
         *
         * Only one version of an SSM document can be in the APPROVED state at a time. When a new version is approved, the status of the previous version changes to REJECTED.
         *
         * Only one version of an SSM document can be in review, or PENDING, at a time.
         */
        public var reviewStatus: aws.sdk.kotlin.services.ssm.model.ReviewStatus? = null
        /**
         * The status of the SSM document, such as `Creating`, `Active`, `Updating`, `Failed`, and `Deleting`.
         */
        public var status: aws.sdk.kotlin.services.ssm.model.DocumentStatus? = null
        /**
         * A message returned by Amazon Web Services Systems Manager that explains the `Status` value. For example, a `Failed` status might be explained by the `StatusInformation` message, "The specified S3 bucket doesn't exist. Verify that the URL of the S3 bucket is correct."
         */
        public var statusInformation: kotlin.String? = null
        /**
         * The version of the artifact associated with the document. For example, 12.6. This value is unique across all versions of a document, and can't be changed.
         */
        public var versionName: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.ssm.model.GetDocumentResponse) : this() {
            this.attachmentsContent = x.attachmentsContent
            this.content = x.content
            this.createdDate = x.createdDate
            this.displayName = x.displayName
            this.documentFormat = x.documentFormat
            this.documentType = x.documentType
            this.documentVersion = x.documentVersion
            this.name = x.name
            this.requires = x.requires
            this.reviewStatus = x.reviewStatus
            this.status = x.status
            this.statusInformation = x.statusInformation
            this.versionName = x.versionName
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy