{-# 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.RDS.Types.CloudwatchLogsExportConfiguration 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 CloudwatchLogsExportConfiguration = CloudwatchLogsExportConfiguration'
{
CloudwatchLogsExportConfiguration -> Maybe [Text]
disableLogTypes :: Prelude.Maybe [Prelude.Text],
CloudwatchLogsExportConfiguration -> Maybe [Text]
enableLogTypes :: Prelude.Maybe [Prelude.Text]
}
deriving (CloudwatchLogsExportConfiguration
-> CloudwatchLogsExportConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CloudwatchLogsExportConfiguration
-> CloudwatchLogsExportConfiguration -> Bool
$c/= :: CloudwatchLogsExportConfiguration
-> CloudwatchLogsExportConfiguration -> Bool
== :: CloudwatchLogsExportConfiguration
-> CloudwatchLogsExportConfiguration -> Bool
$c== :: CloudwatchLogsExportConfiguration
-> CloudwatchLogsExportConfiguration -> Bool
Prelude.Eq, ReadPrec [CloudwatchLogsExportConfiguration]
ReadPrec CloudwatchLogsExportConfiguration
Int -> ReadS CloudwatchLogsExportConfiguration
ReadS [CloudwatchLogsExportConfiguration]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CloudwatchLogsExportConfiguration]
$creadListPrec :: ReadPrec [CloudwatchLogsExportConfiguration]
readPrec :: ReadPrec CloudwatchLogsExportConfiguration
$creadPrec :: ReadPrec CloudwatchLogsExportConfiguration
readList :: ReadS [CloudwatchLogsExportConfiguration]
$creadList :: ReadS [CloudwatchLogsExportConfiguration]
readsPrec :: Int -> ReadS CloudwatchLogsExportConfiguration
$creadsPrec :: Int -> ReadS CloudwatchLogsExportConfiguration
Prelude.Read, Int -> CloudwatchLogsExportConfiguration -> ShowS
[CloudwatchLogsExportConfiguration] -> ShowS
CloudwatchLogsExportConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CloudwatchLogsExportConfiguration] -> ShowS
$cshowList :: [CloudwatchLogsExportConfiguration] -> ShowS
show :: CloudwatchLogsExportConfiguration -> String
$cshow :: CloudwatchLogsExportConfiguration -> String
showsPrec :: Int -> CloudwatchLogsExportConfiguration -> ShowS
$cshowsPrec :: Int -> CloudwatchLogsExportConfiguration -> ShowS
Prelude.Show, forall x.
Rep CloudwatchLogsExportConfiguration x
-> CloudwatchLogsExportConfiguration
forall x.
CloudwatchLogsExportConfiguration
-> Rep CloudwatchLogsExportConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CloudwatchLogsExportConfiguration x
-> CloudwatchLogsExportConfiguration
$cfrom :: forall x.
CloudwatchLogsExportConfiguration
-> Rep CloudwatchLogsExportConfiguration x
Prelude.Generic)
newCloudwatchLogsExportConfiguration ::
CloudwatchLogsExportConfiguration
newCloudwatchLogsExportConfiguration :: CloudwatchLogsExportConfiguration
newCloudwatchLogsExportConfiguration =
CloudwatchLogsExportConfiguration'
{ $sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: Maybe [Text]
disableLogTypes =
forall a. Maybe a
Prelude.Nothing,
$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: Maybe [Text]
enableLogTypes = forall a. Maybe a
Prelude.Nothing
}
cloudwatchLogsExportConfiguration_disableLogTypes :: Lens.Lens' CloudwatchLogsExportConfiguration (Prelude.Maybe [Prelude.Text])
cloudwatchLogsExportConfiguration_disableLogTypes :: Lens' CloudwatchLogsExportConfiguration (Maybe [Text])
cloudwatchLogsExportConfiguration_disableLogTypes = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CloudwatchLogsExportConfiguration' {Maybe [Text]
disableLogTypes :: Maybe [Text]
$sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
disableLogTypes} -> Maybe [Text]
disableLogTypes) (\s :: CloudwatchLogsExportConfiguration
s@CloudwatchLogsExportConfiguration' {} Maybe [Text]
a -> CloudwatchLogsExportConfiguration
s {$sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: Maybe [Text]
disableLogTypes = Maybe [Text]
a} :: CloudwatchLogsExportConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
cloudwatchLogsExportConfiguration_enableLogTypes :: Lens.Lens' CloudwatchLogsExportConfiguration (Prelude.Maybe [Prelude.Text])
cloudwatchLogsExportConfiguration_enableLogTypes :: Lens' CloudwatchLogsExportConfiguration (Maybe [Text])
cloudwatchLogsExportConfiguration_enableLogTypes = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CloudwatchLogsExportConfiguration' {Maybe [Text]
enableLogTypes :: Maybe [Text]
$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
enableLogTypes} -> Maybe [Text]
enableLogTypes) (\s :: CloudwatchLogsExportConfiguration
s@CloudwatchLogsExportConfiguration' {} Maybe [Text]
a -> CloudwatchLogsExportConfiguration
s {$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: Maybe [Text]
enableLogTypes = Maybe [Text]
a} :: CloudwatchLogsExportConfiguration) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance
Prelude.Hashable
CloudwatchLogsExportConfiguration
where
hashWithSalt :: Int -> CloudwatchLogsExportConfiguration -> Int
hashWithSalt
Int
_salt
CloudwatchLogsExportConfiguration' {Maybe [Text]
enableLogTypes :: Maybe [Text]
disableLogTypes :: Maybe [Text]
$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
$sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
disableLogTypes
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
enableLogTypes
instance
Prelude.NFData
CloudwatchLogsExportConfiguration
where
rnf :: CloudwatchLogsExportConfiguration -> ()
rnf CloudwatchLogsExportConfiguration' {Maybe [Text]
enableLogTypes :: Maybe [Text]
disableLogTypes :: Maybe [Text]
$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
$sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
disableLogTypes
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
enableLogTypes
instance
Data.ToQuery
CloudwatchLogsExportConfiguration
where
toQuery :: CloudwatchLogsExportConfiguration -> QueryString
toQuery CloudwatchLogsExportConfiguration' {Maybe [Text]
enableLogTypes :: Maybe [Text]
disableLogTypes :: Maybe [Text]
$sel:enableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
$sel:disableLogTypes:CloudwatchLogsExportConfiguration' :: CloudwatchLogsExportConfiguration -> Maybe [Text]
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"DisableLogTypes"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: forall a. ToQuery a => a -> QueryString
Data.toQuery
( forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Data.toQueryList ByteString
"member"
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
disableLogTypes
),
ByteString
"EnableLogTypes"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: forall a. ToQuery a => a -> QueryString
Data.toQuery
( forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Data.toQueryList ByteString
"member"
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
enableLogTypes
)
]