module Stratosphere.ApplicationAutoScaling.ScalingPolicy.PredictiveScalingPredefinedLoadMetricProperty (
        PredictiveScalingPredefinedLoadMetricProperty(..),
        mkPredictiveScalingPredefinedLoadMetricProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data PredictiveScalingPredefinedLoadMetricProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-applicationautoscaling-scalingpolicy-predictivescalingpredefinedloadmetric.html>
    PredictiveScalingPredefinedLoadMetricProperty {PredictiveScalingPredefinedLoadMetricProperty -> ()
haddock_workaround_ :: (),
                                                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-applicationautoscaling-scalingpolicy-predictivescalingpredefinedloadmetric.html#cfn-applicationautoscaling-scalingpolicy-predictivescalingpredefinedloadmetric-predefinedmetrictype>
                                                   PredictiveScalingPredefinedLoadMetricProperty -> Value Text
predefinedMetricType :: (Value Prelude.Text),
                                                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-applicationautoscaling-scalingpolicy-predictivescalingpredefinedloadmetric.html#cfn-applicationautoscaling-scalingpolicy-predictivescalingpredefinedloadmetric-resourcelabel>
                                                   PredictiveScalingPredefinedLoadMetricProperty -> Maybe (Value Text)
resourceLabel :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty -> Bool
(PredictiveScalingPredefinedLoadMetricProperty
 -> PredictiveScalingPredefinedLoadMetricProperty -> Bool)
-> (PredictiveScalingPredefinedLoadMetricProperty
    -> PredictiveScalingPredefinedLoadMetricProperty -> Bool)
-> Eq PredictiveScalingPredefinedLoadMetricProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty -> Bool
== :: PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty -> Bool
$c/= :: PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty -> Bool
/= :: PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty -> Bool
Prelude.Eq, Int -> PredictiveScalingPredefinedLoadMetricProperty -> ShowS
[PredictiveScalingPredefinedLoadMetricProperty] -> ShowS
PredictiveScalingPredefinedLoadMetricProperty -> String
(Int -> PredictiveScalingPredefinedLoadMetricProperty -> ShowS)
-> (PredictiveScalingPredefinedLoadMetricProperty -> String)
-> ([PredictiveScalingPredefinedLoadMetricProperty] -> ShowS)
-> Show PredictiveScalingPredefinedLoadMetricProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> PredictiveScalingPredefinedLoadMetricProperty -> ShowS
showsPrec :: Int -> PredictiveScalingPredefinedLoadMetricProperty -> ShowS
$cshow :: PredictiveScalingPredefinedLoadMetricProperty -> String
show :: PredictiveScalingPredefinedLoadMetricProperty -> String
$cshowList :: [PredictiveScalingPredefinedLoadMetricProperty] -> ShowS
showList :: [PredictiveScalingPredefinedLoadMetricProperty] -> ShowS
Prelude.Show)
mkPredictiveScalingPredefinedLoadMetricProperty ::
  Value Prelude.Text -> PredictiveScalingPredefinedLoadMetricProperty
mkPredictiveScalingPredefinedLoadMetricProperty :: Value Text -> PredictiveScalingPredefinedLoadMetricProperty
mkPredictiveScalingPredefinedLoadMetricProperty
  Value Text
predefinedMetricType
  = PredictiveScalingPredefinedLoadMetricProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       predefinedMetricType :: Value Text
predefinedMetricType = Value Text
predefinedMetricType,
       resourceLabel :: Maybe (Value Text)
resourceLabel = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties PredictiveScalingPredefinedLoadMetricProperty where
  toResourceProperties :: PredictiveScalingPredefinedLoadMetricProperty -> ResourceProperties
toResourceProperties
    PredictiveScalingPredefinedLoadMetricProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: PredictiveScalingPredefinedLoadMetricProperty -> ()
predefinedMetricType :: PredictiveScalingPredefinedLoadMetricProperty -> Value Text
resourceLabel :: PredictiveScalingPredefinedLoadMetricProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
resourceLabel :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::ApplicationAutoScaling::ScalingPolicy.PredictiveScalingPredefinedLoadMetric",
         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
"PredefinedMetricType" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
predefinedMetricType]
                           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                              [Key -> Value 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
"ResourceLabel" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
resourceLabel]))}
instance JSON.ToJSON PredictiveScalingPredefinedLoadMetricProperty where
  toJSON :: PredictiveScalingPredefinedLoadMetricProperty -> Value
toJSON PredictiveScalingPredefinedLoadMetricProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: PredictiveScalingPredefinedLoadMetricProperty -> ()
predefinedMetricType :: PredictiveScalingPredefinedLoadMetricProperty -> Value Text
resourceLabel :: PredictiveScalingPredefinedLoadMetricProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
resourceLabel :: Maybe (Value Text)
..}
    = [(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
"PredefinedMetricType" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
predefinedMetricType]
              ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                 [Key -> Value 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
"ResourceLabel" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
resourceLabel])))
instance Property "PredefinedMetricType" PredictiveScalingPredefinedLoadMetricProperty where
  type PropertyType "PredefinedMetricType" PredictiveScalingPredefinedLoadMetricProperty = Value Prelude.Text
  set :: PropertyType
  "PredefinedMetricType"
  PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty
set PropertyType
  "PredefinedMetricType"
  PredictiveScalingPredefinedLoadMetricProperty
newValue PredictiveScalingPredefinedLoadMetricProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: PredictiveScalingPredefinedLoadMetricProperty -> ()
predefinedMetricType :: PredictiveScalingPredefinedLoadMetricProperty -> Value Text
resourceLabel :: PredictiveScalingPredefinedLoadMetricProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
resourceLabel :: Maybe (Value Text)
..}
    = PredictiveScalingPredefinedLoadMetricProperty
        {predefinedMetricType :: Value Text
predefinedMetricType = PropertyType
  "PredefinedMetricType"
  PredictiveScalingPredefinedLoadMetricProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
resourceLabel :: Maybe (Value Text)
haddock_workaround_ :: ()
resourceLabel :: Maybe (Value Text)
..}
instance Property "ResourceLabel" PredictiveScalingPredefinedLoadMetricProperty where
  type PropertyType "ResourceLabel" PredictiveScalingPredefinedLoadMetricProperty = Value Prelude.Text
  set :: PropertyType
  "ResourceLabel" PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty
-> PredictiveScalingPredefinedLoadMetricProperty
set PropertyType
  "ResourceLabel" PredictiveScalingPredefinedLoadMetricProperty
newValue PredictiveScalingPredefinedLoadMetricProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: PredictiveScalingPredefinedLoadMetricProperty -> ()
predefinedMetricType :: PredictiveScalingPredefinedLoadMetricProperty -> Value Text
resourceLabel :: PredictiveScalingPredefinedLoadMetricProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
resourceLabel :: Maybe (Value Text)
..}
    = PredictiveScalingPredefinedLoadMetricProperty
        {resourceLabel :: Maybe (Value Text)
resourceLabel = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "ResourceLabel" PredictiveScalingPredefinedLoadMetricProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
haddock_workaround_ :: ()
predefinedMetricType :: Value Text
..}