{-# 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.AuditManager.Types.AssessmentMetadataItem where
import Amazonka.AuditManager.Types.AssessmentStatus
import Amazonka.AuditManager.Types.Delegation
import Amazonka.AuditManager.Types.Role
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data AssessmentMetadataItem = AssessmentMetadataItem'
{
AssessmentMetadataItem -> Maybe POSIX
creationTime :: Prelude.Maybe Core.POSIX,
AssessmentMetadataItem -> Maybe AssessmentStatus
status :: Prelude.Maybe AssessmentStatus,
AssessmentMetadataItem -> Maybe POSIX
lastUpdated :: Prelude.Maybe Core.POSIX,
AssessmentMetadataItem -> Maybe [Role]
roles :: Prelude.Maybe [Role],
AssessmentMetadataItem -> Maybe [Delegation]
delegations :: Prelude.Maybe [Delegation],
AssessmentMetadataItem -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
AssessmentMetadataItem -> Maybe Text
complianceType :: Prelude.Maybe Prelude.Text,
AssessmentMetadataItem -> Maybe Text
id :: Prelude.Maybe Prelude.Text
}
deriving (AssessmentMetadataItem -> AssessmentMetadataItem -> Bool
(AssessmentMetadataItem -> AssessmentMetadataItem -> Bool)
-> (AssessmentMetadataItem -> AssessmentMetadataItem -> Bool)
-> Eq AssessmentMetadataItem
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AssessmentMetadataItem -> AssessmentMetadataItem -> Bool
$c/= :: AssessmentMetadataItem -> AssessmentMetadataItem -> Bool
== :: AssessmentMetadataItem -> AssessmentMetadataItem -> Bool
$c== :: AssessmentMetadataItem -> AssessmentMetadataItem -> Bool
Prelude.Eq, ReadPrec [AssessmentMetadataItem]
ReadPrec AssessmentMetadataItem
Int -> ReadS AssessmentMetadataItem
ReadS [AssessmentMetadataItem]
(Int -> ReadS AssessmentMetadataItem)
-> ReadS [AssessmentMetadataItem]
-> ReadPrec AssessmentMetadataItem
-> ReadPrec [AssessmentMetadataItem]
-> Read AssessmentMetadataItem
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AssessmentMetadataItem]
$creadListPrec :: ReadPrec [AssessmentMetadataItem]
readPrec :: ReadPrec AssessmentMetadataItem
$creadPrec :: ReadPrec AssessmentMetadataItem
readList :: ReadS [AssessmentMetadataItem]
$creadList :: ReadS [AssessmentMetadataItem]
readsPrec :: Int -> ReadS AssessmentMetadataItem
$creadsPrec :: Int -> ReadS AssessmentMetadataItem
Prelude.Read, Int -> AssessmentMetadataItem -> ShowS
[AssessmentMetadataItem] -> ShowS
AssessmentMetadataItem -> String
(Int -> AssessmentMetadataItem -> ShowS)
-> (AssessmentMetadataItem -> String)
-> ([AssessmentMetadataItem] -> ShowS)
-> Show AssessmentMetadataItem
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AssessmentMetadataItem] -> ShowS
$cshowList :: [AssessmentMetadataItem] -> ShowS
show :: AssessmentMetadataItem -> String
$cshow :: AssessmentMetadataItem -> String
showsPrec :: Int -> AssessmentMetadataItem -> ShowS
$cshowsPrec :: Int -> AssessmentMetadataItem -> ShowS
Prelude.Show, (forall x. AssessmentMetadataItem -> Rep AssessmentMetadataItem x)
-> (forall x.
Rep AssessmentMetadataItem x -> AssessmentMetadataItem)
-> Generic AssessmentMetadataItem
forall x. Rep AssessmentMetadataItem x -> AssessmentMetadataItem
forall x. AssessmentMetadataItem -> Rep AssessmentMetadataItem x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AssessmentMetadataItem x -> AssessmentMetadataItem
$cfrom :: forall x. AssessmentMetadataItem -> Rep AssessmentMetadataItem x
Prelude.Generic)
newAssessmentMetadataItem ::
AssessmentMetadataItem
newAssessmentMetadataItem :: AssessmentMetadataItem
newAssessmentMetadataItem =
AssessmentMetadataItem' :: Maybe POSIX
-> Maybe AssessmentStatus
-> Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem
AssessmentMetadataItem'
{ $sel:creationTime:AssessmentMetadataItem' :: Maybe POSIX
creationTime =
Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:status:AssessmentMetadataItem' :: Maybe AssessmentStatus
status = Maybe AssessmentStatus
forall a. Maybe a
Prelude.Nothing,
$sel:lastUpdated:AssessmentMetadataItem' :: Maybe POSIX
lastUpdated = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:roles:AssessmentMetadataItem' :: Maybe [Role]
roles = Maybe [Role]
forall a. Maybe a
Prelude.Nothing,
$sel:delegations:AssessmentMetadataItem' :: Maybe [Delegation]
delegations = Maybe [Delegation]
forall a. Maybe a
Prelude.Nothing,
$sel:name:AssessmentMetadataItem' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:complianceType:AssessmentMetadataItem' :: Maybe Text
complianceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:id:AssessmentMetadataItem' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
assessmentMetadataItem_creationTime :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe Prelude.UTCTime)
assessmentMetadataItem_creationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_creationTime = (AssessmentMetadataItem -> Maybe POSIX)
-> (AssessmentMetadataItem
-> Maybe POSIX -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe POSIX)
(Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe POSIX
creationTime :: Maybe POSIX
$sel:creationTime:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe POSIX
creationTime} -> Maybe POSIX
creationTime) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe POSIX
a -> AssessmentMetadataItem
s {$sel:creationTime:AssessmentMetadataItem' :: Maybe POSIX
creationTime = Maybe POSIX
a} :: AssessmentMetadataItem) ((Maybe POSIX -> f (Maybe POSIX))
-> AssessmentMetadataItem -> f AssessmentMetadataItem)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AssessmentMetadataItem
-> f AssessmentMetadataItem
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
assessmentMetadataItem_status :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe AssessmentStatus)
assessmentMetadataItem_status :: (Maybe AssessmentStatus -> f (Maybe AssessmentStatus))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_status = (AssessmentMetadataItem -> Maybe AssessmentStatus)
-> (AssessmentMetadataItem
-> Maybe AssessmentStatus -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe AssessmentStatus)
(Maybe AssessmentStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe AssessmentStatus
status :: Maybe AssessmentStatus
$sel:status:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe AssessmentStatus
status} -> Maybe AssessmentStatus
status) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe AssessmentStatus
a -> AssessmentMetadataItem
s {$sel:status:AssessmentMetadataItem' :: Maybe AssessmentStatus
status = Maybe AssessmentStatus
a} :: AssessmentMetadataItem)
assessmentMetadataItem_lastUpdated :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe Prelude.UTCTime)
assessmentMetadataItem_lastUpdated :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_lastUpdated = (AssessmentMetadataItem -> Maybe POSIX)
-> (AssessmentMetadataItem
-> Maybe POSIX -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe POSIX)
(Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe POSIX
lastUpdated :: Maybe POSIX
$sel:lastUpdated:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe POSIX
lastUpdated} -> Maybe POSIX
lastUpdated) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe POSIX
a -> AssessmentMetadataItem
s {$sel:lastUpdated:AssessmentMetadataItem' :: Maybe POSIX
lastUpdated = Maybe POSIX
a} :: AssessmentMetadataItem) ((Maybe POSIX -> f (Maybe POSIX))
-> AssessmentMetadataItem -> f AssessmentMetadataItem)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AssessmentMetadataItem
-> f AssessmentMetadataItem
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
assessmentMetadataItem_roles :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe [Role])
assessmentMetadataItem_roles :: (Maybe [Role] -> f (Maybe [Role]))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_roles = (AssessmentMetadataItem -> Maybe [Role])
-> (AssessmentMetadataItem
-> Maybe [Role] -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe [Role])
(Maybe [Role])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe [Role]
roles :: Maybe [Role]
$sel:roles:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe [Role]
roles} -> Maybe [Role]
roles) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe [Role]
a -> AssessmentMetadataItem
s {$sel:roles:AssessmentMetadataItem' :: Maybe [Role]
roles = Maybe [Role]
a} :: AssessmentMetadataItem) ((Maybe [Role] -> f (Maybe [Role]))
-> AssessmentMetadataItem -> f AssessmentMetadataItem)
-> ((Maybe [Role] -> f (Maybe [Role]))
-> Maybe [Role] -> f (Maybe [Role]))
-> (Maybe [Role] -> f (Maybe [Role]))
-> AssessmentMetadataItem
-> f AssessmentMetadataItem
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Role] [Role] [Role] [Role]
-> Iso (Maybe [Role]) (Maybe [Role]) (Maybe [Role]) (Maybe [Role])
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 [Role] [Role] [Role] [Role]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
assessmentMetadataItem_delegations :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe [Delegation])
assessmentMetadataItem_delegations :: (Maybe [Delegation] -> f (Maybe [Delegation]))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_delegations = (AssessmentMetadataItem -> Maybe [Delegation])
-> (AssessmentMetadataItem
-> Maybe [Delegation] -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe [Delegation])
(Maybe [Delegation])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe [Delegation]
delegations :: Maybe [Delegation]
$sel:delegations:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe [Delegation]
delegations} -> Maybe [Delegation]
delegations) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe [Delegation]
a -> AssessmentMetadataItem
s {$sel:delegations:AssessmentMetadataItem' :: Maybe [Delegation]
delegations = Maybe [Delegation]
a} :: AssessmentMetadataItem) ((Maybe [Delegation] -> f (Maybe [Delegation]))
-> AssessmentMetadataItem -> f AssessmentMetadataItem)
-> ((Maybe [Delegation] -> f (Maybe [Delegation]))
-> Maybe [Delegation] -> f (Maybe [Delegation]))
-> (Maybe [Delegation] -> f (Maybe [Delegation]))
-> AssessmentMetadataItem
-> f AssessmentMetadataItem
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Delegation] [Delegation] [Delegation] [Delegation]
-> Iso
(Maybe [Delegation])
(Maybe [Delegation])
(Maybe [Delegation])
(Maybe [Delegation])
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 [Delegation] [Delegation] [Delegation] [Delegation]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
assessmentMetadataItem_name :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe Prelude.Text)
assessmentMetadataItem_name :: (Maybe Text -> f (Maybe Text))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_name = (AssessmentMetadataItem -> Maybe Text)
-> (AssessmentMetadataItem -> Maybe Text -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe Text
name :: Maybe Text
$sel:name:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe Text
name} -> Maybe Text
name) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe Text
a -> AssessmentMetadataItem
s {$sel:name:AssessmentMetadataItem' :: Maybe Text
name = Maybe Text
a} :: AssessmentMetadataItem)
assessmentMetadataItem_complianceType :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe Prelude.Text)
assessmentMetadataItem_complianceType :: (Maybe Text -> f (Maybe Text))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_complianceType = (AssessmentMetadataItem -> Maybe Text)
-> (AssessmentMetadataItem -> Maybe Text -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe Text
complianceType :: Maybe Text
$sel:complianceType:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe Text
complianceType} -> Maybe Text
complianceType) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe Text
a -> AssessmentMetadataItem
s {$sel:complianceType:AssessmentMetadataItem' :: Maybe Text
complianceType = Maybe Text
a} :: AssessmentMetadataItem)
assessmentMetadataItem_id :: Lens.Lens' AssessmentMetadataItem (Prelude.Maybe Prelude.Text)
assessmentMetadataItem_id :: (Maybe Text -> f (Maybe Text))
-> AssessmentMetadataItem -> f AssessmentMetadataItem
assessmentMetadataItem_id = (AssessmentMetadataItem -> Maybe Text)
-> (AssessmentMetadataItem -> Maybe Text -> AssessmentMetadataItem)
-> Lens
AssessmentMetadataItem
AssessmentMetadataItem
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssessmentMetadataItem' {Maybe Text
id :: Maybe Text
$sel:id:AssessmentMetadataItem' :: AssessmentMetadataItem -> Maybe Text
id} -> Maybe Text
id) (\s :: AssessmentMetadataItem
s@AssessmentMetadataItem' {} Maybe Text
a -> AssessmentMetadataItem
s {$sel:id:AssessmentMetadataItem' :: Maybe Text
id = Maybe Text
a} :: AssessmentMetadataItem)
instance Core.FromJSON AssessmentMetadataItem where
parseJSON :: Value -> Parser AssessmentMetadataItem
parseJSON =
String
-> (Object -> Parser AssessmentMetadataItem)
-> Value
-> Parser AssessmentMetadataItem
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AssessmentMetadataItem"
( \Object
x ->
Maybe POSIX
-> Maybe AssessmentStatus
-> Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem
AssessmentMetadataItem'
(Maybe POSIX
-> Maybe AssessmentStatus
-> Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
-> Parser (Maybe POSIX)
-> Parser
(Maybe AssessmentStatus
-> Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
forall (f :: * -> *) a b. Functor 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
"creationTime")
Parser
(Maybe AssessmentStatus
-> Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
-> Parser (Maybe AssessmentStatus)
-> Parser
(Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AssessmentStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"status")
Parser
(Maybe POSIX
-> Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
-> Parser (Maybe POSIX)
-> Parser
(Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
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
"lastUpdated")
Parser
(Maybe [Role]
-> Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
-> Parser (Maybe [Role])
-> Parser
(Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Role]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"roles" Parser (Maybe (Maybe [Role]))
-> Maybe [Role] -> Parser (Maybe [Role])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Role]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe [Delegation]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssessmentMetadataItem)
-> Parser (Maybe [Delegation])
-> Parser
(Maybe Text -> Maybe Text -> Maybe Text -> AssessmentMetadataItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [Delegation]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"delegations" Parser (Maybe (Maybe [Delegation]))
-> Maybe [Delegation] -> Parser (Maybe [Delegation])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [Delegation]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe Text -> Maybe Text -> Maybe Text -> AssessmentMetadataItem)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> AssessmentMetadataItem)
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
"name")
Parser (Maybe Text -> Maybe Text -> AssessmentMetadataItem)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> AssessmentMetadataItem)
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
"complianceType")
Parser (Maybe Text -> AssessmentMetadataItem)
-> Parser (Maybe Text) -> Parser AssessmentMetadataItem
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")
)
instance Prelude.Hashable AssessmentMetadataItem
instance Prelude.NFData AssessmentMetadataItem