{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Route53.Types.ReusableDelegationSetLimit where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.Route53.Internal
import Amazonka.Route53.Types.ReusableDelegationSetLimitType
data ReusableDelegationSetLimit = ReusableDelegationSetLimit'
{
ReusableDelegationSetLimit -> ReusableDelegationSetLimitType
type' :: ReusableDelegationSetLimitType,
ReusableDelegationSetLimit -> Natural
value :: Prelude.Natural
}
deriving (ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool
(ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool)
-> (ReusableDelegationSetLimit
-> ReusableDelegationSetLimit -> Bool)
-> Eq ReusableDelegationSetLimit
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool
$c/= :: ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool
== :: ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool
$c== :: ReusableDelegationSetLimit -> ReusableDelegationSetLimit -> Bool
Prelude.Eq, ReadPrec [ReusableDelegationSetLimit]
ReadPrec ReusableDelegationSetLimit
Int -> ReadS ReusableDelegationSetLimit
ReadS [ReusableDelegationSetLimit]
(Int -> ReadS ReusableDelegationSetLimit)
-> ReadS [ReusableDelegationSetLimit]
-> ReadPrec ReusableDelegationSetLimit
-> ReadPrec [ReusableDelegationSetLimit]
-> Read ReusableDelegationSetLimit
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ReusableDelegationSetLimit]
$creadListPrec :: ReadPrec [ReusableDelegationSetLimit]
readPrec :: ReadPrec ReusableDelegationSetLimit
$creadPrec :: ReadPrec ReusableDelegationSetLimit
readList :: ReadS [ReusableDelegationSetLimit]
$creadList :: ReadS [ReusableDelegationSetLimit]
readsPrec :: Int -> ReadS ReusableDelegationSetLimit
$creadsPrec :: Int -> ReadS ReusableDelegationSetLimit
Prelude.Read, Int -> ReusableDelegationSetLimit -> ShowS
[ReusableDelegationSetLimit] -> ShowS
ReusableDelegationSetLimit -> String
(Int -> ReusableDelegationSetLimit -> ShowS)
-> (ReusableDelegationSetLimit -> String)
-> ([ReusableDelegationSetLimit] -> ShowS)
-> Show ReusableDelegationSetLimit
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ReusableDelegationSetLimit] -> ShowS
$cshowList :: [ReusableDelegationSetLimit] -> ShowS
show :: ReusableDelegationSetLimit -> String
$cshow :: ReusableDelegationSetLimit -> String
showsPrec :: Int -> ReusableDelegationSetLimit -> ShowS
$cshowsPrec :: Int -> ReusableDelegationSetLimit -> ShowS
Prelude.Show, (forall x.
ReusableDelegationSetLimit -> Rep ReusableDelegationSetLimit x)
-> (forall x.
Rep ReusableDelegationSetLimit x -> ReusableDelegationSetLimit)
-> Generic ReusableDelegationSetLimit
forall x.
Rep ReusableDelegationSetLimit x -> ReusableDelegationSetLimit
forall x.
ReusableDelegationSetLimit -> Rep ReusableDelegationSetLimit x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ReusableDelegationSetLimit x -> ReusableDelegationSetLimit
$cfrom :: forall x.
ReusableDelegationSetLimit -> Rep ReusableDelegationSetLimit x
Prelude.Generic)
newReusableDelegationSetLimit ::
ReusableDelegationSetLimitType ->
Prelude.Natural ->
ReusableDelegationSetLimit
newReusableDelegationSetLimit :: ReusableDelegationSetLimitType
-> Natural -> ReusableDelegationSetLimit
newReusableDelegationSetLimit ReusableDelegationSetLimitType
pType_ Natural
pValue_ =
ReusableDelegationSetLimit' :: ReusableDelegationSetLimitType
-> Natural -> ReusableDelegationSetLimit
ReusableDelegationSetLimit'
{ $sel:type':ReusableDelegationSetLimit' :: ReusableDelegationSetLimitType
type' = ReusableDelegationSetLimitType
pType_,
$sel:value:ReusableDelegationSetLimit' :: Natural
value = Natural
pValue_
}
reusableDelegationSetLimit_type :: Lens.Lens' ReusableDelegationSetLimit ReusableDelegationSetLimitType
reusableDelegationSetLimit_type :: (ReusableDelegationSetLimitType
-> f ReusableDelegationSetLimitType)
-> ReusableDelegationSetLimit -> f ReusableDelegationSetLimit
reusableDelegationSetLimit_type = (ReusableDelegationSetLimit -> ReusableDelegationSetLimitType)
-> (ReusableDelegationSetLimit
-> ReusableDelegationSetLimitType -> ReusableDelegationSetLimit)
-> Lens
ReusableDelegationSetLimit
ReusableDelegationSetLimit
ReusableDelegationSetLimitType
ReusableDelegationSetLimitType
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReusableDelegationSetLimit' {ReusableDelegationSetLimitType
type' :: ReusableDelegationSetLimitType
$sel:type':ReusableDelegationSetLimit' :: ReusableDelegationSetLimit -> ReusableDelegationSetLimitType
type'} -> ReusableDelegationSetLimitType
type') (\s :: ReusableDelegationSetLimit
s@ReusableDelegationSetLimit' {} ReusableDelegationSetLimitType
a -> ReusableDelegationSetLimit
s {$sel:type':ReusableDelegationSetLimit' :: ReusableDelegationSetLimitType
type' = ReusableDelegationSetLimitType
a} :: ReusableDelegationSetLimit)
reusableDelegationSetLimit_value :: Lens.Lens' ReusableDelegationSetLimit Prelude.Natural
reusableDelegationSetLimit_value :: (Natural -> f Natural)
-> ReusableDelegationSetLimit -> f ReusableDelegationSetLimit
reusableDelegationSetLimit_value = (ReusableDelegationSetLimit -> Natural)
-> (ReusableDelegationSetLimit
-> Natural -> ReusableDelegationSetLimit)
-> Lens
ReusableDelegationSetLimit
ReusableDelegationSetLimit
Natural
Natural
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReusableDelegationSetLimit' {Natural
value :: Natural
$sel:value:ReusableDelegationSetLimit' :: ReusableDelegationSetLimit -> Natural
value} -> Natural
value) (\s :: ReusableDelegationSetLimit
s@ReusableDelegationSetLimit' {} Natural
a -> ReusableDelegationSetLimit
s {$sel:value:ReusableDelegationSetLimit' :: Natural
value = Natural
a} :: ReusableDelegationSetLimit)
instance Core.FromXML ReusableDelegationSetLimit where
parseXML :: [Node] -> Either String ReusableDelegationSetLimit
parseXML [Node]
x =
ReusableDelegationSetLimitType
-> Natural -> ReusableDelegationSetLimit
ReusableDelegationSetLimit'
(ReusableDelegationSetLimitType
-> Natural -> ReusableDelegationSetLimit)
-> Either String ReusableDelegationSetLimitType
-> Either String (Natural -> ReusableDelegationSetLimit)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String ReusableDelegationSetLimitType
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"Type") Either String (Natural -> ReusableDelegationSetLimit)
-> Either String Natural
-> Either String ReusableDelegationSetLimit
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Natural
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"Value")
instance Prelude.Hashable ReusableDelegationSetLimit
instance Prelude.NFData ReusableDelegationSetLimit