module Stratosphere.SSM.MaintenanceWindowTask.NotificationConfigProperty (
NotificationConfigProperty(..), mkNotificationConfigProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data NotificationConfigProperty
=
NotificationConfigProperty {NotificationConfigProperty -> ()
haddock_workaround_ :: (),
NotificationConfigProperty -> Value Text
notificationArn :: (Value Prelude.Text),
NotificationConfigProperty -> Maybe (ValueList Text)
notificationEvents :: (Prelude.Maybe (ValueList Prelude.Text)),
NotificationConfigProperty -> Maybe (Value Text)
notificationType :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (NotificationConfigProperty -> NotificationConfigProperty -> Bool
(NotificationConfigProperty -> NotificationConfigProperty -> Bool)
-> (NotificationConfigProperty
-> NotificationConfigProperty -> Bool)
-> Eq NotificationConfigProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NotificationConfigProperty -> NotificationConfigProperty -> Bool
== :: NotificationConfigProperty -> NotificationConfigProperty -> Bool
$c/= :: NotificationConfigProperty -> NotificationConfigProperty -> Bool
/= :: NotificationConfigProperty -> NotificationConfigProperty -> Bool
Prelude.Eq, Int -> NotificationConfigProperty -> ShowS
[NotificationConfigProperty] -> ShowS
NotificationConfigProperty -> String
(Int -> NotificationConfigProperty -> ShowS)
-> (NotificationConfigProperty -> String)
-> ([NotificationConfigProperty] -> ShowS)
-> Show NotificationConfigProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NotificationConfigProperty -> ShowS
showsPrec :: Int -> NotificationConfigProperty -> ShowS
$cshow :: NotificationConfigProperty -> String
show :: NotificationConfigProperty -> String
$cshowList :: [NotificationConfigProperty] -> ShowS
showList :: [NotificationConfigProperty] -> ShowS
Prelude.Show)
mkNotificationConfigProperty ::
Value Prelude.Text -> NotificationConfigProperty
mkNotificationConfigProperty :: Value Text -> NotificationConfigProperty
mkNotificationConfigProperty Value Text
notificationArn
= NotificationConfigProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), notificationArn :: Value Text
notificationArn = Value Text
notificationArn,
notificationEvents :: Maybe (ValueList Text)
notificationEvents = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing,
notificationType :: Maybe (Value Text)
notificationType = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NotificationConfigProperty where
toResourceProperties :: NotificationConfigProperty -> ResourceProperties
toResourceProperties NotificationConfigProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: NotificationConfigProperty -> ()
notificationArn :: NotificationConfigProperty -> Value Text
notificationEvents :: NotificationConfigProperty -> Maybe (ValueList Text)
notificationType :: NotificationConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::SSM::MaintenanceWindowTask.NotificationConfig",
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
"NotificationArn" 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
notificationArn]
([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
"NotificationEvents" (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)
notificationEvents,
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
"NotificationType" (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)
notificationType]))}
instance JSON.ToJSON NotificationConfigProperty where
toJSON :: NotificationConfigProperty -> Value
toJSON NotificationConfigProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: NotificationConfigProperty -> ()
notificationArn :: NotificationConfigProperty -> Value Text
notificationEvents :: NotificationConfigProperty -> Maybe (ValueList Text)
notificationType :: NotificationConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
notificationType :: 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
"NotificationArn" 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
notificationArn]
([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
"NotificationEvents" (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)
notificationEvents,
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
"NotificationType" (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)
notificationType])))
instance Property "NotificationArn" NotificationConfigProperty where
type PropertyType "NotificationArn" NotificationConfigProperty = Value Prelude.Text
set :: PropertyType "NotificationArn" NotificationConfigProperty
-> NotificationConfigProperty -> NotificationConfigProperty
set PropertyType "NotificationArn" NotificationConfigProperty
newValue NotificationConfigProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: NotificationConfigProperty -> ()
notificationArn :: NotificationConfigProperty -> Value Text
notificationEvents :: NotificationConfigProperty -> Maybe (ValueList Text)
notificationType :: NotificationConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
..}
= NotificationConfigProperty {notificationArn :: Value Text
notificationArn = PropertyType "NotificationArn" NotificationConfigProperty
Value Text
newValue, Maybe (ValueList Text)
Maybe (Value Text)
()
haddock_workaround_ :: ()
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
haddock_workaround_ :: ()
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
..}
instance Property "NotificationEvents" NotificationConfigProperty where
type PropertyType "NotificationEvents" NotificationConfigProperty = ValueList Prelude.Text
set :: PropertyType "NotificationEvents" NotificationConfigProperty
-> NotificationConfigProperty -> NotificationConfigProperty
set PropertyType "NotificationEvents" NotificationConfigProperty
newValue NotificationConfigProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: NotificationConfigProperty -> ()
notificationArn :: NotificationConfigProperty -> Value Text
notificationEvents :: NotificationConfigProperty -> Maybe (ValueList Text)
notificationType :: NotificationConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
..}
= NotificationConfigProperty
{notificationEvents :: Maybe (ValueList Text)
notificationEvents = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "NotificationEvents" NotificationConfigProperty
ValueList Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationType :: Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationType :: Maybe (Value Text)
..}
instance Property "NotificationType" NotificationConfigProperty where
type PropertyType "NotificationType" NotificationConfigProperty = Value Prelude.Text
set :: PropertyType "NotificationType" NotificationConfigProperty
-> NotificationConfigProperty -> NotificationConfigProperty
set PropertyType "NotificationType" NotificationConfigProperty
newValue NotificationConfigProperty {Maybe (ValueList Text)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: NotificationConfigProperty -> ()
notificationArn :: NotificationConfigProperty -> Value Text
notificationEvents :: NotificationConfigProperty -> Maybe (ValueList Text)
notificationType :: NotificationConfigProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
notificationType :: Maybe (Value Text)
..}
= NotificationConfigProperty
{notificationType :: Maybe (Value Text)
notificationType = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "NotificationType" NotificationConfigProperty
Value Text
newValue, Maybe (ValueList Text)
()
Value Text
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
haddock_workaround_ :: ()
notificationArn :: Value Text
notificationEvents :: Maybe (ValueList Text)
..}