zio.aws.nimble.model.DeleteStudioComponentRequest.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zio-aws-nimble_3 Show documentation
Show all versions of zio-aws-nimble_3 Show documentation
Low-level AWS wrapper for ZIO
package zio.aws.nimble.model
import zio.aws.nimble.model.primitives.ClientToken
import zio.ZIO
import zio.aws.core.{AwsError, BuilderHelper}
import zio.prelude.data.Optional
import scala.jdk.CollectionConverters.*
final case class DeleteStudioComponentRequest(
clientToken: Optional[ClientToken] = Optional.Absent,
studioComponentId: String,
studioId: String
) {
def buildAwsValue()
: software.amazon.awssdk.services.nimble.model.DeleteStudioComponentRequest = {
import DeleteStudioComponentRequest.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.nimble.model.DeleteStudioComponentRequest
.builder()
.optionallyWith(
clientToken.map(value => ClientToken.unwrap(value): java.lang.String)
)(_.clientToken)
.studioComponentId(studioComponentId: java.lang.String)
.studioId(studioId: java.lang.String)
.build()
}
def asReadOnly: zio.aws.nimble.model.DeleteStudioComponentRequest.ReadOnly =
zio.aws.nimble.model.DeleteStudioComponentRequest.wrap(buildAwsValue())
}
object DeleteStudioComponentRequest {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.nimble.model.DeleteStudioComponentRequest
] = BuilderHelper.apply
trait ReadOnly {
def asEditable: zio.aws.nimble.model.DeleteStudioComponentRequest =
zio.aws.nimble.model.DeleteStudioComponentRequest(
clientToken.map(value => value),
studioComponentId,
studioId
)
def clientToken: Optional[ClientToken]
def studioComponentId: String
def studioId: String
def getClientToken: ZIO[Any, AwsError, ClientToken] =
AwsError.unwrapOptionField("clientToken", clientToken)
def getStudioComponentId: ZIO[Any, Nothing, String] =
ZIO.succeed(studioComponentId)
def getStudioId: ZIO[Any, Nothing, String] = ZIO.succeed(studioId)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.nimble.model.DeleteStudioComponentRequest
) extends zio.aws.nimble.model.DeleteStudioComponentRequest.ReadOnly {
override val clientToken: Optional[ClientToken] = zio.aws.core.internal
.optionalFromNullable(impl.clientToken())
.map(value => zio.aws.nimble.model.primitives.ClientToken(value))
override val studioComponentId: String = impl.studioComponentId(): String
override val studioId: String = impl.studioId(): String
}
def wrap(
impl: software.amazon.awssdk.services.nimble.model.DeleteStudioComponentRequest
): zio.aws.nimble.model.DeleteStudioComponentRequest.ReadOnly = new Wrapper(
impl
)
}