zio.aws.tnb.model.GetSolNetworkPackageMetadata.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zio-aws-tnb_3 Show documentation
Show all versions of zio-aws-tnb_3 Show documentation
Low-level AWS wrapper for ZIO
package zio.aws.tnb.model
import zio.aws.tnb.model.primitives.SyntheticTimestamp_date_time
import java.time.Instant
import zio.prelude.data.Optional
import zio.aws.core.{AwsError, BuilderHelper}
import zio.ZIO
import scala.jdk.CollectionConverters.*
final case class GetSolNetworkPackageMetadata(
createdAt: SyntheticTimestamp_date_time,
lastModified: SyntheticTimestamp_date_time,
nsd: Optional[zio.aws.tnb.model.NetworkArtifactMeta] = Optional.Absent
) {
def buildAwsValue()
: software.amazon.awssdk.services.tnb.model.GetSolNetworkPackageMetadata = {
import GetSolNetworkPackageMetadata.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.tnb.model.GetSolNetworkPackageMetadata
.builder()
.createdAt(SyntheticTimestamp_date_time.unwrap(createdAt): Instant)
.lastModified(SyntheticTimestamp_date_time.unwrap(lastModified): Instant)
.optionallyWith(nsd.map(value => value.buildAwsValue()))(_.nsd)
.build()
}
def asReadOnly: zio.aws.tnb.model.GetSolNetworkPackageMetadata.ReadOnly =
zio.aws.tnb.model.GetSolNetworkPackageMetadata.wrap(buildAwsValue())
}
object GetSolNetworkPackageMetadata {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.tnb.model.GetSolNetworkPackageMetadata
] = BuilderHelper.apply
trait ReadOnly {
def asEditable: zio.aws.tnb.model.GetSolNetworkPackageMetadata =
zio.aws.tnb.model.GetSolNetworkPackageMetadata(
createdAt,
lastModified,
nsd.map(value => value.asEditable)
)
def createdAt: SyntheticTimestamp_date_time
def lastModified: SyntheticTimestamp_date_time
def nsd: Optional[zio.aws.tnb.model.NetworkArtifactMeta.ReadOnly]
def getCreatedAt: ZIO[Any, Nothing, SyntheticTimestamp_date_time] =
ZIO.succeed(createdAt)
def getLastModified: ZIO[Any, Nothing, SyntheticTimestamp_date_time] =
ZIO.succeed(lastModified)
def getNsd
: ZIO[Any, AwsError, zio.aws.tnb.model.NetworkArtifactMeta.ReadOnly] =
AwsError.unwrapOptionField("nsd", nsd)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.tnb.model.GetSolNetworkPackageMetadata
) extends zio.aws.tnb.model.GetSolNetworkPackageMetadata.ReadOnly {
override val createdAt: SyntheticTimestamp_date_time =
zio.aws.tnb.model.primitives
.SyntheticTimestamp_date_time(impl.createdAt())
override val lastModified: SyntheticTimestamp_date_time =
zio.aws.tnb.model.primitives
.SyntheticTimestamp_date_time(impl.lastModified())
override val nsd: Optional[zio.aws.tnb.model.NetworkArtifactMeta.ReadOnly] =
zio.aws.core.internal
.optionalFromNullable(impl.nsd())
.map(value => zio.aws.tnb.model.NetworkArtifactMeta.wrap(value))
}
def wrap(
impl: software.amazon.awssdk.services.tnb.model.GetSolNetworkPackageMetadata
): zio.aws.tnb.model.GetSolNetworkPackageMetadata.ReadOnly = new Wrapper(impl)
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy