{-# 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.KinesisAnalyticsV2.Types.KinesisStreamsOutputDescription where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data KinesisStreamsOutputDescription = KinesisStreamsOutputDescription'
{
KinesisStreamsOutputDescription -> Maybe Text
roleARN :: Prelude.Maybe Prelude.Text,
KinesisStreamsOutputDescription -> Text
resourceARN :: Prelude.Text
}
deriving (KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool
(KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool)
-> (KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool)
-> Eq KinesisStreamsOutputDescription
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool
$c/= :: KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool
== :: KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool
$c== :: KinesisStreamsOutputDescription
-> KinesisStreamsOutputDescription -> Bool
Prelude.Eq, ReadPrec [KinesisStreamsOutputDescription]
ReadPrec KinesisStreamsOutputDescription
Int -> ReadS KinesisStreamsOutputDescription
ReadS [KinesisStreamsOutputDescription]
(Int -> ReadS KinesisStreamsOutputDescription)
-> ReadS [KinesisStreamsOutputDescription]
-> ReadPrec KinesisStreamsOutputDescription
-> ReadPrec [KinesisStreamsOutputDescription]
-> Read KinesisStreamsOutputDescription
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [KinesisStreamsOutputDescription]
$creadListPrec :: ReadPrec [KinesisStreamsOutputDescription]
readPrec :: ReadPrec KinesisStreamsOutputDescription
$creadPrec :: ReadPrec KinesisStreamsOutputDescription
readList :: ReadS [KinesisStreamsOutputDescription]
$creadList :: ReadS [KinesisStreamsOutputDescription]
readsPrec :: Int -> ReadS KinesisStreamsOutputDescription
$creadsPrec :: Int -> ReadS KinesisStreamsOutputDescription
Prelude.Read, Int -> KinesisStreamsOutputDescription -> ShowS
[KinesisStreamsOutputDescription] -> ShowS
KinesisStreamsOutputDescription -> String
(Int -> KinesisStreamsOutputDescription -> ShowS)
-> (KinesisStreamsOutputDescription -> String)
-> ([KinesisStreamsOutputDescription] -> ShowS)
-> Show KinesisStreamsOutputDescription
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [KinesisStreamsOutputDescription] -> ShowS
$cshowList :: [KinesisStreamsOutputDescription] -> ShowS
show :: KinesisStreamsOutputDescription -> String
$cshow :: KinesisStreamsOutputDescription -> String
showsPrec :: Int -> KinesisStreamsOutputDescription -> ShowS
$cshowsPrec :: Int -> KinesisStreamsOutputDescription -> ShowS
Prelude.Show, (forall x.
KinesisStreamsOutputDescription
-> Rep KinesisStreamsOutputDescription x)
-> (forall x.
Rep KinesisStreamsOutputDescription x
-> KinesisStreamsOutputDescription)
-> Generic KinesisStreamsOutputDescription
forall x.
Rep KinesisStreamsOutputDescription x
-> KinesisStreamsOutputDescription
forall x.
KinesisStreamsOutputDescription
-> Rep KinesisStreamsOutputDescription x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep KinesisStreamsOutputDescription x
-> KinesisStreamsOutputDescription
$cfrom :: forall x.
KinesisStreamsOutputDescription
-> Rep KinesisStreamsOutputDescription x
Prelude.Generic)
newKinesisStreamsOutputDescription ::
Prelude.Text ->
KinesisStreamsOutputDescription
newKinesisStreamsOutputDescription :: Text -> KinesisStreamsOutputDescription
newKinesisStreamsOutputDescription Text
pResourceARN_ =
KinesisStreamsOutputDescription' :: Maybe Text -> Text -> KinesisStreamsOutputDescription
KinesisStreamsOutputDescription'
{ $sel:roleARN:KinesisStreamsOutputDescription' :: Maybe Text
roleARN =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:resourceARN:KinesisStreamsOutputDescription' :: Text
resourceARN = Text
pResourceARN_
}
kinesisStreamsOutputDescription_roleARN :: Lens.Lens' KinesisStreamsOutputDescription (Prelude.Maybe Prelude.Text)
kinesisStreamsOutputDescription_roleARN :: (Maybe Text -> f (Maybe Text))
-> KinesisStreamsOutputDescription
-> f KinesisStreamsOutputDescription
kinesisStreamsOutputDescription_roleARN = (KinesisStreamsOutputDescription -> Maybe Text)
-> (KinesisStreamsOutputDescription
-> Maybe Text -> KinesisStreamsOutputDescription)
-> Lens
KinesisStreamsOutputDescription
KinesisStreamsOutputDescription
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\KinesisStreamsOutputDescription' {Maybe Text
roleARN :: Maybe Text
$sel:roleARN:KinesisStreamsOutputDescription' :: KinesisStreamsOutputDescription -> Maybe Text
roleARN} -> Maybe Text
roleARN) (\s :: KinesisStreamsOutputDescription
s@KinesisStreamsOutputDescription' {} Maybe Text
a -> KinesisStreamsOutputDescription
s {$sel:roleARN:KinesisStreamsOutputDescription' :: Maybe Text
roleARN = Maybe Text
a} :: KinesisStreamsOutputDescription)
kinesisStreamsOutputDescription_resourceARN :: Lens.Lens' KinesisStreamsOutputDescription Prelude.Text
kinesisStreamsOutputDescription_resourceARN :: (Text -> f Text)
-> KinesisStreamsOutputDescription
-> f KinesisStreamsOutputDescription
kinesisStreamsOutputDescription_resourceARN = (KinesisStreamsOutputDescription -> Text)
-> (KinesisStreamsOutputDescription
-> Text -> KinesisStreamsOutputDescription)
-> Lens
KinesisStreamsOutputDescription
KinesisStreamsOutputDescription
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\KinesisStreamsOutputDescription' {Text
resourceARN :: Text
$sel:resourceARN:KinesisStreamsOutputDescription' :: KinesisStreamsOutputDescription -> Text
resourceARN} -> Text
resourceARN) (\s :: KinesisStreamsOutputDescription
s@KinesisStreamsOutputDescription' {} Text
a -> KinesisStreamsOutputDescription
s {$sel:resourceARN:KinesisStreamsOutputDescription' :: Text
resourceARN = Text
a} :: KinesisStreamsOutputDescription)
instance
Core.FromJSON
KinesisStreamsOutputDescription
where
parseJSON :: Value -> Parser KinesisStreamsOutputDescription
parseJSON =
String
-> (Object -> Parser KinesisStreamsOutputDescription)
-> Value
-> Parser KinesisStreamsOutputDescription
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"KinesisStreamsOutputDescription"
( \Object
x ->
Maybe Text -> Text -> KinesisStreamsOutputDescription
KinesisStreamsOutputDescription'
(Maybe Text -> Text -> KinesisStreamsOutputDescription)
-> Parser (Maybe Text)
-> Parser (Text -> KinesisStreamsOutputDescription)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RoleARN")
Parser (Text -> KinesisStreamsOutputDescription)
-> Parser Text -> Parser KinesisStreamsOutputDescription
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"ResourceARN")
)
instance
Prelude.Hashable
KinesisStreamsOutputDescription
instance
Prelude.NFData
KinesisStreamsOutputDescription