{-# 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.AmplifyUiBuilder.Types.ThemeSummary where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data ThemeSummary = ThemeSummary'
{
ThemeSummary -> Text
appId :: Prelude.Text,
ThemeSummary -> Text
environmentName :: Prelude.Text,
ThemeSummary -> Text
id :: Prelude.Text,
ThemeSummary -> Text
name :: Prelude.Text
}
deriving (ThemeSummary -> ThemeSummary -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ThemeSummary -> ThemeSummary -> Bool
$c/= :: ThemeSummary -> ThemeSummary -> Bool
== :: ThemeSummary -> ThemeSummary -> Bool
$c== :: ThemeSummary -> ThemeSummary -> Bool
Prelude.Eq, ReadPrec [ThemeSummary]
ReadPrec ThemeSummary
Int -> ReadS ThemeSummary
ReadS [ThemeSummary]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ThemeSummary]
$creadListPrec :: ReadPrec [ThemeSummary]
readPrec :: ReadPrec ThemeSummary
$creadPrec :: ReadPrec ThemeSummary
readList :: ReadS [ThemeSummary]
$creadList :: ReadS [ThemeSummary]
readsPrec :: Int -> ReadS ThemeSummary
$creadsPrec :: Int -> ReadS ThemeSummary
Prelude.Read, Int -> ThemeSummary -> ShowS
[ThemeSummary] -> ShowS
ThemeSummary -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ThemeSummary] -> ShowS
$cshowList :: [ThemeSummary] -> ShowS
show :: ThemeSummary -> String
$cshow :: ThemeSummary -> String
showsPrec :: Int -> ThemeSummary -> ShowS
$cshowsPrec :: Int -> ThemeSummary -> ShowS
Prelude.Show, forall x. Rep ThemeSummary x -> ThemeSummary
forall x. ThemeSummary -> Rep ThemeSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ThemeSummary x -> ThemeSummary
$cfrom :: forall x. ThemeSummary -> Rep ThemeSummary x
Prelude.Generic)
newThemeSummary ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
ThemeSummary
newThemeSummary :: Text -> Text -> Text -> Text -> ThemeSummary
newThemeSummary Text
pAppId_ Text
pEnvironmentName_ Text
pId_ Text
pName_ =
ThemeSummary'
{ $sel:appId:ThemeSummary' :: Text
appId = Text
pAppId_,
$sel:environmentName:ThemeSummary' :: Text
environmentName = Text
pEnvironmentName_,
$sel:id:ThemeSummary' :: Text
id = Text
pId_,
$sel:name:ThemeSummary' :: Text
name = Text
pName_
}
themeSummary_appId :: Lens.Lens' ThemeSummary Prelude.Text
themeSummary_appId :: Lens' ThemeSummary Text
themeSummary_appId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeSummary' {Text
appId :: Text
$sel:appId:ThemeSummary' :: ThemeSummary -> Text
appId} -> Text
appId) (\s :: ThemeSummary
s@ThemeSummary' {} Text
a -> ThemeSummary
s {$sel:appId:ThemeSummary' :: Text
appId = Text
a} :: ThemeSummary)
themeSummary_environmentName :: Lens.Lens' ThemeSummary Prelude.Text
themeSummary_environmentName :: Lens' ThemeSummary Text
themeSummary_environmentName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeSummary' {Text
environmentName :: Text
$sel:environmentName:ThemeSummary' :: ThemeSummary -> Text
environmentName} -> Text
environmentName) (\s :: ThemeSummary
s@ThemeSummary' {} Text
a -> ThemeSummary
s {$sel:environmentName:ThemeSummary' :: Text
environmentName = Text
a} :: ThemeSummary)
themeSummary_id :: Lens.Lens' ThemeSummary Prelude.Text
themeSummary_id :: Lens' ThemeSummary Text
themeSummary_id = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeSummary' {Text
id :: Text
$sel:id:ThemeSummary' :: ThemeSummary -> Text
id} -> Text
id) (\s :: ThemeSummary
s@ThemeSummary' {} Text
a -> ThemeSummary
s {$sel:id:ThemeSummary' :: Text
id = Text
a} :: ThemeSummary)
themeSummary_name :: Lens.Lens' ThemeSummary Prelude.Text
themeSummary_name :: Lens' ThemeSummary Text
themeSummary_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeSummary' {Text
name :: Text
$sel:name:ThemeSummary' :: ThemeSummary -> Text
name} -> Text
name) (\s :: ThemeSummary
s@ThemeSummary' {} Text
a -> ThemeSummary
s {$sel:name:ThemeSummary' :: Text
name = Text
a} :: ThemeSummary)
instance Data.FromJSON ThemeSummary where
parseJSON :: Value -> Parser ThemeSummary
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ThemeSummary"
( \Object
x ->
Text -> Text -> Text -> Text -> ThemeSummary
ThemeSummary'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"appId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"environmentName")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"id")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"name")
)
instance Prelude.Hashable ThemeSummary where
hashWithSalt :: Int -> ThemeSummary -> Int
hashWithSalt Int
_salt ThemeSummary' {Text
name :: Text
id :: Text
environmentName :: Text
appId :: Text
$sel:name:ThemeSummary' :: ThemeSummary -> Text
$sel:id:ThemeSummary' :: ThemeSummary -> Text
$sel:environmentName:ThemeSummary' :: ThemeSummary -> Text
$sel:appId:ThemeSummary' :: ThemeSummary -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
appId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
environmentName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
id
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
instance Prelude.NFData ThemeSummary where
rnf :: ThemeSummary -> ()
rnf ThemeSummary' {Text
name :: Text
id :: Text
environmentName :: Text
appId :: Text
$sel:name:ThemeSummary' :: ThemeSummary -> Text
$sel:id:ThemeSummary' :: ThemeSummary -> Text
$sel:environmentName:ThemeSummary' :: ThemeSummary -> Text
$sel:appId:ThemeSummary' :: ThemeSummary -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
appId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
environmentName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
id
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name