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