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