{-# 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.EC2.Types.VerifiedAccessLogs where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.EC2.Internal
import Amazonka.EC2.Types.VerifiedAccessLogCloudWatchLogsDestination
import Amazonka.EC2.Types.VerifiedAccessLogKinesisDataFirehoseDestination
import Amazonka.EC2.Types.VerifiedAccessLogS3Destination
import qualified Amazonka.Prelude as Prelude
data VerifiedAccessLogs = VerifiedAccessLogs'
{
VerifiedAccessLogs
-> Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs :: Prelude.Maybe VerifiedAccessLogCloudWatchLogsDestination,
VerifiedAccessLogs
-> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose :: Prelude.Maybe VerifiedAccessLogKinesisDataFirehoseDestination,
VerifiedAccessLogs -> Maybe VerifiedAccessLogS3Destination
s3 :: Prelude.Maybe VerifiedAccessLogS3Destination
}
deriving (VerifiedAccessLogs -> VerifiedAccessLogs -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: VerifiedAccessLogs -> VerifiedAccessLogs -> Bool
$c/= :: VerifiedAccessLogs -> VerifiedAccessLogs -> Bool
== :: VerifiedAccessLogs -> VerifiedAccessLogs -> Bool
$c== :: VerifiedAccessLogs -> VerifiedAccessLogs -> Bool
Prelude.Eq, ReadPrec [VerifiedAccessLogs]
ReadPrec VerifiedAccessLogs
Int -> ReadS VerifiedAccessLogs
ReadS [VerifiedAccessLogs]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [VerifiedAccessLogs]
$creadListPrec :: ReadPrec [VerifiedAccessLogs]
readPrec :: ReadPrec VerifiedAccessLogs
$creadPrec :: ReadPrec VerifiedAccessLogs
readList :: ReadS [VerifiedAccessLogs]
$creadList :: ReadS [VerifiedAccessLogs]
readsPrec :: Int -> ReadS VerifiedAccessLogs
$creadsPrec :: Int -> ReadS VerifiedAccessLogs
Prelude.Read, Int -> VerifiedAccessLogs -> ShowS
[VerifiedAccessLogs] -> ShowS
VerifiedAccessLogs -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [VerifiedAccessLogs] -> ShowS
$cshowList :: [VerifiedAccessLogs] -> ShowS
show :: VerifiedAccessLogs -> String
$cshow :: VerifiedAccessLogs -> String
showsPrec :: Int -> VerifiedAccessLogs -> ShowS
$cshowsPrec :: Int -> VerifiedAccessLogs -> ShowS
Prelude.Show, forall x. Rep VerifiedAccessLogs x -> VerifiedAccessLogs
forall x. VerifiedAccessLogs -> Rep VerifiedAccessLogs x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep VerifiedAccessLogs x -> VerifiedAccessLogs
$cfrom :: forall x. VerifiedAccessLogs -> Rep VerifiedAccessLogs x
Prelude.Generic)
newVerifiedAccessLogs ::
VerifiedAccessLogs
newVerifiedAccessLogs :: VerifiedAccessLogs
newVerifiedAccessLogs =
VerifiedAccessLogs'
{ $sel:cloudWatchLogs:VerifiedAccessLogs' :: Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs =
forall a. Maybe a
Prelude.Nothing,
$sel:kinesisDataFirehose:VerifiedAccessLogs' :: Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose = forall a. Maybe a
Prelude.Nothing,
$sel:s3:VerifiedAccessLogs' :: Maybe VerifiedAccessLogS3Destination
s3 = forall a. Maybe a
Prelude.Nothing
}
verifiedAccessLogs_cloudWatchLogs :: Lens.Lens' VerifiedAccessLogs (Prelude.Maybe VerifiedAccessLogCloudWatchLogsDestination)
verifiedAccessLogs_cloudWatchLogs :: Lens'
VerifiedAccessLogs
(Maybe VerifiedAccessLogCloudWatchLogsDestination)
verifiedAccessLogs_cloudWatchLogs = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VerifiedAccessLogs' {Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs :: Maybe VerifiedAccessLogCloudWatchLogsDestination
$sel:cloudWatchLogs:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs} -> Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs) (\s :: VerifiedAccessLogs
s@VerifiedAccessLogs' {} Maybe VerifiedAccessLogCloudWatchLogsDestination
a -> VerifiedAccessLogs
s {$sel:cloudWatchLogs:VerifiedAccessLogs' :: Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs = Maybe VerifiedAccessLogCloudWatchLogsDestination
a} :: VerifiedAccessLogs)
verifiedAccessLogs_kinesisDataFirehose :: Lens.Lens' VerifiedAccessLogs (Prelude.Maybe VerifiedAccessLogKinesisDataFirehoseDestination)
verifiedAccessLogs_kinesisDataFirehose :: Lens'
VerifiedAccessLogs
(Maybe VerifiedAccessLogKinesisDataFirehoseDestination)
verifiedAccessLogs_kinesisDataFirehose = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VerifiedAccessLogs' {Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose :: Maybe VerifiedAccessLogKinesisDataFirehoseDestination
$sel:kinesisDataFirehose:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose} -> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose) (\s :: VerifiedAccessLogs
s@VerifiedAccessLogs' {} Maybe VerifiedAccessLogKinesisDataFirehoseDestination
a -> VerifiedAccessLogs
s {$sel:kinesisDataFirehose:VerifiedAccessLogs' :: Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose = Maybe VerifiedAccessLogKinesisDataFirehoseDestination
a} :: VerifiedAccessLogs)
verifiedAccessLogs_s3 :: Lens.Lens' VerifiedAccessLogs (Prelude.Maybe VerifiedAccessLogS3Destination)
verifiedAccessLogs_s3 :: Lens' VerifiedAccessLogs (Maybe VerifiedAccessLogS3Destination)
verifiedAccessLogs_s3 = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VerifiedAccessLogs' {Maybe VerifiedAccessLogS3Destination
s3 :: Maybe VerifiedAccessLogS3Destination
$sel:s3:VerifiedAccessLogs' :: VerifiedAccessLogs -> Maybe VerifiedAccessLogS3Destination
s3} -> Maybe VerifiedAccessLogS3Destination
s3) (\s :: VerifiedAccessLogs
s@VerifiedAccessLogs' {} Maybe VerifiedAccessLogS3Destination
a -> VerifiedAccessLogs
s {$sel:s3:VerifiedAccessLogs' :: Maybe VerifiedAccessLogS3Destination
s3 = Maybe VerifiedAccessLogS3Destination
a} :: VerifiedAccessLogs)
instance Data.FromXML VerifiedAccessLogs where
parseXML :: [Node] -> Either String VerifiedAccessLogs
parseXML [Node]
x =
Maybe VerifiedAccessLogCloudWatchLogsDestination
-> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
-> Maybe VerifiedAccessLogS3Destination
-> VerifiedAccessLogs
VerifiedAccessLogs'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"cloudWatchLogs")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"kinesisDataFirehose")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"s3")
instance Prelude.Hashable VerifiedAccessLogs where
hashWithSalt :: Int -> VerifiedAccessLogs -> Int
hashWithSalt Int
_salt VerifiedAccessLogs' {Maybe VerifiedAccessLogCloudWatchLogsDestination
Maybe VerifiedAccessLogKinesisDataFirehoseDestination
Maybe VerifiedAccessLogS3Destination
s3 :: Maybe VerifiedAccessLogS3Destination
kinesisDataFirehose :: Maybe VerifiedAccessLogKinesisDataFirehoseDestination
cloudWatchLogs :: Maybe VerifiedAccessLogCloudWatchLogsDestination
$sel:s3:VerifiedAccessLogs' :: VerifiedAccessLogs -> Maybe VerifiedAccessLogS3Destination
$sel:kinesisDataFirehose:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
$sel:cloudWatchLogs:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogCloudWatchLogsDestination
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VerifiedAccessLogS3Destination
s3
instance Prelude.NFData VerifiedAccessLogs where
rnf :: VerifiedAccessLogs -> ()
rnf VerifiedAccessLogs' {Maybe VerifiedAccessLogCloudWatchLogsDestination
Maybe VerifiedAccessLogKinesisDataFirehoseDestination
Maybe VerifiedAccessLogS3Destination
s3 :: Maybe VerifiedAccessLogS3Destination
kinesisDataFirehose :: Maybe VerifiedAccessLogKinesisDataFirehoseDestination
cloudWatchLogs :: Maybe VerifiedAccessLogCloudWatchLogsDestination
$sel:s3:VerifiedAccessLogs' :: VerifiedAccessLogs -> Maybe VerifiedAccessLogS3Destination
$sel:kinesisDataFirehose:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogKinesisDataFirehoseDestination
$sel:cloudWatchLogs:VerifiedAccessLogs' :: VerifiedAccessLogs
-> Maybe VerifiedAccessLogCloudWatchLogsDestination
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe VerifiedAccessLogCloudWatchLogsDestination
cloudWatchLogs
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe VerifiedAccessLogKinesisDataFirehoseDestination
kinesisDataFirehose
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe VerifiedAccessLogS3Destination
s3