{-# 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.AppFlow.Types.InforNexusConnectorProfileCredentials where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data InforNexusConnectorProfileCredentials = InforNexusConnectorProfileCredentials'
{
InforNexusConnectorProfileCredentials -> Sensitive Text
accessKeyId :: Core.Sensitive Prelude.Text,
InforNexusConnectorProfileCredentials -> Text
userId :: Prelude.Text,
InforNexusConnectorProfileCredentials -> Text
secretAccessKey :: Prelude.Text,
InforNexusConnectorProfileCredentials -> Text
datakey :: Prelude.Text
}
deriving (InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool
(InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool)
-> (InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool)
-> Eq InforNexusConnectorProfileCredentials
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool
$c/= :: InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool
== :: InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool
$c== :: InforNexusConnectorProfileCredentials
-> InforNexusConnectorProfileCredentials -> Bool
Prelude.Eq, Int -> InforNexusConnectorProfileCredentials -> ShowS
[InforNexusConnectorProfileCredentials] -> ShowS
InforNexusConnectorProfileCredentials -> String
(Int -> InforNexusConnectorProfileCredentials -> ShowS)
-> (InforNexusConnectorProfileCredentials -> String)
-> ([InforNexusConnectorProfileCredentials] -> ShowS)
-> Show InforNexusConnectorProfileCredentials
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InforNexusConnectorProfileCredentials] -> ShowS
$cshowList :: [InforNexusConnectorProfileCredentials] -> ShowS
show :: InforNexusConnectorProfileCredentials -> String
$cshow :: InforNexusConnectorProfileCredentials -> String
showsPrec :: Int -> InforNexusConnectorProfileCredentials -> ShowS
$cshowsPrec :: Int -> InforNexusConnectorProfileCredentials -> ShowS
Prelude.Show, (forall x.
InforNexusConnectorProfileCredentials
-> Rep InforNexusConnectorProfileCredentials x)
-> (forall x.
Rep InforNexusConnectorProfileCredentials x
-> InforNexusConnectorProfileCredentials)
-> Generic InforNexusConnectorProfileCredentials
forall x.
Rep InforNexusConnectorProfileCredentials x
-> InforNexusConnectorProfileCredentials
forall x.
InforNexusConnectorProfileCredentials
-> Rep InforNexusConnectorProfileCredentials x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep InforNexusConnectorProfileCredentials x
-> InforNexusConnectorProfileCredentials
$cfrom :: forall x.
InforNexusConnectorProfileCredentials
-> Rep InforNexusConnectorProfileCredentials x
Prelude.Generic)
newInforNexusConnectorProfileCredentials ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
InforNexusConnectorProfileCredentials
newInforNexusConnectorProfileCredentials :: Text
-> Text -> Text -> Text -> InforNexusConnectorProfileCredentials
newInforNexusConnectorProfileCredentials
Text
pAccessKeyId_
Text
pUserId_
Text
pSecretAccessKey_
Text
pDatakey_ =
InforNexusConnectorProfileCredentials' :: Sensitive Text
-> Text -> Text -> Text -> InforNexusConnectorProfileCredentials
InforNexusConnectorProfileCredentials'
{ $sel:accessKeyId:InforNexusConnectorProfileCredentials' :: Sensitive Text
accessKeyId =
Tagged Text (Identity Text)
-> Tagged (Sensitive Text) (Identity (Sensitive Text))
forall a. Iso' (Sensitive a) a
Core._Sensitive
(Tagged Text (Identity Text)
-> Tagged (Sensitive Text) (Identity (Sensitive Text)))
-> Text -> Sensitive Text
forall t b. AReview t b -> b -> t
Lens.# Text
pAccessKeyId_,
$sel:userId:InforNexusConnectorProfileCredentials' :: Text
userId = Text
pUserId_,
$sel:secretAccessKey:InforNexusConnectorProfileCredentials' :: Text
secretAccessKey = Text
pSecretAccessKey_,
$sel:datakey:InforNexusConnectorProfileCredentials' :: Text
datakey = Text
pDatakey_
}
inforNexusConnectorProfileCredentials_accessKeyId :: Lens.Lens' InforNexusConnectorProfileCredentials Prelude.Text
inforNexusConnectorProfileCredentials_accessKeyId :: (Text -> f Text)
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials
inforNexusConnectorProfileCredentials_accessKeyId = (InforNexusConnectorProfileCredentials -> Sensitive Text)
-> (InforNexusConnectorProfileCredentials
-> Sensitive Text -> InforNexusConnectorProfileCredentials)
-> Lens
InforNexusConnectorProfileCredentials
InforNexusConnectorProfileCredentials
(Sensitive Text)
(Sensitive Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InforNexusConnectorProfileCredentials' {Sensitive Text
accessKeyId :: Sensitive Text
$sel:accessKeyId:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Sensitive Text
accessKeyId} -> Sensitive Text
accessKeyId) (\s :: InforNexusConnectorProfileCredentials
s@InforNexusConnectorProfileCredentials' {} Sensitive Text
a -> InforNexusConnectorProfileCredentials
s {$sel:accessKeyId:InforNexusConnectorProfileCredentials' :: Sensitive Text
accessKeyId = Sensitive Text
a} :: InforNexusConnectorProfileCredentials) ((Sensitive Text -> f (Sensitive Text))
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials)
-> ((Text -> f Text) -> Sensitive Text -> f (Sensitive Text))
-> (Text -> f Text)
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> f Text) -> Sensitive Text -> f (Sensitive Text)
forall a. Iso' (Sensitive a) a
Core._Sensitive
inforNexusConnectorProfileCredentials_userId :: Lens.Lens' InforNexusConnectorProfileCredentials Prelude.Text
inforNexusConnectorProfileCredentials_userId :: (Text -> f Text)
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials
inforNexusConnectorProfileCredentials_userId = (InforNexusConnectorProfileCredentials -> Text)
-> (InforNexusConnectorProfileCredentials
-> Text -> InforNexusConnectorProfileCredentials)
-> Lens
InforNexusConnectorProfileCredentials
InforNexusConnectorProfileCredentials
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InforNexusConnectorProfileCredentials' {Text
userId :: Text
$sel:userId:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
userId} -> Text
userId) (\s :: InforNexusConnectorProfileCredentials
s@InforNexusConnectorProfileCredentials' {} Text
a -> InforNexusConnectorProfileCredentials
s {$sel:userId:InforNexusConnectorProfileCredentials' :: Text
userId = Text
a} :: InforNexusConnectorProfileCredentials)
inforNexusConnectorProfileCredentials_secretAccessKey :: Lens.Lens' InforNexusConnectorProfileCredentials Prelude.Text
inforNexusConnectorProfileCredentials_secretAccessKey :: (Text -> f Text)
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials
inforNexusConnectorProfileCredentials_secretAccessKey = (InforNexusConnectorProfileCredentials -> Text)
-> (InforNexusConnectorProfileCredentials
-> Text -> InforNexusConnectorProfileCredentials)
-> Lens
InforNexusConnectorProfileCredentials
InforNexusConnectorProfileCredentials
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InforNexusConnectorProfileCredentials' {Text
secretAccessKey :: Text
$sel:secretAccessKey:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
secretAccessKey} -> Text
secretAccessKey) (\s :: InforNexusConnectorProfileCredentials
s@InforNexusConnectorProfileCredentials' {} Text
a -> InforNexusConnectorProfileCredentials
s {$sel:secretAccessKey:InforNexusConnectorProfileCredentials' :: Text
secretAccessKey = Text
a} :: InforNexusConnectorProfileCredentials)
inforNexusConnectorProfileCredentials_datakey :: Lens.Lens' InforNexusConnectorProfileCredentials Prelude.Text
inforNexusConnectorProfileCredentials_datakey :: (Text -> f Text)
-> InforNexusConnectorProfileCredentials
-> f InforNexusConnectorProfileCredentials
inforNexusConnectorProfileCredentials_datakey = (InforNexusConnectorProfileCredentials -> Text)
-> (InforNexusConnectorProfileCredentials
-> Text -> InforNexusConnectorProfileCredentials)
-> Lens
InforNexusConnectorProfileCredentials
InforNexusConnectorProfileCredentials
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InforNexusConnectorProfileCredentials' {Text
datakey :: Text
$sel:datakey:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
datakey} -> Text
datakey) (\s :: InforNexusConnectorProfileCredentials
s@InforNexusConnectorProfileCredentials' {} Text
a -> InforNexusConnectorProfileCredentials
s {$sel:datakey:InforNexusConnectorProfileCredentials' :: Text
datakey = Text
a} :: InforNexusConnectorProfileCredentials)
instance
Prelude.Hashable
InforNexusConnectorProfileCredentials
instance
Prelude.NFData
InforNexusConnectorProfileCredentials
instance
Core.ToJSON
InforNexusConnectorProfileCredentials
where
toJSON :: InforNexusConnectorProfileCredentials -> Value
toJSON InforNexusConnectorProfileCredentials' {Text
Sensitive Text
datakey :: Text
secretAccessKey :: Text
userId :: Text
accessKeyId :: Sensitive Text
$sel:datakey:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
$sel:secretAccessKey:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
$sel:userId:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Text
$sel:accessKeyId:InforNexusConnectorProfileCredentials' :: InforNexusConnectorProfileCredentials -> Sensitive Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"accessKeyId" Text -> Sensitive Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Sensitive Text
accessKeyId),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"userId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
userId),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
(Text
"secretAccessKey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
secretAccessKey),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"datakey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
datakey)
]
)