{-# 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.KinesisAnalytics.Types.KinesisFirehoseOutput where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data KinesisFirehoseOutput = KinesisFirehoseOutput'
{
KinesisFirehoseOutput -> Text
resourceARN :: Prelude.Text,
KinesisFirehoseOutput -> Text
roleARN :: Prelude.Text
}
deriving (KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool
(KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool)
-> (KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool)
-> Eq KinesisFirehoseOutput
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool
$c/= :: KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool
== :: KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool
$c== :: KinesisFirehoseOutput -> KinesisFirehoseOutput -> Bool
Prelude.Eq, ReadPrec [KinesisFirehoseOutput]
ReadPrec KinesisFirehoseOutput
Int -> ReadS KinesisFirehoseOutput
ReadS [KinesisFirehoseOutput]
(Int -> ReadS KinesisFirehoseOutput)
-> ReadS [KinesisFirehoseOutput]
-> ReadPrec KinesisFirehoseOutput
-> ReadPrec [KinesisFirehoseOutput]
-> Read KinesisFirehoseOutput
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [KinesisFirehoseOutput]
$creadListPrec :: ReadPrec [KinesisFirehoseOutput]
readPrec :: ReadPrec KinesisFirehoseOutput
$creadPrec :: ReadPrec KinesisFirehoseOutput
readList :: ReadS [KinesisFirehoseOutput]
$creadList :: ReadS [KinesisFirehoseOutput]
readsPrec :: Int -> ReadS KinesisFirehoseOutput
$creadsPrec :: Int -> ReadS KinesisFirehoseOutput
Prelude.Read, Int -> KinesisFirehoseOutput -> ShowS
[KinesisFirehoseOutput] -> ShowS
KinesisFirehoseOutput -> String
(Int -> KinesisFirehoseOutput -> ShowS)
-> (KinesisFirehoseOutput -> String)
-> ([KinesisFirehoseOutput] -> ShowS)
-> Show KinesisFirehoseOutput
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [KinesisFirehoseOutput] -> ShowS
$cshowList :: [KinesisFirehoseOutput] -> ShowS
show :: KinesisFirehoseOutput -> String
$cshow :: KinesisFirehoseOutput -> String
showsPrec :: Int -> KinesisFirehoseOutput -> ShowS
$cshowsPrec :: Int -> KinesisFirehoseOutput -> ShowS
Prelude.Show, (forall x. KinesisFirehoseOutput -> Rep KinesisFirehoseOutput x)
-> (forall x. Rep KinesisFirehoseOutput x -> KinesisFirehoseOutput)
-> Generic KinesisFirehoseOutput
forall x. Rep KinesisFirehoseOutput x -> KinesisFirehoseOutput
forall x. KinesisFirehoseOutput -> Rep KinesisFirehoseOutput x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep KinesisFirehoseOutput x -> KinesisFirehoseOutput
$cfrom :: forall x. KinesisFirehoseOutput -> Rep KinesisFirehoseOutput x
Prelude.Generic)
newKinesisFirehoseOutput ::
Prelude.Text ->
Prelude.Text ->
KinesisFirehoseOutput
newKinesisFirehoseOutput :: Text -> Text -> KinesisFirehoseOutput
newKinesisFirehoseOutput Text
pResourceARN_ Text
pRoleARN_ =
KinesisFirehoseOutput' :: Text -> Text -> KinesisFirehoseOutput
KinesisFirehoseOutput'
{ $sel:resourceARN:KinesisFirehoseOutput' :: Text
resourceARN = Text
pResourceARN_,
$sel:roleARN:KinesisFirehoseOutput' :: Text
roleARN = Text
pRoleARN_
}
kinesisFirehoseOutput_resourceARN :: Lens.Lens' KinesisFirehoseOutput Prelude.Text
kinesisFirehoseOutput_resourceARN :: (Text -> f Text)
-> KinesisFirehoseOutput -> f KinesisFirehoseOutput
kinesisFirehoseOutput_resourceARN = (KinesisFirehoseOutput -> Text)
-> (KinesisFirehoseOutput -> Text -> KinesisFirehoseOutput)
-> Lens KinesisFirehoseOutput KinesisFirehoseOutput Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\KinesisFirehoseOutput' {Text
resourceARN :: Text
$sel:resourceARN:KinesisFirehoseOutput' :: KinesisFirehoseOutput -> Text
resourceARN} -> Text
resourceARN) (\s :: KinesisFirehoseOutput
s@KinesisFirehoseOutput' {} Text
a -> KinesisFirehoseOutput
s {$sel:resourceARN:KinesisFirehoseOutput' :: Text
resourceARN = Text
a} :: KinesisFirehoseOutput)
kinesisFirehoseOutput_roleARN :: Lens.Lens' KinesisFirehoseOutput Prelude.Text
kinesisFirehoseOutput_roleARN :: (Text -> f Text)
-> KinesisFirehoseOutput -> f KinesisFirehoseOutput
kinesisFirehoseOutput_roleARN = (KinesisFirehoseOutput -> Text)
-> (KinesisFirehoseOutput -> Text -> KinesisFirehoseOutput)
-> Lens KinesisFirehoseOutput KinesisFirehoseOutput Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\KinesisFirehoseOutput' {Text
roleARN :: Text
$sel:roleARN:KinesisFirehoseOutput' :: KinesisFirehoseOutput -> Text
roleARN} -> Text
roleARN) (\s :: KinesisFirehoseOutput
s@KinesisFirehoseOutput' {} Text
a -> KinesisFirehoseOutput
s {$sel:roleARN:KinesisFirehoseOutput' :: Text
roleARN = Text
a} :: KinesisFirehoseOutput)
instance Prelude.Hashable KinesisFirehoseOutput
instance Prelude.NFData KinesisFirehoseOutput
instance Core.ToJSON KinesisFirehoseOutput where
toJSON :: KinesisFirehoseOutput -> Value
toJSON KinesisFirehoseOutput' {Text
roleARN :: Text
resourceARN :: Text
$sel:roleARN:KinesisFirehoseOutput' :: KinesisFirehoseOutput -> Text
$sel:resourceARN:KinesisFirehoseOutput' :: KinesisFirehoseOutput -> 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
"ResourceARN" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
resourceARN),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"RoleARN" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
roleARN)
]
)