
commonMain.aws.sdk.kotlin.services.fis.model.ExperimentAction.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.fis.model
import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant
/**
* Describes the action for an experiment.
*/
public class ExperimentAction private constructor(builder: Builder) {
/**
* The ID of the action.
*/
public val actionId: kotlin.String? = builder.actionId
/**
* The description for the action.
*/
public val description: kotlin.String? = builder.description
/**
* The time that the action ended.
*/
public val endTime: aws.smithy.kotlin.runtime.time.Instant? = builder.endTime
/**
* The parameters for the action.
*/
public val parameters: Map? = builder.parameters
/**
* The name of the action that must be completed before this action starts.
*/
public val startAfter: List? = builder.startAfter
/**
* The time that the action started.
*/
public val startTime: aws.smithy.kotlin.runtime.time.Instant? = builder.startTime
/**
* The state of the action.
*/
public val state: aws.sdk.kotlin.services.fis.model.ExperimentActionState? = builder.state
/**
* The targets for the action.
*/
public val targets: Map? = builder.targets
public companion object {
public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.fis.model.ExperimentAction = Builder().apply(block).build()
}
override fun toString(): kotlin.String = buildString {
append("ExperimentAction(")
append("actionId=$actionId,")
append("description=$description,")
append("endTime=$endTime,")
append("parameters=$parameters,")
append("startAfter=$startAfter,")
append("startTime=$startTime,")
append("state=$state,")
append("targets=$targets")
append(")")
}
override fun hashCode(): kotlin.Int {
var result = actionId?.hashCode() ?: 0
result = 31 * result + (description?.hashCode() ?: 0)
result = 31 * result + (endTime?.hashCode() ?: 0)
result = 31 * result + (parameters?.hashCode() ?: 0)
result = 31 * result + (startAfter?.hashCode() ?: 0)
result = 31 * result + (startTime?.hashCode() ?: 0)
result = 31 * result + (state?.hashCode() ?: 0)
result = 31 * result + (targets?.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 ExperimentAction
if (actionId != other.actionId) return false
if (description != other.description) return false
if (endTime != other.endTime) return false
if (parameters != other.parameters) return false
if (startAfter != other.startAfter) return false
if (startTime != other.startTime) return false
if (state != other.state) return false
if (targets != other.targets) return false
return true
}
public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.fis.model.ExperimentAction = Builder(this).apply(block).build()
@SdkDsl
public class Builder {
/**
* The ID of the action.
*/
public var actionId: kotlin.String? = null
/**
* The description for the action.
*/
public var description: kotlin.String? = null
/**
* The time that the action ended.
*/
public var endTime: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The parameters for the action.
*/
public var parameters: Map? = null
/**
* The name of the action that must be completed before this action starts.
*/
public var startAfter: List? = null
/**
* The time that the action started.
*/
public var startTime: aws.smithy.kotlin.runtime.time.Instant? = null
/**
* The state of the action.
*/
public var state: aws.sdk.kotlin.services.fis.model.ExperimentActionState? = null
/**
* The targets for the action.
*/
public var targets: Map? = null
@PublishedApi
internal constructor()
@PublishedApi
internal constructor(x: aws.sdk.kotlin.services.fis.model.ExperimentAction) : this() {
this.actionId = x.actionId
this.description = x.description
this.endTime = x.endTime
this.parameters = x.parameters
this.startAfter = x.startAfter
this.startTime = x.startTime
this.state = x.state
this.targets = x.targets
}
@PublishedApi
internal fun build(): aws.sdk.kotlin.services.fis.model.ExperimentAction = ExperimentAction(this)
/**
* construct an [aws.sdk.kotlin.services.fis.model.ExperimentActionState] inside the given [block]
*/
public fun state(block: aws.sdk.kotlin.services.fis.model.ExperimentActionState.Builder.() -> kotlin.Unit) {
this.state = aws.sdk.kotlin.services.fis.model.ExperimentActionState.invoke(block)
}
internal fun correctErrors(): Builder {
return this
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy