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

commonMain.aws.sdk.kotlin.services.iot.model.DescribeMitigationActionResponse.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.iot.model

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

public class DescribeMitigationActionResponse private constructor(builder: Builder) {
    /**
     * The ARN that identifies this migration action.
     */
    public val actionArn: kotlin.String? = builder.actionArn
    /**
     * A unique identifier for this action.
     */
    public val actionId: kotlin.String? = builder.actionId
    /**
     * The friendly name that uniquely identifies the mitigation action.
     */
    public val actionName: kotlin.String? = builder.actionName
    /**
     * Parameters that control how the mitigation action is applied, specific to the type of mitigation action.
     */
    public val actionParams: aws.sdk.kotlin.services.iot.model.MitigationActionParams? = builder.actionParams
    /**
     * The type of mitigation action.
     */
    public val actionType: aws.sdk.kotlin.services.iot.model.MitigationActionType? = builder.actionType
    /**
     * The date and time when the mitigation action was added to your Amazon Web Services accounts.
     */
    public val creationDate: aws.smithy.kotlin.runtime.time.Instant? = builder.creationDate
    /**
     * The date and time when the mitigation action was last changed.
     */
    public val lastModifiedDate: aws.smithy.kotlin.runtime.time.Instant? = builder.lastModifiedDate
    /**
     * The ARN of the IAM role used to apply this action.
     */
    public val roleArn: kotlin.String? = builder.roleArn

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

    override fun toString(): kotlin.String = buildString {
        append("DescribeMitigationActionResponse(")
        append("actionArn=$actionArn,")
        append("actionId=$actionId,")
        append("actionName=$actionName,")
        append("actionParams=$actionParams,")
        append("actionType=$actionType,")
        append("creationDate=$creationDate,")
        append("lastModifiedDate=$lastModifiedDate,")
        append("roleArn=$roleArn")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = actionArn?.hashCode() ?: 0
        result = 31 * result + (actionId?.hashCode() ?: 0)
        result = 31 * result + (actionName?.hashCode() ?: 0)
        result = 31 * result + (actionParams?.hashCode() ?: 0)
        result = 31 * result + (actionType?.hashCode() ?: 0)
        result = 31 * result + (creationDate?.hashCode() ?: 0)
        result = 31 * result + (lastModifiedDate?.hashCode() ?: 0)
        result = 31 * result + (roleArn?.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 DescribeMitigationActionResponse

        if (actionArn != other.actionArn) return false
        if (actionId != other.actionId) return false
        if (actionName != other.actionName) return false
        if (actionParams != other.actionParams) return false
        if (actionType != other.actionType) return false
        if (creationDate != other.creationDate) return false
        if (lastModifiedDate != other.lastModifiedDate) return false
        if (roleArn != other.roleArn) return false

        return true
    }

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

    public class Builder {
        /**
         * The ARN that identifies this migration action.
         */
        public var actionArn: kotlin.String? = null
        /**
         * A unique identifier for this action.
         */
        public var actionId: kotlin.String? = null
        /**
         * The friendly name that uniquely identifies the mitigation action.
         */
        public var actionName: kotlin.String? = null
        /**
         * Parameters that control how the mitigation action is applied, specific to the type of mitigation action.
         */
        public var actionParams: aws.sdk.kotlin.services.iot.model.MitigationActionParams? = null
        /**
         * The type of mitigation action.
         */
        public var actionType: aws.sdk.kotlin.services.iot.model.MitigationActionType? = null
        /**
         * The date and time when the mitigation action was added to your Amazon Web Services accounts.
         */
        public var creationDate: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The date and time when the mitigation action was last changed.
         */
        public var lastModifiedDate: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The ARN of the IAM role used to apply this action.
         */
        public var roleArn: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.iot.model.DescribeMitigationActionResponse) : this() {
            this.actionArn = x.actionArn
            this.actionId = x.actionId
            this.actionName = x.actionName
            this.actionParams = x.actionParams
            this.actionType = x.actionType
            this.creationDate = x.creationDate
            this.lastModifiedDate = x.lastModifiedDate
            this.roleArn = x.roleArn
        }

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

        /**
         * construct an [aws.sdk.kotlin.services.iot.model.MitigationActionParams] inside the given [block]
         */
        public fun actionParams(block: aws.sdk.kotlin.services.iot.model.MitigationActionParams.Builder.() -> kotlin.Unit) {
            this.actionParams = aws.sdk.kotlin.services.iot.model.MitigationActionParams.invoke(block)
        }

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy