module Stratosphere.XRay.Group.InsightsConfigurationProperty (
        InsightsConfigurationProperty(..), mkInsightsConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data InsightsConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-xray-group-insightsconfiguration.html>
    InsightsConfigurationProperty {InsightsConfigurationProperty -> ()
haddock_workaround_ :: (),
                                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-xray-group-insightsconfiguration.html#cfn-xray-group-insightsconfiguration-insightsenabled>
                                   InsightsConfigurationProperty -> Maybe (Value Bool)
insightsEnabled :: (Prelude.Maybe (Value Prelude.Bool)),
                                   -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-xray-group-insightsconfiguration.html#cfn-xray-group-insightsconfiguration-notificationsenabled>
                                   InsightsConfigurationProperty -> Maybe (Value Bool)
notificationsEnabled :: (Prelude.Maybe (Value Prelude.Bool))}
  deriving stock (InsightsConfigurationProperty
-> InsightsConfigurationProperty -> Bool
(InsightsConfigurationProperty
 -> InsightsConfigurationProperty -> Bool)
-> (InsightsConfigurationProperty
    -> InsightsConfigurationProperty -> Bool)
-> Eq InsightsConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: InsightsConfigurationProperty
-> InsightsConfigurationProperty -> Bool
== :: InsightsConfigurationProperty
-> InsightsConfigurationProperty -> Bool
$c/= :: InsightsConfigurationProperty
-> InsightsConfigurationProperty -> Bool
/= :: InsightsConfigurationProperty
-> InsightsConfigurationProperty -> Bool
Prelude.Eq, Int -> InsightsConfigurationProperty -> ShowS
[InsightsConfigurationProperty] -> ShowS
InsightsConfigurationProperty -> String
(Int -> InsightsConfigurationProperty -> ShowS)
-> (InsightsConfigurationProperty -> String)
-> ([InsightsConfigurationProperty] -> ShowS)
-> Show InsightsConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> InsightsConfigurationProperty -> ShowS
showsPrec :: Int -> InsightsConfigurationProperty -> ShowS
$cshow :: InsightsConfigurationProperty -> String
show :: InsightsConfigurationProperty -> String
$cshowList :: [InsightsConfigurationProperty] -> ShowS
showList :: [InsightsConfigurationProperty] -> ShowS
Prelude.Show)
mkInsightsConfigurationProperty :: InsightsConfigurationProperty
mkInsightsConfigurationProperty :: InsightsConfigurationProperty
mkInsightsConfigurationProperty
  = InsightsConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), insightsEnabled :: Maybe (Value Bool)
insightsEnabled = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing,
       notificationsEnabled :: Maybe (Value Bool)
notificationsEnabled = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties InsightsConfigurationProperty where
  toResourceProperties :: InsightsConfigurationProperty -> ResourceProperties
toResourceProperties InsightsConfigurationProperty {Maybe (Value Bool)
()
haddock_workaround_ :: InsightsConfigurationProperty -> ()
insightsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
notificationsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
notificationsEnabled :: Maybe (Value Bool)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::XRay::Group.InsightsConfiguration",
         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
"InsightsEnabled" (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)
insightsEnabled,
                            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
"NotificationsEnabled"
                              (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)
notificationsEnabled])}
instance JSON.ToJSON InsightsConfigurationProperty where
  toJSON :: InsightsConfigurationProperty -> Value
toJSON InsightsConfigurationProperty {Maybe (Value Bool)
()
haddock_workaround_ :: InsightsConfigurationProperty -> ()
insightsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
notificationsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
notificationsEnabled :: 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
"InsightsEnabled" (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)
insightsEnabled,
               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
"NotificationsEnabled"
                 (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)
notificationsEnabled]))
instance Property "InsightsEnabled" InsightsConfigurationProperty where
  type PropertyType "InsightsEnabled" InsightsConfigurationProperty = Value Prelude.Bool
  set :: PropertyType "InsightsEnabled" InsightsConfigurationProperty
-> InsightsConfigurationProperty -> InsightsConfigurationProperty
set PropertyType "InsightsEnabled" InsightsConfigurationProperty
newValue InsightsConfigurationProperty {Maybe (Value Bool)
()
haddock_workaround_ :: InsightsConfigurationProperty -> ()
insightsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
notificationsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
notificationsEnabled :: Maybe (Value Bool)
..}
    = InsightsConfigurationProperty
        {insightsEnabled :: Maybe (Value Bool)
insightsEnabled = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "InsightsEnabled" InsightsConfigurationProperty
Value Bool
newValue, Maybe (Value Bool)
()
haddock_workaround_ :: ()
notificationsEnabled :: Maybe (Value Bool)
haddock_workaround_ :: ()
notificationsEnabled :: Maybe (Value Bool)
..}
instance Property "NotificationsEnabled" InsightsConfigurationProperty where
  type PropertyType "NotificationsEnabled" InsightsConfigurationProperty = Value Prelude.Bool
  set :: PropertyType "NotificationsEnabled" InsightsConfigurationProperty
-> InsightsConfigurationProperty -> InsightsConfigurationProperty
set PropertyType "NotificationsEnabled" InsightsConfigurationProperty
newValue InsightsConfigurationProperty {Maybe (Value Bool)
()
haddock_workaround_ :: InsightsConfigurationProperty -> ()
insightsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
notificationsEnabled :: InsightsConfigurationProperty -> Maybe (Value Bool)
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
notificationsEnabled :: Maybe (Value Bool)
..}
    = InsightsConfigurationProperty
        {notificationsEnabled :: Maybe (Value Bool)
notificationsEnabled = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "NotificationsEnabled" InsightsConfigurationProperty
Value Bool
newValue, Maybe (Value Bool)
()
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
haddock_workaround_ :: ()
insightsEnabled :: Maybe (Value Bool)
..}