zio.aws.amplifybackend.model.CreateBackendApiResponse.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zio-aws-amplifybackend_3 Show documentation
Show all versions of zio-aws-amplifybackend_3 Show documentation
Low-level AWS wrapper for ZIO
package zio.aws.amplifybackend.model
import zio.aws.amplifybackend.model.primitives.__string
import zio.ZIO
import zio.aws.core.{AwsError, BuilderHelper}
import zio.prelude.data.Optional
import scala.jdk.CollectionConverters.*
final case class CreateBackendApiResponse(
appId: Optional[__string] = Optional.Absent,
backendEnvironmentName: Optional[__string] = Optional.Absent,
error: Optional[__string] = Optional.Absent,
jobId: Optional[__string] = Optional.Absent,
operation: Optional[__string] = Optional.Absent,
status: Optional[__string] = Optional.Absent
) {
def buildAwsValue()
: software.amazon.awssdk.services.amplifybackend.model.CreateBackendApiResponse = {
import CreateBackendApiResponse.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.amplifybackend.model.CreateBackendApiResponse
.builder()
.optionallyWith(appId.map(value => value: java.lang.String))(_.appId)
.optionallyWith(
backendEnvironmentName.map(value => value: java.lang.String)
)(_.backendEnvironmentName)
.optionallyWith(error.map(value => value: java.lang.String))(_.error)
.optionallyWith(jobId.map(value => value: java.lang.String))(_.jobId)
.optionallyWith(operation.map(value => value: java.lang.String))(
_.operation
)
.optionallyWith(status.map(value => value: java.lang.String))(_.status)
.build()
}
def asReadOnly
: zio.aws.amplifybackend.model.CreateBackendApiResponse.ReadOnly =
zio.aws.amplifybackend.model.CreateBackendApiResponse.wrap(buildAwsValue())
}
object CreateBackendApiResponse {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.amplifybackend.model.CreateBackendApiResponse
] = BuilderHelper.apply
trait ReadOnly {
def asEditable: zio.aws.amplifybackend.model.CreateBackendApiResponse =
zio.aws.amplifybackend.model.CreateBackendApiResponse(
appId.map(value => value),
backendEnvironmentName.map(value => value),
error.map(value => value),
jobId.map(value => value),
operation.map(value => value),
status.map(value => value)
)
def appId: Optional[__string]
def backendEnvironmentName: Optional[__string]
def error: Optional[__string]
def jobId: Optional[__string]
def operation: Optional[__string]
def status: Optional[__string]
def getAppId: ZIO[Any, AwsError, __string] =
AwsError.unwrapOptionField("appId", appId)
def getBackendEnvironmentName: ZIO[Any, AwsError, __string] = AwsError
.unwrapOptionField("backendEnvironmentName", backendEnvironmentName)
def getError: ZIO[Any, AwsError, __string] =
AwsError.unwrapOptionField("error", error)
def getJobId: ZIO[Any, AwsError, __string] =
AwsError.unwrapOptionField("jobId", jobId)
def getOperation: ZIO[Any, AwsError, __string] =
AwsError.unwrapOptionField("operation", operation)
def getStatus: ZIO[Any, AwsError, __string] =
AwsError.unwrapOptionField("status", status)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.amplifybackend.model.CreateBackendApiResponse
) extends zio.aws.amplifybackend.model.CreateBackendApiResponse.ReadOnly {
override val appId: Optional[__string] = zio.aws.core.internal
.optionalFromNullable(impl.appId())
.map(value => value: __string)
override val backendEnvironmentName: Optional[__string] =
zio.aws.core.internal
.optionalFromNullable(impl.backendEnvironmentName())
.map(value => value: __string)
override val error: Optional[__string] = zio.aws.core.internal
.optionalFromNullable(impl.error())
.map(value => value: __string)
override val jobId: Optional[__string] = zio.aws.core.internal
.optionalFromNullable(impl.jobId())
.map(value => value: __string)
override val operation: Optional[__string] = zio.aws.core.internal
.optionalFromNullable(impl.operation())
.map(value => value: __string)
override val status: Optional[__string] = zio.aws.core.internal
.optionalFromNullable(impl.status())
.map(value => value: __string)
}
def wrap(
impl: software.amazon.awssdk.services.amplifybackend.model.CreateBackendApiResponse
): zio.aws.amplifybackend.model.CreateBackendApiResponse.ReadOnly =
new Wrapper(impl)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy