module Stratosphere.EMR.Cluster.ScalingConstraintsProperty (
ScalingConstraintsProperty(..), mkScalingConstraintsProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ScalingConstraintsProperty
=
ScalingConstraintsProperty {ScalingConstraintsProperty -> ()
haddock_workaround_ :: (),
ScalingConstraintsProperty -> Value Integer
maxCapacity :: (Value Prelude.Integer),
ScalingConstraintsProperty -> Value Integer
minCapacity :: (Value Prelude.Integer)}
deriving stock (ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool
(ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool)
-> (ScalingConstraintsProperty
-> ScalingConstraintsProperty -> Bool)
-> Eq ScalingConstraintsProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool
== :: ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool
$c/= :: ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool
/= :: ScalingConstraintsProperty -> ScalingConstraintsProperty -> Bool
Prelude.Eq, Int -> ScalingConstraintsProperty -> ShowS
[ScalingConstraintsProperty] -> ShowS
ScalingConstraintsProperty -> String
(Int -> ScalingConstraintsProperty -> ShowS)
-> (ScalingConstraintsProperty -> String)
-> ([ScalingConstraintsProperty] -> ShowS)
-> Show ScalingConstraintsProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ScalingConstraintsProperty -> ShowS
showsPrec :: Int -> ScalingConstraintsProperty -> ShowS
$cshow :: ScalingConstraintsProperty -> String
show :: ScalingConstraintsProperty -> String
$cshowList :: [ScalingConstraintsProperty] -> ShowS
showList :: [ScalingConstraintsProperty] -> ShowS
Prelude.Show)
mkScalingConstraintsProperty ::
Value Prelude.Integer
-> Value Prelude.Integer -> ScalingConstraintsProperty
mkScalingConstraintsProperty :: Value Integer -> Value Integer -> ScalingConstraintsProperty
mkScalingConstraintsProperty Value Integer
maxCapacity Value Integer
minCapacity
= ScalingConstraintsProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), maxCapacity :: Value Integer
maxCapacity = Value Integer
maxCapacity,
minCapacity :: Value Integer
minCapacity = Value Integer
minCapacity}
instance ToResourceProperties ScalingConstraintsProperty where
toResourceProperties :: ScalingConstraintsProperty -> ResourceProperties
toResourceProperties ScalingConstraintsProperty {()
Value Integer
haddock_workaround_ :: ScalingConstraintsProperty -> ()
maxCapacity :: ScalingConstraintsProperty -> Value Integer
minCapacity :: ScalingConstraintsProperty -> Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
minCapacity :: Value Integer
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EMR::Cluster.ScalingConstraints",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Key
"MaxCapacity" 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
maxCapacity,
Key
"MinCapacity" 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
minCapacity]}
instance JSON.ToJSON ScalingConstraintsProperty where
toJSON :: ScalingConstraintsProperty -> Value
toJSON ScalingConstraintsProperty {()
Value Integer
haddock_workaround_ :: ScalingConstraintsProperty -> ()
maxCapacity :: ScalingConstraintsProperty -> Value Integer
minCapacity :: ScalingConstraintsProperty -> Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
minCapacity :: Value Integer
..}
= [(Key, Value)] -> Value
JSON.object
[Key
"MaxCapacity" 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
maxCapacity,
Key
"MinCapacity" 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
minCapacity]
instance Property "MaxCapacity" ScalingConstraintsProperty where
type PropertyType "MaxCapacity" ScalingConstraintsProperty = Value Prelude.Integer
set :: PropertyType "MaxCapacity" ScalingConstraintsProperty
-> ScalingConstraintsProperty -> ScalingConstraintsProperty
set PropertyType "MaxCapacity" ScalingConstraintsProperty
newValue ScalingConstraintsProperty {()
Value Integer
haddock_workaround_ :: ScalingConstraintsProperty -> ()
maxCapacity :: ScalingConstraintsProperty -> Value Integer
minCapacity :: ScalingConstraintsProperty -> Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
minCapacity :: Value Integer
..}
= ScalingConstraintsProperty {maxCapacity :: Value Integer
maxCapacity = PropertyType "MaxCapacity" ScalingConstraintsProperty
Value Integer
newValue, ()
Value Integer
haddock_workaround_ :: ()
minCapacity :: Value Integer
haddock_workaround_ :: ()
minCapacity :: Value Integer
..}
instance Property "MinCapacity" ScalingConstraintsProperty where
type PropertyType "MinCapacity" ScalingConstraintsProperty = Value Prelude.Integer
set :: PropertyType "MinCapacity" ScalingConstraintsProperty
-> ScalingConstraintsProperty -> ScalingConstraintsProperty
set PropertyType "MinCapacity" ScalingConstraintsProperty
newValue ScalingConstraintsProperty {()
Value Integer
haddock_workaround_ :: ScalingConstraintsProperty -> ()
maxCapacity :: ScalingConstraintsProperty -> Value Integer
minCapacity :: ScalingConstraintsProperty -> Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
minCapacity :: Value Integer
..}
= ScalingConstraintsProperty {minCapacity :: Value Integer
minCapacity = PropertyType "MinCapacity" ScalingConstraintsProperty
Value Integer
newValue, ()
Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
haddock_workaround_ :: ()
maxCapacity :: Value Integer
..}