{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.SSMIncidents.Types.RegionMapInputValue where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data RegionMapInputValue = RegionMapInputValue'
{
RegionMapInputValue -> Maybe Text
sseKmsKeyId :: Prelude.Maybe Prelude.Text
}
deriving (RegionMapInputValue -> RegionMapInputValue -> Bool
(RegionMapInputValue -> RegionMapInputValue -> Bool)
-> (RegionMapInputValue -> RegionMapInputValue -> Bool)
-> Eq RegionMapInputValue
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: RegionMapInputValue -> RegionMapInputValue -> Bool
$c/= :: RegionMapInputValue -> RegionMapInputValue -> Bool
== :: RegionMapInputValue -> RegionMapInputValue -> Bool
$c== :: RegionMapInputValue -> RegionMapInputValue -> Bool
Prelude.Eq, ReadPrec [RegionMapInputValue]
ReadPrec RegionMapInputValue
Int -> ReadS RegionMapInputValue
ReadS [RegionMapInputValue]
(Int -> ReadS RegionMapInputValue)
-> ReadS [RegionMapInputValue]
-> ReadPrec RegionMapInputValue
-> ReadPrec [RegionMapInputValue]
-> Read RegionMapInputValue
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [RegionMapInputValue]
$creadListPrec :: ReadPrec [RegionMapInputValue]
readPrec :: ReadPrec RegionMapInputValue
$creadPrec :: ReadPrec RegionMapInputValue
readList :: ReadS [RegionMapInputValue]
$creadList :: ReadS [RegionMapInputValue]
readsPrec :: Int -> ReadS RegionMapInputValue
$creadsPrec :: Int -> ReadS RegionMapInputValue
Prelude.Read, Int -> RegionMapInputValue -> ShowS
[RegionMapInputValue] -> ShowS
RegionMapInputValue -> String
(Int -> RegionMapInputValue -> ShowS)
-> (RegionMapInputValue -> String)
-> ([RegionMapInputValue] -> ShowS)
-> Show RegionMapInputValue
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [RegionMapInputValue] -> ShowS
$cshowList :: [RegionMapInputValue] -> ShowS
show :: RegionMapInputValue -> String
$cshow :: RegionMapInputValue -> String
showsPrec :: Int -> RegionMapInputValue -> ShowS
$cshowsPrec :: Int -> RegionMapInputValue -> ShowS
Prelude.Show, (forall x. RegionMapInputValue -> Rep RegionMapInputValue x)
-> (forall x. Rep RegionMapInputValue x -> RegionMapInputValue)
-> Generic RegionMapInputValue
forall x. Rep RegionMapInputValue x -> RegionMapInputValue
forall x. RegionMapInputValue -> Rep RegionMapInputValue x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep RegionMapInputValue x -> RegionMapInputValue
$cfrom :: forall x. RegionMapInputValue -> Rep RegionMapInputValue x
Prelude.Generic)
newRegionMapInputValue ::
RegionMapInputValue
newRegionMapInputValue :: RegionMapInputValue
newRegionMapInputValue =
RegionMapInputValue' :: Maybe Text -> RegionMapInputValue
RegionMapInputValue' {$sel:sseKmsKeyId:RegionMapInputValue' :: Maybe Text
sseKmsKeyId = Maybe Text
forall a. Maybe a
Prelude.Nothing}
regionMapInputValue_sseKmsKeyId :: Lens.Lens' RegionMapInputValue (Prelude.Maybe Prelude.Text)
regionMapInputValue_sseKmsKeyId :: (Maybe Text -> f (Maybe Text))
-> RegionMapInputValue -> f RegionMapInputValue
regionMapInputValue_sseKmsKeyId = (RegionMapInputValue -> Maybe Text)
-> (RegionMapInputValue -> Maybe Text -> RegionMapInputValue)
-> Lens
RegionMapInputValue RegionMapInputValue (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RegionMapInputValue' {Maybe Text
sseKmsKeyId :: Maybe Text
$sel:sseKmsKeyId:RegionMapInputValue' :: RegionMapInputValue -> Maybe Text
sseKmsKeyId} -> Maybe Text
sseKmsKeyId) (\s :: RegionMapInputValue
s@RegionMapInputValue' {} Maybe Text
a -> RegionMapInputValue
s {$sel:sseKmsKeyId:RegionMapInputValue' :: Maybe Text
sseKmsKeyId = Maybe Text
a} :: RegionMapInputValue)
instance Prelude.Hashable RegionMapInputValue
instance Prelude.NFData RegionMapInputValue
instance Core.ToJSON RegionMapInputValue where
toJSON :: RegionMapInputValue -> Value
toJSON RegionMapInputValue' {Maybe Text
sseKmsKeyId :: Maybe Text
$sel:sseKmsKeyId:RegionMapInputValue' :: RegionMapInputValue -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[(Text
"sseKmsKeyId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sseKmsKeyId]
)