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

commonMain.aws.sdk.kotlin.services.auditmanager.model.AssessmentControl.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.auditmanager.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * The control entity that represents a standard control or a custom control in an Audit Manager assessment.
 */
public class AssessmentControl private constructor(builder: Builder) {
    /**
     * The amount of evidence in the assessment report.
     */
    public val assessmentReportEvidenceCount: kotlin.Int = builder.assessmentReportEvidenceCount
    /**
     * The list of comments that's attached to the control.
     */
    public val comments: List? = builder.comments
    /**
     * The description of the control.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The amount of evidence that's collected for the control.
     */
    public val evidenceCount: kotlin.Int = builder.evidenceCount
    /**
     * The list of data sources for the evidence.
     */
    public val evidenceSources: List? = builder.evidenceSources
    /**
     * The identifier for the control.
     */
    public val id: kotlin.String? = builder.id
    /**
     * The name of the control.
     */
    public val name: kotlin.String? = builder.name
    /**
     * The response of the control.
     */
    public val response: aws.sdk.kotlin.services.auditmanager.model.ControlResponse? = builder.response
    /**
     * The status of the control.
     */
    public val status: aws.sdk.kotlin.services.auditmanager.model.ControlStatus? = builder.status

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

    override fun toString(): kotlin.String = buildString {
        append("AssessmentControl(")
        append("assessmentReportEvidenceCount=$assessmentReportEvidenceCount,")
        append("comments=$comments,")
        append("description=*** Sensitive Data Redacted ***,")
        append("evidenceCount=$evidenceCount,")
        append("evidenceSources=$evidenceSources,")
        append("id=$id,")
        append("name=$name,")
        append("response=$response,")
        append("status=$status")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = assessmentReportEvidenceCount
        result = 31 * result + (comments?.hashCode() ?: 0)
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (evidenceCount)
        result = 31 * result + (evidenceSources?.hashCode() ?: 0)
        result = 31 * result + (id?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (response?.hashCode() ?: 0)
        result = 31 * result + (status?.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 AssessmentControl

        if (assessmentReportEvidenceCount != other.assessmentReportEvidenceCount) return false
        if (comments != other.comments) return false
        if (description != other.description) return false
        if (evidenceCount != other.evidenceCount) return false
        if (evidenceSources != other.evidenceSources) return false
        if (id != other.id) return false
        if (name != other.name) return false
        if (response != other.response) return false
        if (status != other.status) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The amount of evidence in the assessment report.
         */
        public var assessmentReportEvidenceCount: kotlin.Int = 0
        /**
         * The list of comments that's attached to the control.
         */
        public var comments: List? = null
        /**
         * The description of the control.
         */
        public var description: kotlin.String? = null
        /**
         * The amount of evidence that's collected for the control.
         */
        public var evidenceCount: kotlin.Int = 0
        /**
         * The list of data sources for the evidence.
         */
        public var evidenceSources: List? = null
        /**
         * The identifier for the control.
         */
        public var id: kotlin.String? = null
        /**
         * The name of the control.
         */
        public var name: kotlin.String? = null
        /**
         * The response of the control.
         */
        public var response: aws.sdk.kotlin.services.auditmanager.model.ControlResponse? = null
        /**
         * The status of the control.
         */
        public var status: aws.sdk.kotlin.services.auditmanager.model.ControlStatus? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.auditmanager.model.AssessmentControl) : this() {
            this.assessmentReportEvidenceCount = x.assessmentReportEvidenceCount
            this.comments = x.comments
            this.description = x.description
            this.evidenceCount = x.evidenceCount
            this.evidenceSources = x.evidenceSources
            this.id = x.id
            this.name = x.name
            this.response = x.response
            this.status = x.status
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy