{-# 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.FrameworkMetadata where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data FrameworkMetadata = FrameworkMetadata'
{
FrameworkMetadata -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
FrameworkMetadata -> Maybe Text
complianceType :: Prelude.Maybe Prelude.Text,
FrameworkMetadata -> Maybe Text
logo :: Prelude.Maybe Prelude.Text,
FrameworkMetadata -> Maybe Text
description :: Prelude.Maybe Prelude.Text
}
deriving (FrameworkMetadata -> FrameworkMetadata -> Bool
(FrameworkMetadata -> FrameworkMetadata -> Bool)
-> (FrameworkMetadata -> FrameworkMetadata -> Bool)
-> Eq FrameworkMetadata
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: FrameworkMetadata -> FrameworkMetadata -> Bool
$c/= :: FrameworkMetadata -> FrameworkMetadata -> Bool
== :: FrameworkMetadata -> FrameworkMetadata -> Bool
$c== :: FrameworkMetadata -> FrameworkMetadata -> Bool
Prelude.Eq, ReadPrec [FrameworkMetadata]
ReadPrec FrameworkMetadata
Int -> ReadS FrameworkMetadata
ReadS [FrameworkMetadata]
(Int -> ReadS FrameworkMetadata)
-> ReadS [FrameworkMetadata]
-> ReadPrec FrameworkMetadata
-> ReadPrec [FrameworkMetadata]
-> Read FrameworkMetadata
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [FrameworkMetadata]
$creadListPrec :: ReadPrec [FrameworkMetadata]
readPrec :: ReadPrec FrameworkMetadata
$creadPrec :: ReadPrec FrameworkMetadata
readList :: ReadS [FrameworkMetadata]
$creadList :: ReadS [FrameworkMetadata]
readsPrec :: Int -> ReadS FrameworkMetadata
$creadsPrec :: Int -> ReadS FrameworkMetadata
Prelude.Read, Int -> FrameworkMetadata -> ShowS
[FrameworkMetadata] -> ShowS
FrameworkMetadata -> String
(Int -> FrameworkMetadata -> ShowS)
-> (FrameworkMetadata -> String)
-> ([FrameworkMetadata] -> ShowS)
-> Show FrameworkMetadata
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [FrameworkMetadata] -> ShowS
$cshowList :: [FrameworkMetadata] -> ShowS
show :: FrameworkMetadata -> String
$cshow :: FrameworkMetadata -> String
showsPrec :: Int -> FrameworkMetadata -> ShowS
$cshowsPrec :: Int -> FrameworkMetadata -> ShowS
Prelude.Show, (forall x. FrameworkMetadata -> Rep FrameworkMetadata x)
-> (forall x. Rep FrameworkMetadata x -> FrameworkMetadata)
-> Generic FrameworkMetadata
forall x. Rep FrameworkMetadata x -> FrameworkMetadata
forall x. FrameworkMetadata -> Rep FrameworkMetadata x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep FrameworkMetadata x -> FrameworkMetadata
$cfrom :: forall x. FrameworkMetadata -> Rep FrameworkMetadata x
Prelude.Generic)
newFrameworkMetadata ::
FrameworkMetadata
newFrameworkMetadata :: FrameworkMetadata
newFrameworkMetadata =
FrameworkMetadata' :: Maybe Text
-> Maybe Text -> Maybe Text -> Maybe Text -> FrameworkMetadata
FrameworkMetadata'
{ $sel:name:FrameworkMetadata' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:complianceType:FrameworkMetadata' :: Maybe Text
complianceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:logo:FrameworkMetadata' :: Maybe Text
logo = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:description:FrameworkMetadata' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
frameworkMetadata_name :: Lens.Lens' FrameworkMetadata (Prelude.Maybe Prelude.Text)
frameworkMetadata_name :: (Maybe Text -> f (Maybe Text))
-> FrameworkMetadata -> f FrameworkMetadata
frameworkMetadata_name = (FrameworkMetadata -> Maybe Text)
-> (FrameworkMetadata -> Maybe Text -> FrameworkMetadata)
-> Lens
FrameworkMetadata FrameworkMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\FrameworkMetadata' {Maybe Text
name :: Maybe Text
$sel:name:FrameworkMetadata' :: FrameworkMetadata -> Maybe Text
name} -> Maybe Text
name) (\s :: FrameworkMetadata
s@FrameworkMetadata' {} Maybe Text
a -> FrameworkMetadata
s {$sel:name:FrameworkMetadata' :: Maybe Text
name = Maybe Text
a} :: FrameworkMetadata)
frameworkMetadata_complianceType :: Lens.Lens' FrameworkMetadata (Prelude.Maybe Prelude.Text)
frameworkMetadata_complianceType :: (Maybe Text -> f (Maybe Text))
-> FrameworkMetadata -> f FrameworkMetadata
frameworkMetadata_complianceType = (FrameworkMetadata -> Maybe Text)
-> (FrameworkMetadata -> Maybe Text -> FrameworkMetadata)
-> Lens
FrameworkMetadata FrameworkMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\FrameworkMetadata' {Maybe Text
complianceType :: Maybe Text
$sel:complianceType:FrameworkMetadata' :: FrameworkMetadata -> Maybe Text
complianceType} -> Maybe Text
complianceType) (\s :: FrameworkMetadata
s@FrameworkMetadata' {} Maybe Text
a -> FrameworkMetadata
s {$sel:complianceType:FrameworkMetadata' :: Maybe Text
complianceType = Maybe Text
a} :: FrameworkMetadata)
frameworkMetadata_logo :: Lens.Lens' FrameworkMetadata (Prelude.Maybe Prelude.Text)
frameworkMetadata_logo :: (Maybe Text -> f (Maybe Text))
-> FrameworkMetadata -> f FrameworkMetadata
frameworkMetadata_logo = (FrameworkMetadata -> Maybe Text)
-> (FrameworkMetadata -> Maybe Text -> FrameworkMetadata)
-> Lens
FrameworkMetadata FrameworkMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\FrameworkMetadata' {Maybe Text
logo :: Maybe Text
$sel:logo:FrameworkMetadata' :: FrameworkMetadata -> Maybe Text
logo} -> Maybe Text
logo) (\s :: FrameworkMetadata
s@FrameworkMetadata' {} Maybe Text
a -> FrameworkMetadata
s {$sel:logo:FrameworkMetadata' :: Maybe Text
logo = Maybe Text
a} :: FrameworkMetadata)
frameworkMetadata_description :: Lens.Lens' FrameworkMetadata (Prelude.Maybe Prelude.Text)
frameworkMetadata_description :: (Maybe Text -> f (Maybe Text))
-> FrameworkMetadata -> f FrameworkMetadata
frameworkMetadata_description = (FrameworkMetadata -> Maybe Text)
-> (FrameworkMetadata -> Maybe Text -> FrameworkMetadata)
-> Lens
FrameworkMetadata FrameworkMetadata (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\FrameworkMetadata' {Maybe Text
description :: Maybe Text
$sel:description:FrameworkMetadata' :: FrameworkMetadata -> Maybe Text
description} -> Maybe Text
description) (\s :: FrameworkMetadata
s@FrameworkMetadata' {} Maybe Text
a -> FrameworkMetadata
s {$sel:description:FrameworkMetadata' :: Maybe Text
description = Maybe Text
a} :: FrameworkMetadata)
instance Core.FromJSON FrameworkMetadata where
parseJSON :: Value -> Parser FrameworkMetadata
parseJSON =
String
-> (Object -> Parser FrameworkMetadata)
-> Value
-> Parser FrameworkMetadata
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"FrameworkMetadata"
( \Object
x ->
Maybe Text
-> Maybe Text -> Maybe Text -> Maybe Text -> FrameworkMetadata
FrameworkMetadata'
(Maybe Text
-> Maybe Text -> Maybe Text -> Maybe Text -> FrameworkMetadata)
-> Parser (Maybe Text)
-> Parser
(Maybe Text -> Maybe Text -> Maybe Text -> FrameworkMetadata)
forall (f :: * -> *) a b. Functor 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 -> Maybe Text -> FrameworkMetadata)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> FrameworkMetadata)
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 -> Maybe Text -> FrameworkMetadata)
-> Parser (Maybe Text) -> Parser (Maybe Text -> FrameworkMetadata)
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
"logo")
Parser (Maybe Text -> FrameworkMetadata)
-> Parser (Maybe Text) -> Parser FrameworkMetadata
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")
)
instance Prelude.Hashable FrameworkMetadata
instance Prelude.NFData FrameworkMetadata