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

io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes.scala Maven / Gradle / Ivy

package io.github.vigoo.zioaws.swf.model
import zio.ZIO
import io.github.vigoo.zioaws.swf.model.primitives.{EventId, TimerId}
import io.github.vigoo.zioaws.core.BuilderHelper
import scala.jdk.CollectionConverters._
final case class StartTimerFailedEventAttributes(
    timerId: TimerId,
    cause: io.github.vigoo.zioaws.swf.model.StartTimerFailedCause,
    decisionTaskCompletedEventId: EventId
) {
  def buildAwsValue()
      : software.amazon.awssdk.services.swf.model.StartTimerFailedEventAttributes = {
    import StartTimerFailedEventAttributes.zioAwsBuilderHelper.BuilderOps
    software.amazon.awssdk.services.swf.model.StartTimerFailedEventAttributes
      .builder()
      .timerId(timerId: java.lang.String)
      .cause(cause.unwrap)
      .decisionTaskCompletedEventId(
        decisionTaskCompletedEventId: java.lang.Long
      )
      .build()
  }
  def asReadOnly
      : io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes.ReadOnly =
    io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes
      .wrap(buildAwsValue())
}
object StartTimerFailedEventAttributes {
  private lazy val zioAwsBuilderHelper: BuilderHelper[
    software.amazon.awssdk.services.swf.model.StartTimerFailedEventAttributes
  ] = BuilderHelper.apply
  trait ReadOnly {
    def editable
        : io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes =
      io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes(
        timerIdValue,
        causeValue,
        decisionTaskCompletedEventIdValue
      )
    def timerIdValue: TimerId
    def causeValue: io.github.vigoo.zioaws.swf.model.StartTimerFailedCause
    def decisionTaskCompletedEventIdValue: EventId
    def timerId: ZIO[Any, Nothing, TimerId] = ZIO.succeed(timerIdValue)
    def cause: ZIO[
      Any,
      Nothing,
      io.github.vigoo.zioaws.swf.model.StartTimerFailedCause
    ] = ZIO.succeed(causeValue)
    def decisionTaskCompletedEventId: ZIO[Any, Nothing, EventId] =
      ZIO.succeed(decisionTaskCompletedEventIdValue)
  }
  private class Wrapper(
      impl: software.amazon.awssdk.services.swf.model.StartTimerFailedEventAttributes
  ) extends io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes.ReadOnly {
    override def timerIdValue: TimerId = impl.timerId(): TimerId
    override def causeValue
        : io.github.vigoo.zioaws.swf.model.StartTimerFailedCause =
      io.github.vigoo.zioaws.swf.model.StartTimerFailedCause.wrap(impl.cause())
    override def decisionTaskCompletedEventIdValue: EventId =
      impl.decisionTaskCompletedEventId(): EventId
  }
  def wrap(
      impl: software.amazon.awssdk.services.swf.model.StartTimerFailedEventAttributes
  ): io.github.vigoo.zioaws.swf.model.StartTimerFailedEventAttributes.ReadOnly =
    new Wrapper(impl)
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy