module Stratosphere.Backup.BackupVault.LockConfigurationTypeProperty (
LockConfigurationTypeProperty(..), mkLockConfigurationTypeProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data LockConfigurationTypeProperty
=
LockConfigurationTypeProperty {LockConfigurationTypeProperty -> ()
haddock_workaround_ :: (),
LockConfigurationTypeProperty -> Maybe (Value Integer)
changeableForDays :: (Prelude.Maybe (Value Prelude.Integer)),
LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: (Prelude.Maybe (Value Prelude.Integer)),
LockConfigurationTypeProperty -> Value Integer
minRetentionDays :: (Value Prelude.Integer)}
deriving stock (LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool
(LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool)
-> (LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool)
-> Eq LockConfigurationTypeProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool
== :: LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool
$c/= :: LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool
/= :: LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> Bool
Prelude.Eq, Int -> LockConfigurationTypeProperty -> ShowS
[LockConfigurationTypeProperty] -> ShowS
LockConfigurationTypeProperty -> String
(Int -> LockConfigurationTypeProperty -> ShowS)
-> (LockConfigurationTypeProperty -> String)
-> ([LockConfigurationTypeProperty] -> ShowS)
-> Show LockConfigurationTypeProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> LockConfigurationTypeProperty -> ShowS
showsPrec :: Int -> LockConfigurationTypeProperty -> ShowS
$cshow :: LockConfigurationTypeProperty -> String
show :: LockConfigurationTypeProperty -> String
$cshowList :: [LockConfigurationTypeProperty] -> ShowS
showList :: [LockConfigurationTypeProperty] -> ShowS
Prelude.Show)
mkLockConfigurationTypeProperty ::
Value Prelude.Integer -> LockConfigurationTypeProperty
mkLockConfigurationTypeProperty :: Value Integer -> LockConfigurationTypeProperty
mkLockConfigurationTypeProperty Value Integer
minRetentionDays
= LockConfigurationTypeProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), minRetentionDays :: Value Integer
minRetentionDays = Value Integer
minRetentionDays,
changeableForDays :: Maybe (Value Integer)
changeableForDays = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing,
maxRetentionDays :: Maybe (Value Integer)
maxRetentionDays = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties LockConfigurationTypeProperty where
toResourceProperties :: LockConfigurationTypeProperty -> ResourceProperties
toResourceProperties LockConfigurationTypeProperty {Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: LockConfigurationTypeProperty -> ()
changeableForDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
minRetentionDays :: LockConfigurationTypeProperty -> Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Backup::BackupVault.LockConfigurationType",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"MinRetentionDays" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
minRetentionDays]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ChangeableForDays" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
changeableForDays,
Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"MaxRetentionDays" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
maxRetentionDays]))}
instance JSON.ToJSON LockConfigurationTypeProperty where
toJSON :: LockConfigurationTypeProperty -> Value
toJSON LockConfigurationTypeProperty {Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: LockConfigurationTypeProperty -> ()
changeableForDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
minRetentionDays :: LockConfigurationTypeProperty -> Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"MinRetentionDays" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
minRetentionDays]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ChangeableForDays" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
changeableForDays,
Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"MaxRetentionDays" (Value Integer -> (Key, Value))
-> Maybe (Value Integer) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Integer)
maxRetentionDays])))
instance Property "ChangeableForDays" LockConfigurationTypeProperty where
type PropertyType "ChangeableForDays" LockConfigurationTypeProperty = Value Prelude.Integer
set :: PropertyType "ChangeableForDays" LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> LockConfigurationTypeProperty
set PropertyType "ChangeableForDays" LockConfigurationTypeProperty
newValue LockConfigurationTypeProperty {Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: LockConfigurationTypeProperty -> ()
changeableForDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
minRetentionDays :: LockConfigurationTypeProperty -> Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
= LockConfigurationTypeProperty
{changeableForDays :: Maybe (Value Integer)
changeableForDays = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ChangeableForDays" LockConfigurationTypeProperty
Value Integer
newValue, Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: ()
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
haddock_workaround_ :: ()
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
instance Property "MaxRetentionDays" LockConfigurationTypeProperty where
type PropertyType "MaxRetentionDays" LockConfigurationTypeProperty = Value Prelude.Integer
set :: PropertyType "MaxRetentionDays" LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> LockConfigurationTypeProperty
set PropertyType "MaxRetentionDays" LockConfigurationTypeProperty
newValue LockConfigurationTypeProperty {Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: LockConfigurationTypeProperty -> ()
changeableForDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
minRetentionDays :: LockConfigurationTypeProperty -> Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
= LockConfigurationTypeProperty
{maxRetentionDays :: Maybe (Value Integer)
maxRetentionDays = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "MaxRetentionDays" LockConfigurationTypeProperty
Value Integer
newValue, Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
instance Property "MinRetentionDays" LockConfigurationTypeProperty where
type PropertyType "MinRetentionDays" LockConfigurationTypeProperty = Value Prelude.Integer
set :: PropertyType "MinRetentionDays" LockConfigurationTypeProperty
-> LockConfigurationTypeProperty -> LockConfigurationTypeProperty
set PropertyType "MinRetentionDays" LockConfigurationTypeProperty
newValue LockConfigurationTypeProperty {Maybe (Value Integer)
()
Value Integer
haddock_workaround_ :: LockConfigurationTypeProperty -> ()
changeableForDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
maxRetentionDays :: LockConfigurationTypeProperty -> Maybe (Value Integer)
minRetentionDays :: LockConfigurationTypeProperty -> Value Integer
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
minRetentionDays :: Value Integer
..}
= LockConfigurationTypeProperty {minRetentionDays :: Value Integer
minRetentionDays = PropertyType "MinRetentionDays" LockConfigurationTypeProperty
Value Integer
newValue, Maybe (Value Integer)
()
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
haddock_workaround_ :: ()
changeableForDays :: Maybe (Value Integer)
maxRetentionDays :: Maybe (Value Integer)
..}