{-# 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.Config.Types.AggregateComplianceByConformancePack where
import Amazonka.Config.Types.AggregateConformancePackCompliance
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data AggregateComplianceByConformancePack = AggregateComplianceByConformancePack'
{
AggregateComplianceByConformancePack
-> Maybe AggregateConformancePackCompliance
compliance :: Prelude.Maybe AggregateConformancePackCompliance,
AggregateComplianceByConformancePack -> Maybe Text
conformancePackName :: Prelude.Maybe Prelude.Text,
AggregateComplianceByConformancePack -> Maybe Text
accountId :: Prelude.Maybe Prelude.Text,
AggregateComplianceByConformancePack -> Maybe Text
awsRegion :: Prelude.Maybe Prelude.Text
}
deriving (AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool
(AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool)
-> (AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool)
-> Eq AggregateComplianceByConformancePack
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool
$c/= :: AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool
== :: AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool
$c== :: AggregateComplianceByConformancePack
-> AggregateComplianceByConformancePack -> Bool
Prelude.Eq, ReadPrec [AggregateComplianceByConformancePack]
ReadPrec AggregateComplianceByConformancePack
Int -> ReadS AggregateComplianceByConformancePack
ReadS [AggregateComplianceByConformancePack]
(Int -> ReadS AggregateComplianceByConformancePack)
-> ReadS [AggregateComplianceByConformancePack]
-> ReadPrec AggregateComplianceByConformancePack
-> ReadPrec [AggregateComplianceByConformancePack]
-> Read AggregateComplianceByConformancePack
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AggregateComplianceByConformancePack]
$creadListPrec :: ReadPrec [AggregateComplianceByConformancePack]
readPrec :: ReadPrec AggregateComplianceByConformancePack
$creadPrec :: ReadPrec AggregateComplianceByConformancePack
readList :: ReadS [AggregateComplianceByConformancePack]
$creadList :: ReadS [AggregateComplianceByConformancePack]
readsPrec :: Int -> ReadS AggregateComplianceByConformancePack
$creadsPrec :: Int -> ReadS AggregateComplianceByConformancePack
Prelude.Read, Int -> AggregateComplianceByConformancePack -> ShowS
[AggregateComplianceByConformancePack] -> ShowS
AggregateComplianceByConformancePack -> String
(Int -> AggregateComplianceByConformancePack -> ShowS)
-> (AggregateComplianceByConformancePack -> String)
-> ([AggregateComplianceByConformancePack] -> ShowS)
-> Show AggregateComplianceByConformancePack
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AggregateComplianceByConformancePack] -> ShowS
$cshowList :: [AggregateComplianceByConformancePack] -> ShowS
show :: AggregateComplianceByConformancePack -> String
$cshow :: AggregateComplianceByConformancePack -> String
showsPrec :: Int -> AggregateComplianceByConformancePack -> ShowS
$cshowsPrec :: Int -> AggregateComplianceByConformancePack -> ShowS
Prelude.Show, (forall x.
AggregateComplianceByConformancePack
-> Rep AggregateComplianceByConformancePack x)
-> (forall x.
Rep AggregateComplianceByConformancePack x
-> AggregateComplianceByConformancePack)
-> Generic AggregateComplianceByConformancePack
forall x.
Rep AggregateComplianceByConformancePack x
-> AggregateComplianceByConformancePack
forall x.
AggregateComplianceByConformancePack
-> Rep AggregateComplianceByConformancePack x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep AggregateComplianceByConformancePack x
-> AggregateComplianceByConformancePack
$cfrom :: forall x.
AggregateComplianceByConformancePack
-> Rep AggregateComplianceByConformancePack x
Prelude.Generic)
newAggregateComplianceByConformancePack ::
AggregateComplianceByConformancePack
newAggregateComplianceByConformancePack :: AggregateComplianceByConformancePack
newAggregateComplianceByConformancePack =
AggregateComplianceByConformancePack' :: Maybe AggregateConformancePackCompliance
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AggregateComplianceByConformancePack
AggregateComplianceByConformancePack'
{ $sel:compliance:AggregateComplianceByConformancePack' :: Maybe AggregateConformancePackCompliance
compliance =
Maybe AggregateConformancePackCompliance
forall a. Maybe a
Prelude.Nothing,
$sel:conformancePackName:AggregateComplianceByConformancePack' :: Maybe Text
conformancePackName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:accountId:AggregateComplianceByConformancePack' :: Maybe Text
accountId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:awsRegion:AggregateComplianceByConformancePack' :: Maybe Text
awsRegion = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
aggregateComplianceByConformancePack_compliance :: Lens.Lens' AggregateComplianceByConformancePack (Prelude.Maybe AggregateConformancePackCompliance)
aggregateComplianceByConformancePack_compliance :: (Maybe AggregateConformancePackCompliance
-> f (Maybe AggregateConformancePackCompliance))
-> AggregateComplianceByConformancePack
-> f AggregateComplianceByConformancePack
aggregateComplianceByConformancePack_compliance = (AggregateComplianceByConformancePack
-> Maybe AggregateConformancePackCompliance)
-> (AggregateComplianceByConformancePack
-> Maybe AggregateConformancePackCompliance
-> AggregateComplianceByConformancePack)
-> Lens
AggregateComplianceByConformancePack
AggregateComplianceByConformancePack
(Maybe AggregateConformancePackCompliance)
(Maybe AggregateConformancePackCompliance)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AggregateComplianceByConformancePack' {Maybe AggregateConformancePackCompliance
compliance :: Maybe AggregateConformancePackCompliance
$sel:compliance:AggregateComplianceByConformancePack' :: AggregateComplianceByConformancePack
-> Maybe AggregateConformancePackCompliance
compliance} -> Maybe AggregateConformancePackCompliance
compliance) (\s :: AggregateComplianceByConformancePack
s@AggregateComplianceByConformancePack' {} Maybe AggregateConformancePackCompliance
a -> AggregateComplianceByConformancePack
s {$sel:compliance:AggregateComplianceByConformancePack' :: Maybe AggregateConformancePackCompliance
compliance = Maybe AggregateConformancePackCompliance
a} :: AggregateComplianceByConformancePack)
aggregateComplianceByConformancePack_conformancePackName :: Lens.Lens' AggregateComplianceByConformancePack (Prelude.Maybe Prelude.Text)
aggregateComplianceByConformancePack_conformancePackName :: (Maybe Text -> f (Maybe Text))
-> AggregateComplianceByConformancePack
-> f AggregateComplianceByConformancePack
aggregateComplianceByConformancePack_conformancePackName = (AggregateComplianceByConformancePack -> Maybe Text)
-> (AggregateComplianceByConformancePack
-> Maybe Text -> AggregateComplianceByConformancePack)
-> Lens
AggregateComplianceByConformancePack
AggregateComplianceByConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AggregateComplianceByConformancePack' {Maybe Text
conformancePackName :: Maybe Text
$sel:conformancePackName:AggregateComplianceByConformancePack' :: AggregateComplianceByConformancePack -> Maybe Text
conformancePackName} -> Maybe Text
conformancePackName) (\s :: AggregateComplianceByConformancePack
s@AggregateComplianceByConformancePack' {} Maybe Text
a -> AggregateComplianceByConformancePack
s {$sel:conformancePackName:AggregateComplianceByConformancePack' :: Maybe Text
conformancePackName = Maybe Text
a} :: AggregateComplianceByConformancePack)
aggregateComplianceByConformancePack_accountId :: Lens.Lens' AggregateComplianceByConformancePack (Prelude.Maybe Prelude.Text)
aggregateComplianceByConformancePack_accountId :: (Maybe Text -> f (Maybe Text))
-> AggregateComplianceByConformancePack
-> f AggregateComplianceByConformancePack
aggregateComplianceByConformancePack_accountId = (AggregateComplianceByConformancePack -> Maybe Text)
-> (AggregateComplianceByConformancePack
-> Maybe Text -> AggregateComplianceByConformancePack)
-> Lens
AggregateComplianceByConformancePack
AggregateComplianceByConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AggregateComplianceByConformancePack' {Maybe Text
accountId :: Maybe Text
$sel:accountId:AggregateComplianceByConformancePack' :: AggregateComplianceByConformancePack -> Maybe Text
accountId} -> Maybe Text
accountId) (\s :: AggregateComplianceByConformancePack
s@AggregateComplianceByConformancePack' {} Maybe Text
a -> AggregateComplianceByConformancePack
s {$sel:accountId:AggregateComplianceByConformancePack' :: Maybe Text
accountId = Maybe Text
a} :: AggregateComplianceByConformancePack)
aggregateComplianceByConformancePack_awsRegion :: Lens.Lens' AggregateComplianceByConformancePack (Prelude.Maybe Prelude.Text)
aggregateComplianceByConformancePack_awsRegion :: (Maybe Text -> f (Maybe Text))
-> AggregateComplianceByConformancePack
-> f AggregateComplianceByConformancePack
aggregateComplianceByConformancePack_awsRegion = (AggregateComplianceByConformancePack -> Maybe Text)
-> (AggregateComplianceByConformancePack
-> Maybe Text -> AggregateComplianceByConformancePack)
-> Lens
AggregateComplianceByConformancePack
AggregateComplianceByConformancePack
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AggregateComplianceByConformancePack' {Maybe Text
awsRegion :: Maybe Text
$sel:awsRegion:AggregateComplianceByConformancePack' :: AggregateComplianceByConformancePack -> Maybe Text
awsRegion} -> Maybe Text
awsRegion) (\s :: AggregateComplianceByConformancePack
s@AggregateComplianceByConformancePack' {} Maybe Text
a -> AggregateComplianceByConformancePack
s {$sel:awsRegion:AggregateComplianceByConformancePack' :: Maybe Text
awsRegion = Maybe Text
a} :: AggregateComplianceByConformancePack)
instance
Core.FromJSON
AggregateComplianceByConformancePack
where
parseJSON :: Value -> Parser AggregateComplianceByConformancePack
parseJSON =
String
-> (Object -> Parser AggregateComplianceByConformancePack)
-> Value
-> Parser AggregateComplianceByConformancePack
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AggregateComplianceByConformancePack"
( \Object
x ->
Maybe AggregateConformancePackCompliance
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AggregateComplianceByConformancePack
AggregateComplianceByConformancePack'
(Maybe AggregateConformancePackCompliance
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AggregateComplianceByConformancePack)
-> Parser (Maybe AggregateConformancePackCompliance)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> AggregateComplianceByConformancePack)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe AggregateConformancePackCompliance)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Compliance")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> AggregateComplianceByConformancePack)
-> Parser (Maybe Text)
-> Parser
(Maybe Text -> Maybe Text -> AggregateComplianceByConformancePack)
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
"ConformancePackName")
Parser
(Maybe Text -> Maybe Text -> AggregateComplianceByConformancePack)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> AggregateComplianceByConformancePack)
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
"AccountId")
Parser (Maybe Text -> AggregateComplianceByConformancePack)
-> Parser (Maybe Text)
-> Parser AggregateComplianceByConformancePack
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
"AwsRegion")
)
instance
Prelude.Hashable
AggregateComplianceByConformancePack
instance
Prelude.NFData
AggregateComplianceByConformancePack