{-# 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.QuickSight.Types.ThemeAlias where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data ThemeAlias = ThemeAlias'
{
ThemeAlias -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
ThemeAlias -> Maybe Natural
themeVersionNumber :: Prelude.Maybe Prelude.Natural,
ThemeAlias -> Maybe Text
aliasName :: Prelude.Maybe Prelude.Text
}
deriving (ThemeAlias -> ThemeAlias -> Bool
(ThemeAlias -> ThemeAlias -> Bool)
-> (ThemeAlias -> ThemeAlias -> Bool) -> Eq ThemeAlias
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ThemeAlias -> ThemeAlias -> Bool
$c/= :: ThemeAlias -> ThemeAlias -> Bool
== :: ThemeAlias -> ThemeAlias -> Bool
$c== :: ThemeAlias -> ThemeAlias -> Bool
Prelude.Eq, ReadPrec [ThemeAlias]
ReadPrec ThemeAlias
Int -> ReadS ThemeAlias
ReadS [ThemeAlias]
(Int -> ReadS ThemeAlias)
-> ReadS [ThemeAlias]
-> ReadPrec ThemeAlias
-> ReadPrec [ThemeAlias]
-> Read ThemeAlias
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ThemeAlias]
$creadListPrec :: ReadPrec [ThemeAlias]
readPrec :: ReadPrec ThemeAlias
$creadPrec :: ReadPrec ThemeAlias
readList :: ReadS [ThemeAlias]
$creadList :: ReadS [ThemeAlias]
readsPrec :: Int -> ReadS ThemeAlias
$creadsPrec :: Int -> ReadS ThemeAlias
Prelude.Read, Int -> ThemeAlias -> ShowS
[ThemeAlias] -> ShowS
ThemeAlias -> String
(Int -> ThemeAlias -> ShowS)
-> (ThemeAlias -> String)
-> ([ThemeAlias] -> ShowS)
-> Show ThemeAlias
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ThemeAlias] -> ShowS
$cshowList :: [ThemeAlias] -> ShowS
show :: ThemeAlias -> String
$cshow :: ThemeAlias -> String
showsPrec :: Int -> ThemeAlias -> ShowS
$cshowsPrec :: Int -> ThemeAlias -> ShowS
Prelude.Show, (forall x. ThemeAlias -> Rep ThemeAlias x)
-> (forall x. Rep ThemeAlias x -> ThemeAlias) -> Generic ThemeAlias
forall x. Rep ThemeAlias x -> ThemeAlias
forall x. ThemeAlias -> Rep ThemeAlias x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ThemeAlias x -> ThemeAlias
$cfrom :: forall x. ThemeAlias -> Rep ThemeAlias x
Prelude.Generic)
newThemeAlias ::
ThemeAlias
newThemeAlias :: ThemeAlias
newThemeAlias =
ThemeAlias' :: Maybe Text -> Maybe Natural -> Maybe Text -> ThemeAlias
ThemeAlias'
{ $sel:arn:ThemeAlias' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:themeVersionNumber:ThemeAlias' :: Maybe Natural
themeVersionNumber = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
$sel:aliasName:ThemeAlias' :: Maybe Text
aliasName = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
themeAlias_arn :: Lens.Lens' ThemeAlias (Prelude.Maybe Prelude.Text)
themeAlias_arn :: (Maybe Text -> f (Maybe Text)) -> ThemeAlias -> f ThemeAlias
themeAlias_arn = (ThemeAlias -> Maybe Text)
-> (ThemeAlias -> Maybe Text -> ThemeAlias)
-> Lens ThemeAlias ThemeAlias (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeAlias' {Maybe Text
arn :: Maybe Text
$sel:arn:ThemeAlias' :: ThemeAlias -> Maybe Text
arn} -> Maybe Text
arn) (\s :: ThemeAlias
s@ThemeAlias' {} Maybe Text
a -> ThemeAlias
s {$sel:arn:ThemeAlias' :: Maybe Text
arn = Maybe Text
a} :: ThemeAlias)
themeAlias_themeVersionNumber :: Lens.Lens' ThemeAlias (Prelude.Maybe Prelude.Natural)
themeAlias_themeVersionNumber :: (Maybe Natural -> f (Maybe Natural)) -> ThemeAlias -> f ThemeAlias
themeAlias_themeVersionNumber = (ThemeAlias -> Maybe Natural)
-> (ThemeAlias -> Maybe Natural -> ThemeAlias)
-> Lens ThemeAlias ThemeAlias (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeAlias' {Maybe Natural
themeVersionNumber :: Maybe Natural
$sel:themeVersionNumber:ThemeAlias' :: ThemeAlias -> Maybe Natural
themeVersionNumber} -> Maybe Natural
themeVersionNumber) (\s :: ThemeAlias
s@ThemeAlias' {} Maybe Natural
a -> ThemeAlias
s {$sel:themeVersionNumber:ThemeAlias' :: Maybe Natural
themeVersionNumber = Maybe Natural
a} :: ThemeAlias)
themeAlias_aliasName :: Lens.Lens' ThemeAlias (Prelude.Maybe Prelude.Text)
themeAlias_aliasName :: (Maybe Text -> f (Maybe Text)) -> ThemeAlias -> f ThemeAlias
themeAlias_aliasName = (ThemeAlias -> Maybe Text)
-> (ThemeAlias -> Maybe Text -> ThemeAlias)
-> Lens ThemeAlias ThemeAlias (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ThemeAlias' {Maybe Text
aliasName :: Maybe Text
$sel:aliasName:ThemeAlias' :: ThemeAlias -> Maybe Text
aliasName} -> Maybe Text
aliasName) (\s :: ThemeAlias
s@ThemeAlias' {} Maybe Text
a -> ThemeAlias
s {$sel:aliasName:ThemeAlias' :: Maybe Text
aliasName = Maybe Text
a} :: ThemeAlias)
instance Core.FromJSON ThemeAlias where
parseJSON :: Value -> Parser ThemeAlias
parseJSON =
String
-> (Object -> Parser ThemeAlias) -> Value -> Parser ThemeAlias
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"ThemeAlias"
( \Object
x ->
Maybe Text -> Maybe Natural -> Maybe Text -> ThemeAlias
ThemeAlias'
(Maybe Text -> Maybe Natural -> Maybe Text -> ThemeAlias)
-> Parser (Maybe Text)
-> Parser (Maybe Natural -> Maybe Text -> ThemeAlias)
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
"Arn")
Parser (Maybe Natural -> Maybe Text -> ThemeAlias)
-> Parser (Maybe Natural) -> Parser (Maybe Text -> ThemeAlias)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Natural)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ThemeVersionNumber")
Parser (Maybe Text -> ThemeAlias)
-> Parser (Maybe Text) -> Parser ThemeAlias
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
"AliasName")
)
instance Prelude.Hashable ThemeAlias
instance Prelude.NFData ThemeAlias