zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of zio-aws-emrcontainers_2.12 Show documentation
Show all versions of zio-aws-emrcontainers_2.12 Show documentation
Low-level AWS wrapper for ZIO
The newest version!
package zio.aws.emrcontainers.model
import zio.aws.emrcontainers.model.primitives.{NextToken, JavaInteger, Date}
import java.time.Instant
import zio.prelude.data.Optional
import zio.aws.core.{AwsError, BuilderHelper}
import zio.ZIO
import java.lang.Integer
import scala.jdk.CollectionConverters._
final case class ListSecurityConfigurationsRequest(
createdAfter: Optional[Date] = Optional.Absent,
createdBefore: Optional[Date] = Optional.Absent,
maxResults: Optional[JavaInteger] = Optional.Absent,
nextToken: Optional[NextToken] = Optional.Absent
) {
def buildAwsValue()
: software.amazon.awssdk.services.emrcontainers.model.ListSecurityConfigurationsRequest = {
import ListSecurityConfigurationsRequest.zioAwsBuilderHelper.BuilderOps
software.amazon.awssdk.services.emrcontainers.model.ListSecurityConfigurationsRequest
.builder()
.optionallyWith(createdAfter.map(value => Date.unwrap(value): Instant))(
_.createdAfter
)
.optionallyWith(createdBefore.map(value => Date.unwrap(value): Instant))(
_.createdBefore
)
.optionallyWith(
maxResults.map(value => JavaInteger.unwrap(value): Integer)
)(_.maxResults)
.optionallyWith(
nextToken.map(value => NextToken.unwrap(value): java.lang.String)
)(_.nextToken)
.build()
}
def asReadOnly
: zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest.ReadOnly =
zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest
.wrap(buildAwsValue())
}
object ListSecurityConfigurationsRequest {
private lazy val zioAwsBuilderHelper: BuilderHelper[
software.amazon.awssdk.services.emrcontainers.model.ListSecurityConfigurationsRequest
] = BuilderHelper.apply
trait ReadOnly {
def asEditable
: zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest =
zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest(
createdAfter.map(value => value),
createdBefore.map(value => value),
maxResults.map(value => value),
nextToken.map(value => value)
)
def createdAfter: Optional[Date]
def createdBefore: Optional[Date]
def maxResults: Optional[JavaInteger]
def nextToken: Optional[NextToken]
def getCreatedAfter: ZIO[Any, AwsError, Date] =
AwsError.unwrapOptionField("createdAfter", createdAfter)
def getCreatedBefore: ZIO[Any, AwsError, Date] =
AwsError.unwrapOptionField("createdBefore", createdBefore)
def getMaxResults: ZIO[Any, AwsError, JavaInteger] =
AwsError.unwrapOptionField("maxResults", maxResults)
def getNextToken: ZIO[Any, AwsError, NextToken] =
AwsError.unwrapOptionField("nextToken", nextToken)
}
private final class Wrapper(
impl: software.amazon.awssdk.services.emrcontainers.model.ListSecurityConfigurationsRequest
) extends zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest.ReadOnly {
override val createdAfter: Optional[Date] = zio.aws.core.internal
.optionalFromNullable(impl.createdAfter())
.map(value => zio.aws.emrcontainers.model.primitives.Date(value))
override val createdBefore: Optional[Date] = zio.aws.core.internal
.optionalFromNullable(impl.createdBefore())
.map(value => zio.aws.emrcontainers.model.primitives.Date(value))
override val maxResults: Optional[JavaInteger] = zio.aws.core.internal
.optionalFromNullable(impl.maxResults())
.map(value => zio.aws.emrcontainers.model.primitives.JavaInteger(value))
override val nextToken: Optional[NextToken] = zio.aws.core.internal
.optionalFromNullable(impl.nextToken())
.map(value => zio.aws.emrcontainers.model.primitives.NextToken(value))
}
def wrap(
impl: software.amazon.awssdk.services.emrcontainers.model.ListSecurityConfigurationsRequest
): zio.aws.emrcontainers.model.ListSecurityConfigurationsRequest.ReadOnly =
new Wrapper(impl)
}