{-# 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.SSM.Types.ResourceDataSyncDestinationDataSharing where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data ResourceDataSyncDestinationDataSharing = ResourceDataSyncDestinationDataSharing'
{
ResourceDataSyncDestinationDataSharing -> Maybe Text
destinationDataSharingType :: Prelude.Maybe Prelude.Text
}
deriving (ResourceDataSyncDestinationDataSharing
-> ResourceDataSyncDestinationDataSharing -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ResourceDataSyncDestinationDataSharing
-> ResourceDataSyncDestinationDataSharing -> Bool
$c/= :: ResourceDataSyncDestinationDataSharing
-> ResourceDataSyncDestinationDataSharing -> Bool
== :: ResourceDataSyncDestinationDataSharing
-> ResourceDataSyncDestinationDataSharing -> Bool
$c== :: ResourceDataSyncDestinationDataSharing
-> ResourceDataSyncDestinationDataSharing -> Bool
Prelude.Eq, ReadPrec [ResourceDataSyncDestinationDataSharing]
ReadPrec ResourceDataSyncDestinationDataSharing
Int -> ReadS ResourceDataSyncDestinationDataSharing
ReadS [ResourceDataSyncDestinationDataSharing]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ResourceDataSyncDestinationDataSharing]
$creadListPrec :: ReadPrec [ResourceDataSyncDestinationDataSharing]
readPrec :: ReadPrec ResourceDataSyncDestinationDataSharing
$creadPrec :: ReadPrec ResourceDataSyncDestinationDataSharing
readList :: ReadS [ResourceDataSyncDestinationDataSharing]
$creadList :: ReadS [ResourceDataSyncDestinationDataSharing]
readsPrec :: Int -> ReadS ResourceDataSyncDestinationDataSharing
$creadsPrec :: Int -> ReadS ResourceDataSyncDestinationDataSharing
Prelude.Read, Int -> ResourceDataSyncDestinationDataSharing -> ShowS
[ResourceDataSyncDestinationDataSharing] -> ShowS
ResourceDataSyncDestinationDataSharing -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ResourceDataSyncDestinationDataSharing] -> ShowS
$cshowList :: [ResourceDataSyncDestinationDataSharing] -> ShowS
show :: ResourceDataSyncDestinationDataSharing -> String
$cshow :: ResourceDataSyncDestinationDataSharing -> String
showsPrec :: Int -> ResourceDataSyncDestinationDataSharing -> ShowS
$cshowsPrec :: Int -> ResourceDataSyncDestinationDataSharing -> ShowS
Prelude.Show, forall x.
Rep ResourceDataSyncDestinationDataSharing x
-> ResourceDataSyncDestinationDataSharing
forall x.
ResourceDataSyncDestinationDataSharing
-> Rep ResourceDataSyncDestinationDataSharing x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ResourceDataSyncDestinationDataSharing x
-> ResourceDataSyncDestinationDataSharing
$cfrom :: forall x.
ResourceDataSyncDestinationDataSharing
-> Rep ResourceDataSyncDestinationDataSharing x
Prelude.Generic)
newResourceDataSyncDestinationDataSharing ::
ResourceDataSyncDestinationDataSharing
newResourceDataSyncDestinationDataSharing :: ResourceDataSyncDestinationDataSharing
newResourceDataSyncDestinationDataSharing =
ResourceDataSyncDestinationDataSharing'
{ $sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: Maybe Text
destinationDataSharingType =
forall a. Maybe a
Prelude.Nothing
}
resourceDataSyncDestinationDataSharing_destinationDataSharingType :: Lens.Lens' ResourceDataSyncDestinationDataSharing (Prelude.Maybe Prelude.Text)
resourceDataSyncDestinationDataSharing_destinationDataSharingType :: Lens' ResourceDataSyncDestinationDataSharing (Maybe Text)
resourceDataSyncDestinationDataSharing_destinationDataSharingType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceDataSyncDestinationDataSharing' {Maybe Text
destinationDataSharingType :: Maybe Text
$sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: ResourceDataSyncDestinationDataSharing -> Maybe Text
destinationDataSharingType} -> Maybe Text
destinationDataSharingType) (\s :: ResourceDataSyncDestinationDataSharing
s@ResourceDataSyncDestinationDataSharing' {} Maybe Text
a -> ResourceDataSyncDestinationDataSharing
s {$sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: Maybe Text
destinationDataSharingType = Maybe Text
a} :: ResourceDataSyncDestinationDataSharing)
instance
Data.FromJSON
ResourceDataSyncDestinationDataSharing
where
parseJSON :: Value -> Parser ResourceDataSyncDestinationDataSharing
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ResourceDataSyncDestinationDataSharing"
( \Object
x ->
Maybe Text -> ResourceDataSyncDestinationDataSharing
ResourceDataSyncDestinationDataSharing'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"DestinationDataSharingType")
)
instance
Prelude.Hashable
ResourceDataSyncDestinationDataSharing
where
hashWithSalt :: Int -> ResourceDataSyncDestinationDataSharing -> Int
hashWithSalt
Int
_salt
ResourceDataSyncDestinationDataSharing' {Maybe Text
destinationDataSharingType :: Maybe Text
$sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: ResourceDataSyncDestinationDataSharing -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
destinationDataSharingType
instance
Prelude.NFData
ResourceDataSyncDestinationDataSharing
where
rnf :: ResourceDataSyncDestinationDataSharing -> ()
rnf ResourceDataSyncDestinationDataSharing' {Maybe Text
destinationDataSharingType :: Maybe Text
$sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: ResourceDataSyncDestinationDataSharing -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
destinationDataSharingType
instance
Data.ToJSON
ResourceDataSyncDestinationDataSharing
where
toJSON :: ResourceDataSyncDestinationDataSharing -> Value
toJSON ResourceDataSyncDestinationDataSharing' {Maybe Text
destinationDataSharingType :: Maybe Text
$sel:destinationDataSharingType:ResourceDataSyncDestinationDataSharing' :: ResourceDataSyncDestinationDataSharing -> Maybe Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"DestinationDataSharingType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
destinationDataSharingType
]
)