zio.aws.codecatalyst.model.ProjectInformation.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 ProjectInformation(
name: Optional[String] = Optional.Absent,
projectId: Optional[String] = Optional.Absent
) {
def buildAwsValue()
: software.amazon.awssdk.services.codecatalyst.model.ProjectInformation = {
import ProjectInformation.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.codecatalyst.model.ProjectInformation
.builder()
.optionallyWith(name.map(value => value: java.lang.String))(_.name)
.optionallyWith(projectId.map(value => value: java.lang.String))(
_.projectId
)
.build()
}
def asReadOnly: zio.aws.codecatalyst.model.ProjectInformation.ReadOnly =
zio.aws.codecatalyst.model.ProjectInformation.wrap(buildAwsValue())
}
object ProjectInformation {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.codecatalyst.model.ProjectInformation
] = BuilderHelper.apply
trait ReadOnly {
def asEditable: zio.aws.codecatalyst.model.ProjectInformation =
zio.aws.codecatalyst.model.ProjectInformation(
name.map(value => value),
projectId.map(value => value)
)
def name: Optional[String]
def projectId: Optional[String]
def getName: ZIO[Any, AwsError, String] =
AwsError.unwrapOptionField("name", name)
def getProjectId: ZIO[Any, AwsError, String] =
AwsError.unwrapOptionField("projectId", projectId)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.codecatalyst.model.ProjectInformation
) extends zio.aws.codecatalyst.model.ProjectInformation.ReadOnly {
override val name: Optional[String] = zio.aws.core.internal
.optionalFromNullable(impl.name())
.map(value => value: String)
override val projectId: Optional[String] = zio.aws.core.internal
.optionalFromNullable(impl.projectId())
.map(value => value: String)
}
def wrap(
impl: software.amazon.awssdk.services.codecatalyst.model.ProjectInformation
): zio.aws.codecatalyst.model.ProjectInformation.ReadOnly = new Wrapper(impl)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy