zio.aws.codecatalyst.model.ListWorkflowRunsResponse.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zio-aws-codecatalyst_3 Show documentation
Show all versions of zio-aws-codecatalyst_3 Show documentation
Low-level AWS wrapper for ZIO
The newest version!
package zio.aws.codecatalyst.model
import zio.ZIO
import zio.aws.core.{AwsError, BuilderHelper}
import zio.prelude.data.Optional
import scala.jdk.CollectionConverters.*
final case class ListWorkflowRunsResponse(
nextToken: Optional[String] = Optional.Absent,
items: Optional[Iterable[zio.aws.codecatalyst.model.WorkflowRunSummary]] =
Optional.Absent
) {
def buildAwsValue()
: software.amazon.awssdk.services.codecatalyst.model.ListWorkflowRunsResponse = {
import ListWorkflowRunsResponse.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.codecatalyst.model.ListWorkflowRunsResponse
.builder()
.optionallyWith(nextToken.map(value => value: java.lang.String))(
_.nextToken
)
.optionallyWith(
items.map(value =>
value.map { item =>
item.buildAwsValue()
}.asJavaCollection
)
)(_.items)
.build()
}
def asReadOnly: zio.aws.codecatalyst.model.ListWorkflowRunsResponse.ReadOnly =
zio.aws.codecatalyst.model.ListWorkflowRunsResponse.wrap(buildAwsValue())
}
object ListWorkflowRunsResponse {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.codecatalyst.model.ListWorkflowRunsResponse
] = BuilderHelper.apply
trait ReadOnly {
def asEditable: zio.aws.codecatalyst.model.ListWorkflowRunsResponse =
zio.aws.codecatalyst.model.ListWorkflowRunsResponse(
nextToken.map(value => value),
items.map(value =>
value.map { item =>
item.asEditable
}
)
)
def nextToken: Optional[String]
def items
: Optional[List[zio.aws.codecatalyst.model.WorkflowRunSummary.ReadOnly]]
def getNextToken: ZIO[Any, AwsError, String] =
AwsError.unwrapOptionField("nextToken", nextToken)
def getItems: ZIO[Any, AwsError, List[
zio.aws.codecatalyst.model.WorkflowRunSummary.ReadOnly
]] = AwsError.unwrapOptionField("items", items)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.codecatalyst.model.ListWorkflowRunsResponse
) extends zio.aws.codecatalyst.model.ListWorkflowRunsResponse.ReadOnly {
override val nextToken: Optional[String] = zio.aws.core.internal
.optionalFromNullable(impl.nextToken())
.map(value => value: String)
override val items: Optional[
List[zio.aws.codecatalyst.model.WorkflowRunSummary.ReadOnly]
] = zio.aws.core.internal
.optionalFromNullable(impl.items())
.map(value =>
value.asScala.map { item =>
zio.aws.codecatalyst.model.WorkflowRunSummary.wrap(item)
}.toList
)
}
def wrap(
impl: software.amazon.awssdk.services.codecatalyst.model.ListWorkflowRunsResponse
): zio.aws.codecatalyst.model.ListWorkflowRunsResponse.ReadOnly = new Wrapper(
impl
)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy