
commonMain.aws.sdk.kotlin.services.swf.model.ActivityTaskCanceledEventAttributes.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
/**
* Provides the details of the `ActivityTaskCanceled` event.
*/
public class ActivityTaskCanceledEventAttributes private constructor(builder: Builder) {
/**
* Details of the cancellation.
*/
public val details: kotlin.String? = builder.details
/**
* If set, contains the ID of the last `ActivityTaskCancelRequested` event recorded for this activity task. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public val latestCancelRequestedEventId: kotlin.Long = builder.latestCancelRequestedEventId
/**
* The ID of the `ActivityTaskScheduled` event that was recorded when this activity task was scheduled. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public val scheduledEventId: kotlin.Long = builder.scheduledEventId
/**
* The ID of the `ActivityTaskStarted` event recorded when this activity task was started. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public val startedEventId: kotlin.Long = builder.startedEventId
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.swf.model.ActivityTaskCanceledEventAttributes = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ActivityTaskCanceledEventAttributes(")
append("details=$details,")
append("latestCancelRequestedEventId=$latestCancelRequestedEventId,")
append("scheduledEventId=$scheduledEventId,")
append("startedEventId=$startedEventId")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = details?.hashCode() ?: 0
result = 31 * result + (latestCancelRequestedEventId.hashCode())
result = 31 * result + (scheduledEventId.hashCode())
result = 31 * result + (startedEventId.hashCode())
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 ActivityTaskCanceledEventAttributes
if (details != other.details) return false
if (latestCancelRequestedEventId != other.latestCancelRequestedEventId) return false
if (scheduledEventId != other.scheduledEventId) return false
if (startedEventId != other.startedEventId) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.swf.model.ActivityTaskCanceledEventAttributes = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* Details of the cancellation.
*/
public var details: kotlin.String? = null
/**
* If set, contains the ID of the last `ActivityTaskCancelRequested` event recorded for this activity task. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public var latestCancelRequestedEventId: kotlin.Long = 0L
/**
* The ID of the `ActivityTaskScheduled` event that was recorded when this activity task was scheduled. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public var scheduledEventId: kotlin.Long = 0L
/**
* The ID of the `ActivityTaskStarted` event recorded when this activity task was started. This information can be useful for diagnosing problems by tracing back the chain of events leading up to this event.
*/
public var startedEventId: kotlin.Long = 0L
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.swf.model.ActivityTaskCanceledEventAttributes) : this() {
this.details = x.details
this.latestCancelRequestedEventId = x.latestCancelRequestedEventId
this.scheduledEventId = x.scheduledEventId
this.startedEventId = x.startedEventId
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.swf.model.ActivityTaskCanceledEventAttributes = ActivityTaskCanceledEventAttributes(this)
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy