{-# 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.CognitoIdentityProvider.Types.DomainDescriptionType where
import Amazonka.CognitoIdentityProvider.Types.CustomDomainConfigType
import Amazonka.CognitoIdentityProvider.Types.DomainStatusType
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data DomainDescriptionType = DomainDescriptionType'
{
DomainDescriptionType -> Maybe DomainStatusType
status :: Prelude.Maybe DomainStatusType,
DomainDescriptionType -> Maybe Text
cloudFrontDistribution :: Prelude.Maybe Prelude.Text,
DomainDescriptionType -> Maybe Text
userPoolId :: Prelude.Maybe Prelude.Text,
DomainDescriptionType -> Maybe Text
domain :: Prelude.Maybe Prelude.Text,
DomainDescriptionType -> Maybe Text
aWSAccountId :: Prelude.Maybe Prelude.Text,
DomainDescriptionType -> Maybe CustomDomainConfigType
customDomainConfig :: Prelude.Maybe CustomDomainConfigType,
DomainDescriptionType -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
DomainDescriptionType -> Maybe Text
s3Bucket :: Prelude.Maybe Prelude.Text
}
deriving (DomainDescriptionType -> DomainDescriptionType -> Bool
(DomainDescriptionType -> DomainDescriptionType -> Bool)
-> (DomainDescriptionType -> DomainDescriptionType -> Bool)
-> Eq DomainDescriptionType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DomainDescriptionType -> DomainDescriptionType -> Bool
$c/= :: DomainDescriptionType -> DomainDescriptionType -> Bool
== :: DomainDescriptionType -> DomainDescriptionType -> Bool
$c== :: DomainDescriptionType -> DomainDescriptionType -> Bool
Prelude.Eq, ReadPrec [DomainDescriptionType]
ReadPrec DomainDescriptionType
Int -> ReadS DomainDescriptionType
ReadS [DomainDescriptionType]
(Int -> ReadS DomainDescriptionType)
-> ReadS [DomainDescriptionType]
-> ReadPrec DomainDescriptionType
-> ReadPrec [DomainDescriptionType]
-> Read DomainDescriptionType
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DomainDescriptionType]
$creadListPrec :: ReadPrec [DomainDescriptionType]
readPrec :: ReadPrec DomainDescriptionType
$creadPrec :: ReadPrec DomainDescriptionType
readList :: ReadS [DomainDescriptionType]
$creadList :: ReadS [DomainDescriptionType]
readsPrec :: Int -> ReadS DomainDescriptionType
$creadsPrec :: Int -> ReadS DomainDescriptionType
Prelude.Read, Int -> DomainDescriptionType -> ShowS
[DomainDescriptionType] -> ShowS
DomainDescriptionType -> String
(Int -> DomainDescriptionType -> ShowS)
-> (DomainDescriptionType -> String)
-> ([DomainDescriptionType] -> ShowS)
-> Show DomainDescriptionType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DomainDescriptionType] -> ShowS
$cshowList :: [DomainDescriptionType] -> ShowS
show :: DomainDescriptionType -> String
$cshow :: DomainDescriptionType -> String
showsPrec :: Int -> DomainDescriptionType -> ShowS
$cshowsPrec :: Int -> DomainDescriptionType -> ShowS
Prelude.Show, (forall x. DomainDescriptionType -> Rep DomainDescriptionType x)
-> (forall x. Rep DomainDescriptionType x -> DomainDescriptionType)
-> Generic DomainDescriptionType
forall x. Rep DomainDescriptionType x -> DomainDescriptionType
forall x. DomainDescriptionType -> Rep DomainDescriptionType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DomainDescriptionType x -> DomainDescriptionType
$cfrom :: forall x. DomainDescriptionType -> Rep DomainDescriptionType x
Prelude.Generic)
newDomainDescriptionType ::
DomainDescriptionType
newDomainDescriptionType :: DomainDescriptionType
newDomainDescriptionType =
DomainDescriptionType' :: Maybe DomainStatusType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType
DomainDescriptionType'
{ $sel:status:DomainDescriptionType' :: Maybe DomainStatusType
status = Maybe DomainStatusType
forall a. Maybe a
Prelude.Nothing,
$sel:cloudFrontDistribution:DomainDescriptionType' :: Maybe Text
cloudFrontDistribution = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:userPoolId:DomainDescriptionType' :: Maybe Text
userPoolId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:domain:DomainDescriptionType' :: Maybe Text
domain = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:aWSAccountId:DomainDescriptionType' :: Maybe Text
aWSAccountId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:customDomainConfig:DomainDescriptionType' :: Maybe CustomDomainConfigType
customDomainConfig = Maybe CustomDomainConfigType
forall a. Maybe a
Prelude.Nothing,
$sel:version:DomainDescriptionType' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:s3Bucket:DomainDescriptionType' :: Maybe Text
s3Bucket = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
domainDescriptionType_status :: Lens.Lens' DomainDescriptionType (Prelude.Maybe DomainStatusType)
domainDescriptionType_status :: (Maybe DomainStatusType -> f (Maybe DomainStatusType))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_status = (DomainDescriptionType -> Maybe DomainStatusType)
-> (DomainDescriptionType
-> Maybe DomainStatusType -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe DomainStatusType)
(Maybe DomainStatusType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe DomainStatusType
status :: Maybe DomainStatusType
$sel:status:DomainDescriptionType' :: DomainDescriptionType -> Maybe DomainStatusType
status} -> Maybe DomainStatusType
status) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe DomainStatusType
a -> DomainDescriptionType
s {$sel:status:DomainDescriptionType' :: Maybe DomainStatusType
status = Maybe DomainStatusType
a} :: DomainDescriptionType)
domainDescriptionType_cloudFrontDistribution :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_cloudFrontDistribution :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_cloudFrontDistribution = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
cloudFrontDistribution :: Maybe Text
$sel:cloudFrontDistribution:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
cloudFrontDistribution} -> Maybe Text
cloudFrontDistribution) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:cloudFrontDistribution:DomainDescriptionType' :: Maybe Text
cloudFrontDistribution = Maybe Text
a} :: DomainDescriptionType)
domainDescriptionType_userPoolId :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_userPoolId :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_userPoolId = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
userPoolId :: Maybe Text
$sel:userPoolId:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
userPoolId} -> Maybe Text
userPoolId) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:userPoolId:DomainDescriptionType' :: Maybe Text
userPoolId = Maybe Text
a} :: DomainDescriptionType)
domainDescriptionType_domain :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_domain :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_domain = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
domain :: Maybe Text
$sel:domain:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
domain} -> Maybe Text
domain) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:domain:DomainDescriptionType' :: Maybe Text
domain = Maybe Text
a} :: DomainDescriptionType)
domainDescriptionType_aWSAccountId :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_aWSAccountId :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_aWSAccountId = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
aWSAccountId :: Maybe Text
$sel:aWSAccountId:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
aWSAccountId} -> Maybe Text
aWSAccountId) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:aWSAccountId:DomainDescriptionType' :: Maybe Text
aWSAccountId = Maybe Text
a} :: DomainDescriptionType)
domainDescriptionType_customDomainConfig :: Lens.Lens' DomainDescriptionType (Prelude.Maybe CustomDomainConfigType)
domainDescriptionType_customDomainConfig :: (Maybe CustomDomainConfigType -> f (Maybe CustomDomainConfigType))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_customDomainConfig = (DomainDescriptionType -> Maybe CustomDomainConfigType)
-> (DomainDescriptionType
-> Maybe CustomDomainConfigType -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe CustomDomainConfigType)
(Maybe CustomDomainConfigType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe CustomDomainConfigType
customDomainConfig :: Maybe CustomDomainConfigType
$sel:customDomainConfig:DomainDescriptionType' :: DomainDescriptionType -> Maybe CustomDomainConfigType
customDomainConfig} -> Maybe CustomDomainConfigType
customDomainConfig) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe CustomDomainConfigType
a -> DomainDescriptionType
s {$sel:customDomainConfig:DomainDescriptionType' :: Maybe CustomDomainConfigType
customDomainConfig = Maybe CustomDomainConfigType
a} :: DomainDescriptionType)
domainDescriptionType_version :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_version :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_version = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
version :: Maybe Text
$sel:version:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
version} -> Maybe Text
version) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:version:DomainDescriptionType' :: Maybe Text
version = Maybe Text
a} :: DomainDescriptionType)
domainDescriptionType_s3Bucket :: Lens.Lens' DomainDescriptionType (Prelude.Maybe Prelude.Text)
domainDescriptionType_s3Bucket :: (Maybe Text -> f (Maybe Text))
-> DomainDescriptionType -> f DomainDescriptionType
domainDescriptionType_s3Bucket = (DomainDescriptionType -> Maybe Text)
-> (DomainDescriptionType -> Maybe Text -> DomainDescriptionType)
-> Lens
DomainDescriptionType
DomainDescriptionType
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DomainDescriptionType' {Maybe Text
s3Bucket :: Maybe Text
$sel:s3Bucket:DomainDescriptionType' :: DomainDescriptionType -> Maybe Text
s3Bucket} -> Maybe Text
s3Bucket) (\s :: DomainDescriptionType
s@DomainDescriptionType' {} Maybe Text
a -> DomainDescriptionType
s {$sel:s3Bucket:DomainDescriptionType' :: Maybe Text
s3Bucket = Maybe Text
a} :: DomainDescriptionType)
instance Core.FromJSON DomainDescriptionType where
parseJSON :: Value -> Parser DomainDescriptionType
parseJSON =
String
-> (Object -> Parser DomainDescriptionType)
-> Value
-> Parser DomainDescriptionType
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"DomainDescriptionType"
( \Object
x ->
Maybe DomainStatusType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType
DomainDescriptionType'
(Maybe DomainStatusType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
-> Parser (Maybe DomainStatusType)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe DomainStatusType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Status")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
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
"CloudFrontDistribution")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
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
"UserPoolId")
Parser
(Maybe Text
-> Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
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
"Domain")
Parser
(Maybe Text
-> Maybe CustomDomainConfigType
-> Maybe Text
-> Maybe Text
-> DomainDescriptionType)
-> Parser (Maybe Text)
-> Parser
(Maybe CustomDomainConfigType
-> Maybe Text -> Maybe Text -> DomainDescriptionType)
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
"AWSAccountId")
Parser
(Maybe CustomDomainConfigType
-> Maybe Text -> Maybe Text -> DomainDescriptionType)
-> Parser (Maybe CustomDomainConfigType)
-> Parser (Maybe Text -> Maybe Text -> DomainDescriptionType)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe CustomDomainConfigType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CustomDomainConfig")
Parser (Maybe Text -> Maybe Text -> DomainDescriptionType)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> DomainDescriptionType)
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
"Version")
Parser (Maybe Text -> DomainDescriptionType)
-> Parser (Maybe Text) -> Parser DomainDescriptionType
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
"S3Bucket")
)
instance Prelude.Hashable DomainDescriptionType
instance Prelude.NFData DomainDescriptionType