module Stratosphere.SecurityLake.SubscriberNotification.NotificationConfigurationProperty (
        module Exports, NotificationConfigurationProperty(..),
        mkNotificationConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.SecurityLake.SubscriberNotification.HttpsNotificationConfigurationProperty as Exports
import Stratosphere.ResourceProperties
data NotificationConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-securitylake-subscribernotification-notificationconfiguration.html>
    NotificationConfigurationProperty {NotificationConfigurationProperty -> ()
haddock_workaround_ :: (),
                                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-securitylake-subscribernotification-notificationconfiguration.html#cfn-securitylake-subscribernotification-notificationconfiguration-httpsnotificationconfiguration>
                                       NotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
httpsNotificationConfiguration :: (Prelude.Maybe HttpsNotificationConfigurationProperty),
                                       -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-securitylake-subscribernotification-notificationconfiguration.html#cfn-securitylake-subscribernotification-notificationconfiguration-sqsnotificationconfiguration>
                                       NotificationConfigurationProperty -> Maybe Object
sqsNotificationConfiguration :: (Prelude.Maybe JSON.Object)}
  deriving stock (NotificationConfigurationProperty
-> NotificationConfigurationProperty -> Bool
(NotificationConfigurationProperty
 -> NotificationConfigurationProperty -> Bool)
-> (NotificationConfigurationProperty
    -> NotificationConfigurationProperty -> Bool)
-> Eq NotificationConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NotificationConfigurationProperty
-> NotificationConfigurationProperty -> Bool
== :: NotificationConfigurationProperty
-> NotificationConfigurationProperty -> Bool
$c/= :: NotificationConfigurationProperty
-> NotificationConfigurationProperty -> Bool
/= :: NotificationConfigurationProperty
-> NotificationConfigurationProperty -> Bool
Prelude.Eq, Int -> NotificationConfigurationProperty -> ShowS
[NotificationConfigurationProperty] -> ShowS
NotificationConfigurationProperty -> String
(Int -> NotificationConfigurationProperty -> ShowS)
-> (NotificationConfigurationProperty -> String)
-> ([NotificationConfigurationProperty] -> ShowS)
-> Show NotificationConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NotificationConfigurationProperty -> ShowS
showsPrec :: Int -> NotificationConfigurationProperty -> ShowS
$cshow :: NotificationConfigurationProperty -> String
show :: NotificationConfigurationProperty -> String
$cshowList :: [NotificationConfigurationProperty] -> ShowS
showList :: [NotificationConfigurationProperty] -> ShowS
Prelude.Show)
mkNotificationConfigurationProperty ::
  NotificationConfigurationProperty
mkNotificationConfigurationProperty :: NotificationConfigurationProperty
mkNotificationConfigurationProperty
  = NotificationConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
httpsNotificationConfiguration = Maybe HttpsNotificationConfigurationProperty
forall a. Maybe a
Prelude.Nothing,
       sqsNotificationConfiguration :: Maybe Object
sqsNotificationConfiguration = Maybe Object
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NotificationConfigurationProperty where
  toResourceProperties :: NotificationConfigurationProperty -> ResourceProperties
toResourceProperties NotificationConfigurationProperty {Maybe Object
Maybe HttpsNotificationConfigurationProperty
()
haddock_workaround_ :: NotificationConfigurationProperty -> ()
httpsNotificationConfiguration :: NotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: NotificationConfigurationProperty -> Maybe Object
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: Maybe Object
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::SecurityLake::SubscriberNotification.NotificationConfiguration",
         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 -> HttpsNotificationConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"HttpsNotificationConfiguration"
                              (HttpsNotificationConfigurationProperty -> (Key, Value))
-> Maybe HttpsNotificationConfigurationProperty
-> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe HttpsNotificationConfigurationProperty
httpsNotificationConfiguration,
                            Key -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"SqsNotificationConfiguration"
                              (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
sqsNotificationConfiguration])}
instance JSON.ToJSON NotificationConfigurationProperty where
  toJSON :: NotificationConfigurationProperty -> Value
toJSON NotificationConfigurationProperty {Maybe Object
Maybe HttpsNotificationConfigurationProperty
()
haddock_workaround_ :: NotificationConfigurationProperty -> ()
httpsNotificationConfiguration :: NotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: NotificationConfigurationProperty -> Maybe Object
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: Maybe Object
..}
    = [(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 -> HttpsNotificationConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"HttpsNotificationConfiguration"
                 (HttpsNotificationConfigurationProperty -> (Key, Value))
-> Maybe HttpsNotificationConfigurationProperty
-> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe HttpsNotificationConfigurationProperty
httpsNotificationConfiguration,
               Key -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"SqsNotificationConfiguration"
                 (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
sqsNotificationConfiguration]))
instance Property "HttpsNotificationConfiguration" NotificationConfigurationProperty where
  type PropertyType "HttpsNotificationConfiguration" NotificationConfigurationProperty = HttpsNotificationConfigurationProperty
  set :: PropertyType
  "HttpsNotificationConfiguration" NotificationConfigurationProperty
-> NotificationConfigurationProperty
-> NotificationConfigurationProperty
set PropertyType
  "HttpsNotificationConfiguration" NotificationConfigurationProperty
newValue NotificationConfigurationProperty {Maybe Object
Maybe HttpsNotificationConfigurationProperty
()
haddock_workaround_ :: NotificationConfigurationProperty -> ()
httpsNotificationConfiguration :: NotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: NotificationConfigurationProperty -> Maybe Object
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: Maybe Object
..}
    = NotificationConfigurationProperty
        {httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
httpsNotificationConfiguration = HttpsNotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType
  "HttpsNotificationConfiguration" NotificationConfigurationProperty
HttpsNotificationConfigurationProperty
newValue, Maybe Object
()
haddock_workaround_ :: ()
sqsNotificationConfiguration :: Maybe Object
haddock_workaround_ :: ()
sqsNotificationConfiguration :: Maybe Object
..}
instance Property "SqsNotificationConfiguration" NotificationConfigurationProperty where
  type PropertyType "SqsNotificationConfiguration" NotificationConfigurationProperty = JSON.Object
  set :: PropertyType
  "SqsNotificationConfiguration" NotificationConfigurationProperty
-> NotificationConfigurationProperty
-> NotificationConfigurationProperty
set PropertyType
  "SqsNotificationConfiguration" NotificationConfigurationProperty
newValue NotificationConfigurationProperty {Maybe Object
Maybe HttpsNotificationConfigurationProperty
()
haddock_workaround_ :: NotificationConfigurationProperty -> ()
httpsNotificationConfiguration :: NotificationConfigurationProperty
-> Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: NotificationConfigurationProperty -> Maybe Object
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
sqsNotificationConfiguration :: Maybe Object
..}
    = NotificationConfigurationProperty
        {sqsNotificationConfiguration :: Maybe Object
sqsNotificationConfiguration = Object -> Maybe Object
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure Object
PropertyType
  "SqsNotificationConfiguration" NotificationConfigurationProperty
newValue, Maybe HttpsNotificationConfigurationProperty
()
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
haddock_workaround_ :: ()
httpsNotificationConfiguration :: Maybe HttpsNotificationConfigurationProperty
..}