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

commonMain.aws.sdk.kotlin.services.swf.model.RespondActivityTaskCompletedRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.swf.model

import aws.smithy.kotlin.runtime.SdkDsl

public class RespondActivityTaskCompletedRequest private constructor(builder: Builder) {
    /**
     * The result of the activity task. It is a free form string that is implementation specific.
     */
    public val result: kotlin.String? = builder.result
    /**
     * The `taskToken` of the ActivityTask.
     *
     * `taskToken` is generated by the service and should be treated as an opaque value. If the task is passed to another process, its `taskToken` must also be passed. This enables it to provide its progress and respond with results.
     */
    public val taskToken: kotlin.String? = builder.taskToken

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

    override fun toString(): kotlin.String = buildString {
        append("RespondActivityTaskCompletedRequest(")
        append("result=$result,")
        append("taskToken=$taskToken")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = result?.hashCode() ?: 0
        result = 31 * result + (taskToken?.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 RespondActivityTaskCompletedRequest

        if (result != other.result) return false
        if (taskToken != other.taskToken) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The result of the activity task. It is a free form string that is implementation specific.
         */
        public var result: kotlin.String? = null
        /**
         * The `taskToken` of the ActivityTask.
         *
         * `taskToken` is generated by the service and should be treated as an opaque value. If the task is passed to another process, its `taskToken` must also be passed. This enables it to provide its progress and respond with results.
         */
        public var taskToken: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.swf.model.RespondActivityTaskCompletedRequest) : this() {
            this.result = x.result
            this.taskToken = x.taskToken
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy