module Stratosphere.FSx.Volume.AggregateConfigurationProperty (
AggregateConfigurationProperty(..),
mkAggregateConfigurationProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data AggregateConfigurationProperty
=
AggregateConfigurationProperty {AggregateConfigurationProperty -> ()
haddock_workaround_ :: (),
AggregateConfigurationProperty -> Maybe (ValueList Text)
aggregates :: (Prelude.Maybe (ValueList Prelude.Text)),
AggregateConfigurationProperty -> Maybe (Value Integer)
constituentsPerAggregate :: (Prelude.Maybe (Value Prelude.Integer))}
deriving stock (AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool
(AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool)
-> (AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool)
-> Eq AggregateConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool
== :: AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool
$c/= :: AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool
/= :: AggregateConfigurationProperty
-> AggregateConfigurationProperty -> Bool
Prelude.Eq, Int -> AggregateConfigurationProperty -> ShowS
[AggregateConfigurationProperty] -> ShowS
AggregateConfigurationProperty -> String
(Int -> AggregateConfigurationProperty -> ShowS)
-> (AggregateConfigurationProperty -> String)
-> ([AggregateConfigurationProperty] -> ShowS)
-> Show AggregateConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AggregateConfigurationProperty -> ShowS
showsPrec :: Int -> AggregateConfigurationProperty -> ShowS
$cshow :: AggregateConfigurationProperty -> String
show :: AggregateConfigurationProperty -> String
$cshowList :: [AggregateConfigurationProperty] -> ShowS
showList :: [AggregateConfigurationProperty] -> ShowS
Prelude.Show)
mkAggregateConfigurationProperty :: AggregateConfigurationProperty
mkAggregateConfigurationProperty :: AggregateConfigurationProperty
mkAggregateConfigurationProperty
= AggregateConfigurationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), aggregates :: Maybe (ValueList Text)
aggregates = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing,
constituentsPerAggregate :: Maybe (Value Integer)
constituentsPerAggregate = Maybe (Value Integer)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AggregateConfigurationProperty where
toResourceProperties :: AggregateConfigurationProperty -> ResourceProperties
toResourceProperties AggregateConfigurationProperty {Maybe (ValueList Text)
Maybe (Value Integer)
()
haddock_workaround_ :: AggregateConfigurationProperty -> ()
aggregates :: AggregateConfigurationProperty -> Maybe (ValueList Text)
constituentsPerAggregate :: AggregateConfigurationProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
constituentsPerAggregate :: Maybe (Value Integer)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::FSx::Volume.AggregateConfiguration",
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
"Aggregates" (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)
aggregates,
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
"ConstituentsPerAggregate"
(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)
constituentsPerAggregate])}
instance JSON.ToJSON AggregateConfigurationProperty where
toJSON :: AggregateConfigurationProperty -> Value
toJSON AggregateConfigurationProperty {Maybe (ValueList Text)
Maybe (Value Integer)
()
haddock_workaround_ :: AggregateConfigurationProperty -> ()
aggregates :: AggregateConfigurationProperty -> Maybe (ValueList Text)
constituentsPerAggregate :: AggregateConfigurationProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
constituentsPerAggregate :: Maybe (Value Integer)
..}
= [(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
"Aggregates" (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)
aggregates,
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
"ConstituentsPerAggregate"
(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)
constituentsPerAggregate]))
instance Property "Aggregates" AggregateConfigurationProperty where
type PropertyType "Aggregates" AggregateConfigurationProperty = ValueList Prelude.Text
set :: PropertyType "Aggregates" AggregateConfigurationProperty
-> AggregateConfigurationProperty -> AggregateConfigurationProperty
set PropertyType "Aggregates" AggregateConfigurationProperty
newValue AggregateConfigurationProperty {Maybe (ValueList Text)
Maybe (Value Integer)
()
haddock_workaround_ :: AggregateConfigurationProperty -> ()
aggregates :: AggregateConfigurationProperty -> Maybe (ValueList Text)
constituentsPerAggregate :: AggregateConfigurationProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
constituentsPerAggregate :: Maybe (Value Integer)
..}
= AggregateConfigurationProperty
{aggregates :: Maybe (ValueList Text)
aggregates = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Aggregates" AggregateConfigurationProperty
ValueList Text
newValue, Maybe (Value Integer)
()
haddock_workaround_ :: ()
constituentsPerAggregate :: Maybe (Value Integer)
haddock_workaround_ :: ()
constituentsPerAggregate :: Maybe (Value Integer)
..}
instance Property "ConstituentsPerAggregate" AggregateConfigurationProperty where
type PropertyType "ConstituentsPerAggregate" AggregateConfigurationProperty = Value Prelude.Integer
set :: PropertyType
"ConstituentsPerAggregate" AggregateConfigurationProperty
-> AggregateConfigurationProperty -> AggregateConfigurationProperty
set PropertyType
"ConstituentsPerAggregate" AggregateConfigurationProperty
newValue AggregateConfigurationProperty {Maybe (ValueList Text)
Maybe (Value Integer)
()
haddock_workaround_ :: AggregateConfigurationProperty -> ()
aggregates :: AggregateConfigurationProperty -> Maybe (ValueList Text)
constituentsPerAggregate :: AggregateConfigurationProperty -> Maybe (Value Integer)
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
constituentsPerAggregate :: Maybe (Value Integer)
..}
= AggregateConfigurationProperty
{constituentsPerAggregate :: Maybe (Value Integer)
constituentsPerAggregate = Value Integer -> Maybe (Value Integer)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
"ConstituentsPerAggregate" AggregateConfigurationProperty
Value Integer
newValue, Maybe (ValueList Text)
()
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
haddock_workaround_ :: ()
aggregates :: Maybe (ValueList Text)
..}