{-# 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.MacieV2.Types.Finding where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MacieV2.Types.ClassificationDetails
import Amazonka.MacieV2.Types.FindingCategory
import Amazonka.MacieV2.Types.FindingType
import Amazonka.MacieV2.Types.PolicyDetails
import Amazonka.MacieV2.Types.ResourcesAffected
import Amazonka.MacieV2.Types.Severity
import qualified Amazonka.Prelude as Prelude
data Finding = Finding'
{
Finding -> Maybe ClassificationDetails
classificationDetails :: Prelude.Maybe ClassificationDetails,
Finding -> Maybe PolicyDetails
policyDetails :: Prelude.Maybe PolicyDetails,
Finding -> Maybe POSIX
createdAt :: Prelude.Maybe Core.POSIX,
Finding -> Maybe FindingCategory
category :: Prelude.Maybe FindingCategory,
Finding -> Maybe Severity
severity :: Prelude.Maybe Severity,
Finding -> Maybe Integer
count :: Prelude.Maybe Prelude.Integer,
Finding -> Maybe Text
schemaVersion :: Prelude.Maybe Prelude.Text,
Finding -> Maybe ResourcesAffected
resourcesAffected :: Prelude.Maybe ResourcesAffected,
Finding -> Maybe Text
accountId :: Prelude.Maybe Prelude.Text,
Finding -> Maybe Text
partition :: Prelude.Maybe Prelude.Text,
Finding -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
Finding -> Maybe Text
region :: Prelude.Maybe Prelude.Text,
Finding -> Maybe POSIX
updatedAt :: Prelude.Maybe Core.POSIX,
Finding -> Maybe Text
title :: Prelude.Maybe Prelude.Text,
Finding -> Maybe FindingType
type' :: Prelude.Maybe FindingType,
Finding -> Maybe Bool
archived :: Prelude.Maybe Prelude.Bool,
Finding -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
Finding -> Maybe Bool
sample :: Prelude.Maybe Prelude.Bool
}
deriving (Finding -> Finding -> Bool
(Finding -> Finding -> Bool)
-> (Finding -> Finding -> Bool) -> Eq Finding
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Finding -> Finding -> Bool
$c/= :: Finding -> Finding -> Bool
== :: Finding -> Finding -> Bool
$c== :: Finding -> Finding -> Bool
Prelude.Eq, ReadPrec [Finding]
ReadPrec Finding
Int -> ReadS Finding
ReadS [Finding]
(Int -> ReadS Finding)
-> ReadS [Finding]
-> ReadPrec Finding
-> ReadPrec [Finding]
-> Read Finding
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Finding]
$creadListPrec :: ReadPrec [Finding]
readPrec :: ReadPrec Finding
$creadPrec :: ReadPrec Finding
readList :: ReadS [Finding]
$creadList :: ReadS [Finding]
readsPrec :: Int -> ReadS Finding
$creadsPrec :: Int -> ReadS Finding
Prelude.Read, Int -> Finding -> ShowS
[Finding] -> ShowS
Finding -> String
(Int -> Finding -> ShowS)
-> (Finding -> String) -> ([Finding] -> ShowS) -> Show Finding
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Finding] -> ShowS
$cshowList :: [Finding] -> ShowS
show :: Finding -> String
$cshow :: Finding -> String
showsPrec :: Int -> Finding -> ShowS
$cshowsPrec :: Int -> Finding -> ShowS
Prelude.Show, (forall x. Finding -> Rep Finding x)
-> (forall x. Rep Finding x -> Finding) -> Generic Finding
forall x. Rep Finding x -> Finding
forall x. Finding -> Rep Finding x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Finding x -> Finding
$cfrom :: forall x. Finding -> Rep Finding x
Prelude.Generic)
newFinding ::
Finding
newFinding :: Finding
newFinding =
Finding' :: Maybe ClassificationDetails
-> Maybe PolicyDetails
-> Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding
Finding'
{ $sel:classificationDetails:Finding' :: Maybe ClassificationDetails
classificationDetails = Maybe ClassificationDetails
forall a. Maybe a
Prelude.Nothing,
$sel:policyDetails:Finding' :: Maybe PolicyDetails
policyDetails = Maybe PolicyDetails
forall a. Maybe a
Prelude.Nothing,
$sel:createdAt:Finding' :: Maybe POSIX
createdAt = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:category:Finding' :: Maybe FindingCategory
category = Maybe FindingCategory
forall a. Maybe a
Prelude.Nothing,
$sel:severity:Finding' :: Maybe Severity
severity = Maybe Severity
forall a. Maybe a
Prelude.Nothing,
$sel:count:Finding' :: Maybe Integer
count = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
$sel:schemaVersion:Finding' :: Maybe Text
schemaVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:resourcesAffected:Finding' :: Maybe ResourcesAffected
resourcesAffected = Maybe ResourcesAffected
forall a. Maybe a
Prelude.Nothing,
$sel:accountId:Finding' :: Maybe Text
accountId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:partition:Finding' :: Maybe Text
partition = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:id:Finding' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:region:Finding' :: Maybe Text
region = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:updatedAt:Finding' :: Maybe POSIX
updatedAt = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:title:Finding' :: Maybe Text
title = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:type':Finding' :: Maybe FindingType
type' = Maybe FindingType
forall a. Maybe a
Prelude.Nothing,
$sel:archived:Finding' :: Maybe Bool
archived = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:description:Finding' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sample:Finding' :: Maybe Bool
sample = Maybe Bool
forall a. Maybe a
Prelude.Nothing
}
finding_classificationDetails :: Lens.Lens' Finding (Prelude.Maybe ClassificationDetails)
finding_classificationDetails :: (Maybe ClassificationDetails -> f (Maybe ClassificationDetails))
-> Finding -> f Finding
finding_classificationDetails = (Finding -> Maybe ClassificationDetails)
-> (Finding -> Maybe ClassificationDetails -> Finding)
-> Lens
Finding
Finding
(Maybe ClassificationDetails)
(Maybe ClassificationDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe ClassificationDetails
classificationDetails :: Maybe ClassificationDetails
$sel:classificationDetails:Finding' :: Finding -> Maybe ClassificationDetails
classificationDetails} -> Maybe ClassificationDetails
classificationDetails) (\s :: Finding
s@Finding' {} Maybe ClassificationDetails
a -> Finding
s {$sel:classificationDetails:Finding' :: Maybe ClassificationDetails
classificationDetails = Maybe ClassificationDetails
a} :: Finding)
finding_policyDetails :: Lens.Lens' Finding (Prelude.Maybe PolicyDetails)
finding_policyDetails :: (Maybe PolicyDetails -> f (Maybe PolicyDetails))
-> Finding -> f Finding
finding_policyDetails = (Finding -> Maybe PolicyDetails)
-> (Finding -> Maybe PolicyDetails -> Finding)
-> Lens Finding Finding (Maybe PolicyDetails) (Maybe PolicyDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe PolicyDetails
policyDetails :: Maybe PolicyDetails
$sel:policyDetails:Finding' :: Finding -> Maybe PolicyDetails
policyDetails} -> Maybe PolicyDetails
policyDetails) (\s :: Finding
s@Finding' {} Maybe PolicyDetails
a -> Finding
s {$sel:policyDetails:Finding' :: Maybe PolicyDetails
policyDetails = Maybe PolicyDetails
a} :: Finding)
finding_createdAt :: Lens.Lens' Finding (Prelude.Maybe Prelude.UTCTime)
finding_createdAt :: (Maybe UTCTime -> f (Maybe UTCTime)) -> Finding -> f Finding
finding_createdAt = (Finding -> Maybe POSIX)
-> (Finding -> Maybe POSIX -> Finding)
-> Lens Finding Finding (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe POSIX
createdAt :: Maybe POSIX
$sel:createdAt:Finding' :: Finding -> Maybe POSIX
createdAt} -> Maybe POSIX
createdAt) (\s :: Finding
s@Finding' {} Maybe POSIX
a -> Finding
s {$sel:createdAt:Finding' :: Maybe POSIX
createdAt = Maybe POSIX
a} :: Finding) ((Maybe POSIX -> f (Maybe POSIX)) -> Finding -> f Finding)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> Finding
-> f Finding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
finding_category :: Lens.Lens' Finding (Prelude.Maybe FindingCategory)
finding_category :: (Maybe FindingCategory -> f (Maybe FindingCategory))
-> Finding -> f Finding
finding_category = (Finding -> Maybe FindingCategory)
-> (Finding -> Maybe FindingCategory -> Finding)
-> Lens
Finding Finding (Maybe FindingCategory) (Maybe FindingCategory)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe FindingCategory
category :: Maybe FindingCategory
$sel:category:Finding' :: Finding -> Maybe FindingCategory
category} -> Maybe FindingCategory
category) (\s :: Finding
s@Finding' {} Maybe FindingCategory
a -> Finding
s {$sel:category:Finding' :: Maybe FindingCategory
category = Maybe FindingCategory
a} :: Finding)
finding_severity :: Lens.Lens' Finding (Prelude.Maybe Severity)
finding_severity :: (Maybe Severity -> f (Maybe Severity)) -> Finding -> f Finding
finding_severity = (Finding -> Maybe Severity)
-> (Finding -> Maybe Severity -> Finding)
-> Lens Finding Finding (Maybe Severity) (Maybe Severity)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Severity
severity :: Maybe Severity
$sel:severity:Finding' :: Finding -> Maybe Severity
severity} -> Maybe Severity
severity) (\s :: Finding
s@Finding' {} Maybe Severity
a -> Finding
s {$sel:severity:Finding' :: Maybe Severity
severity = Maybe Severity
a} :: Finding)
finding_count :: Lens.Lens' Finding (Prelude.Maybe Prelude.Integer)
finding_count :: (Maybe Integer -> f (Maybe Integer)) -> Finding -> f Finding
finding_count = (Finding -> Maybe Integer)
-> (Finding -> Maybe Integer -> Finding)
-> Lens Finding Finding (Maybe Integer) (Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Integer
count :: Maybe Integer
$sel:count:Finding' :: Finding -> Maybe Integer
count} -> Maybe Integer
count) (\s :: Finding
s@Finding' {} Maybe Integer
a -> Finding
s {$sel:count:Finding' :: Maybe Integer
count = Maybe Integer
a} :: Finding)
finding_schemaVersion :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_schemaVersion :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_schemaVersion = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
schemaVersion :: Maybe Text
$sel:schemaVersion:Finding' :: Finding -> Maybe Text
schemaVersion} -> Maybe Text
schemaVersion) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:schemaVersion:Finding' :: Maybe Text
schemaVersion = Maybe Text
a} :: Finding)
finding_resourcesAffected :: Lens.Lens' Finding (Prelude.Maybe ResourcesAffected)
finding_resourcesAffected :: (Maybe ResourcesAffected -> f (Maybe ResourcesAffected))
-> Finding -> f Finding
finding_resourcesAffected = (Finding -> Maybe ResourcesAffected)
-> (Finding -> Maybe ResourcesAffected -> Finding)
-> Lens
Finding Finding (Maybe ResourcesAffected) (Maybe ResourcesAffected)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe ResourcesAffected
resourcesAffected :: Maybe ResourcesAffected
$sel:resourcesAffected:Finding' :: Finding -> Maybe ResourcesAffected
resourcesAffected} -> Maybe ResourcesAffected
resourcesAffected) (\s :: Finding
s@Finding' {} Maybe ResourcesAffected
a -> Finding
s {$sel:resourcesAffected:Finding' :: Maybe ResourcesAffected
resourcesAffected = Maybe ResourcesAffected
a} :: Finding)
finding_accountId :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_accountId :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_accountId = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
accountId :: Maybe Text
$sel:accountId:Finding' :: Finding -> Maybe Text
accountId} -> Maybe Text
accountId) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:accountId:Finding' :: Maybe Text
accountId = Maybe Text
a} :: Finding)
finding_partition :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_partition :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_partition = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
partition :: Maybe Text
$sel:partition:Finding' :: Finding -> Maybe Text
partition} -> Maybe Text
partition) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:partition:Finding' :: Maybe Text
partition = Maybe Text
a} :: Finding)
finding_id :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_id :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_id = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
id :: Maybe Text
$sel:id:Finding' :: Finding -> Maybe Text
id} -> Maybe Text
id) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:id:Finding' :: Maybe Text
id = Maybe Text
a} :: Finding)
finding_region :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_region :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_region = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
region :: Maybe Text
$sel:region:Finding' :: Finding -> Maybe Text
region} -> Maybe Text
region) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:region:Finding' :: Maybe Text
region = Maybe Text
a} :: Finding)
finding_updatedAt :: Lens.Lens' Finding (Prelude.Maybe Prelude.UTCTime)
finding_updatedAt :: (Maybe UTCTime -> f (Maybe UTCTime)) -> Finding -> f Finding
finding_updatedAt = (Finding -> Maybe POSIX)
-> (Finding -> Maybe POSIX -> Finding)
-> Lens Finding Finding (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe POSIX
updatedAt :: Maybe POSIX
$sel:updatedAt:Finding' :: Finding -> Maybe POSIX
updatedAt} -> Maybe POSIX
updatedAt) (\s :: Finding
s@Finding' {} Maybe POSIX
a -> Finding
s {$sel:updatedAt:Finding' :: Maybe POSIX
updatedAt = Maybe POSIX
a} :: Finding) ((Maybe POSIX -> f (Maybe POSIX)) -> Finding -> f Finding)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> Finding
-> f Finding
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
finding_title :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_title :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_title = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
title :: Maybe Text
$sel:title:Finding' :: Finding -> Maybe Text
title} -> Maybe Text
title) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:title:Finding' :: Maybe Text
title = Maybe Text
a} :: Finding)
finding_type :: Lens.Lens' Finding (Prelude.Maybe FindingType)
finding_type :: (Maybe FindingType -> f (Maybe FindingType))
-> Finding -> f Finding
finding_type = (Finding -> Maybe FindingType)
-> (Finding -> Maybe FindingType -> Finding)
-> Lens Finding Finding (Maybe FindingType) (Maybe FindingType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe FindingType
type' :: Maybe FindingType
$sel:type':Finding' :: Finding -> Maybe FindingType
type'} -> Maybe FindingType
type') (\s :: Finding
s@Finding' {} Maybe FindingType
a -> Finding
s {$sel:type':Finding' :: Maybe FindingType
type' = Maybe FindingType
a} :: Finding)
finding_archived :: Lens.Lens' Finding (Prelude.Maybe Prelude.Bool)
finding_archived :: (Maybe Bool -> f (Maybe Bool)) -> Finding -> f Finding
finding_archived = (Finding -> Maybe Bool)
-> (Finding -> Maybe Bool -> Finding)
-> Lens Finding Finding (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Bool
archived :: Maybe Bool
$sel:archived:Finding' :: Finding -> Maybe Bool
archived} -> Maybe Bool
archived) (\s :: Finding
s@Finding' {} Maybe Bool
a -> Finding
s {$sel:archived:Finding' :: Maybe Bool
archived = Maybe Bool
a} :: Finding)
finding_description :: Lens.Lens' Finding (Prelude.Maybe Prelude.Text)
finding_description :: (Maybe Text -> f (Maybe Text)) -> Finding -> f Finding
finding_description = (Finding -> Maybe Text)
-> (Finding -> Maybe Text -> Finding)
-> Lens Finding Finding (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Text
description :: Maybe Text
$sel:description:Finding' :: Finding -> Maybe Text
description} -> Maybe Text
description) (\s :: Finding
s@Finding' {} Maybe Text
a -> Finding
s {$sel:description:Finding' :: Maybe Text
description = Maybe Text
a} :: Finding)
finding_sample :: Lens.Lens' Finding (Prelude.Maybe Prelude.Bool)
finding_sample :: (Maybe Bool -> f (Maybe Bool)) -> Finding -> f Finding
finding_sample = (Finding -> Maybe Bool)
-> (Finding -> Maybe Bool -> Finding)
-> Lens Finding Finding (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Finding' {Maybe Bool
sample :: Maybe Bool
$sel:sample:Finding' :: Finding -> Maybe Bool
sample} -> Maybe Bool
sample) (\s :: Finding
s@Finding' {} Maybe Bool
a -> Finding
s {$sel:sample:Finding' :: Maybe Bool
sample = Maybe Bool
a} :: Finding)
instance Core.FromJSON Finding where
parseJSON :: Value -> Parser Finding
parseJSON =
String -> (Object -> Parser Finding) -> Value -> Parser Finding
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"Finding"
( \Object
x ->
Maybe ClassificationDetails
-> Maybe PolicyDetails
-> Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding
Finding'
(Maybe ClassificationDetails
-> Maybe PolicyDetails
-> Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe ClassificationDetails)
-> Parser
(Maybe PolicyDetails
-> Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe ClassificationDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"classificationDetails")
Parser
(Maybe PolicyDetails
-> Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe PolicyDetails)
-> Parser
(Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe PolicyDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"policyDetails")
Parser
(Maybe POSIX
-> Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe POSIX)
-> Parser
(Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"createdAt")
Parser
(Maybe FindingCategory
-> Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe FindingCategory)
-> Parser
(Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe FindingCategory)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"category")
Parser
(Maybe Severity
-> Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Severity)
-> Parser
(Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Severity)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"severity")
Parser
(Maybe Integer
-> Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Integer)
-> Parser
(Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"count")
Parser
(Maybe Text
-> Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
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
"schemaVersion")
Parser
(Maybe ResourcesAffected
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe ResourcesAffected)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ResourcesAffected)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"resourcesAffected")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
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
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
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
"partition")
Parser
(Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
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
"id")
Parser
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
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
"region")
Parser
(Maybe POSIX
-> Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"updatedAt")
Parser
(Maybe Text
-> Maybe FindingType
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Finding)
-> Parser (Maybe Text)
-> Parser
(Maybe FindingType
-> Maybe Bool -> Maybe Text -> Maybe Bool -> Finding)
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
"title")
Parser
(Maybe FindingType
-> Maybe Bool -> Maybe Text -> Maybe Bool -> Finding)
-> Parser (Maybe FindingType)
-> Parser (Maybe Bool -> Maybe Text -> Maybe Bool -> Finding)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe FindingType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"type")
Parser (Maybe Bool -> Maybe Text -> Maybe Bool -> Finding)
-> Parser (Maybe Bool)
-> Parser (Maybe Text -> Maybe Bool -> Finding)
forall (f :: * -> *) a b. Applicative f => 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
"archived")
Parser (Maybe Text -> Maybe Bool -> Finding)
-> Parser (Maybe Text) -> Parser (Maybe Bool -> Finding)
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
"description")
Parser (Maybe Bool -> Finding)
-> Parser (Maybe Bool) -> Parser Finding
forall (f :: * -> *) a b. Applicative f => 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
"sample")
)
instance Prelude.Hashable Finding
instance Prelude.NFData Finding