module Stratosphere.AutoScaling.AutoScalingGroup.CapacityReservationTargetProperty (
CapacityReservationTargetProperty(..),
mkCapacityReservationTargetProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data CapacityReservationTargetProperty
=
CapacityReservationTargetProperty {CapacityReservationTargetProperty -> ()
haddock_workaround_ :: (),
CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationIds :: (Prelude.Maybe (ValueList Prelude.Text)),
CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationResourceGroupArns :: (Prelude.Maybe (ValueList Prelude.Text))}
deriving stock (CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool
(CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool)
-> (CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool)
-> Eq CapacityReservationTargetProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool
== :: CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool
$c/= :: CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool
/= :: CapacityReservationTargetProperty
-> CapacityReservationTargetProperty -> Bool
Prelude.Eq, Int -> CapacityReservationTargetProperty -> ShowS
[CapacityReservationTargetProperty] -> ShowS
CapacityReservationTargetProperty -> String
(Int -> CapacityReservationTargetProperty -> ShowS)
-> (CapacityReservationTargetProperty -> String)
-> ([CapacityReservationTargetProperty] -> ShowS)
-> Show CapacityReservationTargetProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> CapacityReservationTargetProperty -> ShowS
showsPrec :: Int -> CapacityReservationTargetProperty -> ShowS
$cshow :: CapacityReservationTargetProperty -> String
show :: CapacityReservationTargetProperty -> String
$cshowList :: [CapacityReservationTargetProperty] -> ShowS
showList :: [CapacityReservationTargetProperty] -> ShowS
Prelude.Show)
mkCapacityReservationTargetProperty ::
CapacityReservationTargetProperty
mkCapacityReservationTargetProperty :: CapacityReservationTargetProperty
mkCapacityReservationTargetProperty
= CapacityReservationTargetProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (),
capacityReservationIds :: Maybe (ValueList Text)
capacityReservationIds = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing,
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
capacityReservationResourceGroupArns = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties CapacityReservationTargetProperty where
toResourceProperties :: CapacityReservationTargetProperty -> ResourceProperties
toResourceProperties CapacityReservationTargetProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CapacityReservationTargetProperty -> ()
capacityReservationIds :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationResourceGroupArns :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::AutoScaling::AutoScalingGroup.CapacityReservationTarget",
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 -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"CapacityReservationIds"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
capacityReservationIds,
Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"CapacityReservationResourceGroupArns"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
capacityReservationResourceGroupArns])}
instance JSON.ToJSON CapacityReservationTargetProperty where
toJSON :: CapacityReservationTargetProperty -> Value
toJSON CapacityReservationTargetProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CapacityReservationTargetProperty -> ()
capacityReservationIds :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationResourceGroupArns :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
..}
= [(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 -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"CapacityReservationIds"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
capacityReservationIds,
Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"CapacityReservationResourceGroupArns"
(ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
capacityReservationResourceGroupArns]))
instance Property "CapacityReservationIds" CapacityReservationTargetProperty where
type PropertyType "CapacityReservationIds" CapacityReservationTargetProperty = ValueList Prelude.Text
set :: PropertyType
"CapacityReservationIds" CapacityReservationTargetProperty
-> CapacityReservationTargetProperty
-> CapacityReservationTargetProperty
set PropertyType
"CapacityReservationIds" CapacityReservationTargetProperty
newValue CapacityReservationTargetProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CapacityReservationTargetProperty -> ()
capacityReservationIds :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationResourceGroupArns :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
..}
= CapacityReservationTargetProperty
{capacityReservationIds :: Maybe (ValueList Text)
capacityReservationIds = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
"CapacityReservationIds" CapacityReservationTargetProperty
ValueList Text
newValue, Maybe (ValueList Text)
()
haddock_workaround_ :: ()
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
..}
instance Property "CapacityReservationResourceGroupArns" CapacityReservationTargetProperty where
type PropertyType "CapacityReservationResourceGroupArns" CapacityReservationTargetProperty = ValueList Prelude.Text
set :: PropertyType
"CapacityReservationResourceGroupArns"
CapacityReservationTargetProperty
-> CapacityReservationTargetProperty
-> CapacityReservationTargetProperty
set PropertyType
"CapacityReservationResourceGroupArns"
CapacityReservationTargetProperty
newValue CapacityReservationTargetProperty {Maybe (ValueList Text)
()
haddock_workaround_ :: CapacityReservationTargetProperty -> ()
capacityReservationIds :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
capacityReservationResourceGroupArns :: CapacityReservationTargetProperty -> Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
capacityReservationResourceGroupArns :: Maybe (ValueList Text)
..}
= CapacityReservationTargetProperty
{capacityReservationResourceGroupArns :: Maybe (ValueList Text)
capacityReservationResourceGroupArns = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
"CapacityReservationResourceGroupArns"
CapacityReservationTargetProperty
ValueList Text
newValue, Maybe (ValueList Text)
()
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
haddock_workaround_ :: ()
capacityReservationIds :: Maybe (ValueList Text)
..}