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

commonMain.aws.sdk.kotlin.services.securityhub.model.ConfigurationPolicySummary.kt Maven / Gradle / Ivy

There is a newer version: 1.3.35
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.securityhub.model

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

/**
 * An object that contains the details of an Security Hub configuration policy that’s returned in a `ListConfigurationPolicies` request.
 */
public class ConfigurationPolicySummary private constructor(builder: Builder) {
    /**
     * The Amazon Resource Name (ARN) of the configuration policy.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * The description of the configuration policy.
     */
    public val description: kotlin.String? = builder.description
    /**
     * The universally unique identifier (UUID) of the configuration policy.
     */
    public val id: kotlin.String? = builder.id
    /**
     * The name of the configuration policy. Alphanumeric characters and the following ASCII characters are permitted: `-, ., !, *, /`.
     */
    public val name: kotlin.String? = builder.name
    /**
     * Indicates whether the service that the configuration policy applies to is enabled in the policy.
     */
    public val serviceEnabled: kotlin.Boolean? = builder.serviceEnabled
    /**
     * The date and time, in UTC and ISO 8601 format, that the configuration policy was last updated.
     */
    public val updatedAt: aws.smithy.kotlin.runtime.time.Instant? = builder.updatedAt

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

    override fun toString(): kotlin.String = buildString {
        append("ConfigurationPolicySummary(")
        append("arn=$arn,")
        append("description=$description,")
        append("id=$id,")
        append("name=$name,")
        append("serviceEnabled=$serviceEnabled,")
        append("updatedAt=$updatedAt")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (description?.hashCode() ?: 0)
        result = 31 * result + (id?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (serviceEnabled?.hashCode() ?: 0)
        result = 31 * result + (updatedAt?.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 ConfigurationPolicySummary

        if (arn != other.arn) return false
        if (description != other.description) return false
        if (id != other.id) return false
        if (name != other.name) return false
        if (serviceEnabled != other.serviceEnabled) return false
        if (updatedAt != other.updatedAt) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The Amazon Resource Name (ARN) of the configuration policy.
         */
        public var arn: kotlin.String? = null
        /**
         * The description of the configuration policy.
         */
        public var description: kotlin.String? = null
        /**
         * The universally unique identifier (UUID) of the configuration policy.
         */
        public var id: kotlin.String? = null
        /**
         * The name of the configuration policy. Alphanumeric characters and the following ASCII characters are permitted: `-, ., !, *, /`.
         */
        public var name: kotlin.String? = null
        /**
         * Indicates whether the service that the configuration policy applies to is enabled in the policy.
         */
        public var serviceEnabled: kotlin.Boolean? = null
        /**
         * The date and time, in UTC and ISO 8601 format, that the configuration policy was last updated.
         */
        public var updatedAt: aws.smithy.kotlin.runtime.time.Instant? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.securityhub.model.ConfigurationPolicySummary) : this() {
            this.arn = x.arn
            this.description = x.description
            this.id = x.id
            this.name = x.name
            this.serviceEnabled = x.serviceEnabled
            this.updatedAt = x.updatedAt
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy