{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.DocumentDB.CreateGlobalCluster
(
CreateGlobalCluster (..),
newCreateGlobalCluster,
createGlobalCluster_engineVersion,
createGlobalCluster_deletionProtection,
createGlobalCluster_storageEncrypted,
createGlobalCluster_sourceDBClusterIdentifier,
createGlobalCluster_engine,
createGlobalCluster_databaseName,
createGlobalCluster_globalClusterIdentifier,
CreateGlobalClusterResponse (..),
newCreateGlobalClusterResponse,
createGlobalClusterResponse_globalCluster,
createGlobalClusterResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.DocumentDB.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateGlobalCluster = CreateGlobalCluster'
{
CreateGlobalCluster -> Maybe Text
engineVersion :: Prelude.Maybe Prelude.Text,
CreateGlobalCluster -> Maybe Bool
deletionProtection :: Prelude.Maybe Prelude.Bool,
CreateGlobalCluster -> Maybe Bool
storageEncrypted :: Prelude.Maybe Prelude.Bool,
CreateGlobalCluster -> Maybe Text
sourceDBClusterIdentifier :: Prelude.Maybe Prelude.Text,
CreateGlobalCluster -> Maybe Text
engine :: Prelude.Maybe Prelude.Text,
CreateGlobalCluster -> Maybe Text
databaseName :: Prelude.Maybe Prelude.Text,
CreateGlobalCluster -> Text
globalClusterIdentifier :: Prelude.Text
}
deriving (CreateGlobalCluster -> CreateGlobalCluster -> Bool
(CreateGlobalCluster -> CreateGlobalCluster -> Bool)
-> (CreateGlobalCluster -> CreateGlobalCluster -> Bool)
-> Eq CreateGlobalCluster
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateGlobalCluster -> CreateGlobalCluster -> Bool
$c/= :: CreateGlobalCluster -> CreateGlobalCluster -> Bool
== :: CreateGlobalCluster -> CreateGlobalCluster -> Bool
$c== :: CreateGlobalCluster -> CreateGlobalCluster -> Bool
Prelude.Eq, ReadPrec [CreateGlobalCluster]
ReadPrec CreateGlobalCluster
Int -> ReadS CreateGlobalCluster
ReadS [CreateGlobalCluster]
(Int -> ReadS CreateGlobalCluster)
-> ReadS [CreateGlobalCluster]
-> ReadPrec CreateGlobalCluster
-> ReadPrec [CreateGlobalCluster]
-> Read CreateGlobalCluster
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateGlobalCluster]
$creadListPrec :: ReadPrec [CreateGlobalCluster]
readPrec :: ReadPrec CreateGlobalCluster
$creadPrec :: ReadPrec CreateGlobalCluster
readList :: ReadS [CreateGlobalCluster]
$creadList :: ReadS [CreateGlobalCluster]
readsPrec :: Int -> ReadS CreateGlobalCluster
$creadsPrec :: Int -> ReadS CreateGlobalCluster
Prelude.Read, Int -> CreateGlobalCluster -> ShowS
[CreateGlobalCluster] -> ShowS
CreateGlobalCluster -> String
(Int -> CreateGlobalCluster -> ShowS)
-> (CreateGlobalCluster -> String)
-> ([CreateGlobalCluster] -> ShowS)
-> Show CreateGlobalCluster
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateGlobalCluster] -> ShowS
$cshowList :: [CreateGlobalCluster] -> ShowS
show :: CreateGlobalCluster -> String
$cshow :: CreateGlobalCluster -> String
showsPrec :: Int -> CreateGlobalCluster -> ShowS
$cshowsPrec :: Int -> CreateGlobalCluster -> ShowS
Prelude.Show, (forall x. CreateGlobalCluster -> Rep CreateGlobalCluster x)
-> (forall x. Rep CreateGlobalCluster x -> CreateGlobalCluster)
-> Generic CreateGlobalCluster
forall x. Rep CreateGlobalCluster x -> CreateGlobalCluster
forall x. CreateGlobalCluster -> Rep CreateGlobalCluster x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateGlobalCluster x -> CreateGlobalCluster
$cfrom :: forall x. CreateGlobalCluster -> Rep CreateGlobalCluster x
Prelude.Generic)
newCreateGlobalCluster ::
Prelude.Text ->
CreateGlobalCluster
newCreateGlobalCluster :: Text -> CreateGlobalCluster
newCreateGlobalCluster Text
pGlobalClusterIdentifier_ =
CreateGlobalCluster' :: Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> CreateGlobalCluster
CreateGlobalCluster'
{ $sel:engineVersion:CreateGlobalCluster' :: Maybe Text
engineVersion =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:deletionProtection:CreateGlobalCluster' :: Maybe Bool
deletionProtection = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:storageEncrypted:CreateGlobalCluster' :: Maybe Bool
storageEncrypted = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:sourceDBClusterIdentifier:CreateGlobalCluster' :: Maybe Text
sourceDBClusterIdentifier = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:engine:CreateGlobalCluster' :: Maybe Text
engine = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:databaseName:CreateGlobalCluster' :: Maybe Text
databaseName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:globalClusterIdentifier:CreateGlobalCluster' :: Text
globalClusterIdentifier = Text
pGlobalClusterIdentifier_
}
createGlobalCluster_engineVersion :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Text)
createGlobalCluster_engineVersion :: (Maybe Text -> f (Maybe Text))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_engineVersion = (CreateGlobalCluster -> Maybe Text)
-> (CreateGlobalCluster -> Maybe Text -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Text
engineVersion :: Maybe Text
$sel:engineVersion:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
engineVersion} -> Maybe Text
engineVersion) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Text
a -> CreateGlobalCluster
s {$sel:engineVersion:CreateGlobalCluster' :: Maybe Text
engineVersion = Maybe Text
a} :: CreateGlobalCluster)
createGlobalCluster_deletionProtection :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Bool)
createGlobalCluster_deletionProtection :: (Maybe Bool -> f (Maybe Bool))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_deletionProtection = (CreateGlobalCluster -> Maybe Bool)
-> (CreateGlobalCluster -> Maybe Bool -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Bool
deletionProtection :: Maybe Bool
$sel:deletionProtection:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Bool
deletionProtection} -> Maybe Bool
deletionProtection) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Bool
a -> CreateGlobalCluster
s {$sel:deletionProtection:CreateGlobalCluster' :: Maybe Bool
deletionProtection = Maybe Bool
a} :: CreateGlobalCluster)
createGlobalCluster_storageEncrypted :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Bool)
createGlobalCluster_storageEncrypted :: (Maybe Bool -> f (Maybe Bool))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_storageEncrypted = (CreateGlobalCluster -> Maybe Bool)
-> (CreateGlobalCluster -> Maybe Bool -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Bool
storageEncrypted :: Maybe Bool
$sel:storageEncrypted:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Bool
storageEncrypted} -> Maybe Bool
storageEncrypted) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Bool
a -> CreateGlobalCluster
s {$sel:storageEncrypted:CreateGlobalCluster' :: Maybe Bool
storageEncrypted = Maybe Bool
a} :: CreateGlobalCluster)
createGlobalCluster_sourceDBClusterIdentifier :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Text)
createGlobalCluster_sourceDBClusterIdentifier :: (Maybe Text -> f (Maybe Text))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_sourceDBClusterIdentifier = (CreateGlobalCluster -> Maybe Text)
-> (CreateGlobalCluster -> Maybe Text -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Text
sourceDBClusterIdentifier :: Maybe Text
$sel:sourceDBClusterIdentifier:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
sourceDBClusterIdentifier} -> Maybe Text
sourceDBClusterIdentifier) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Text
a -> CreateGlobalCluster
s {$sel:sourceDBClusterIdentifier:CreateGlobalCluster' :: Maybe Text
sourceDBClusterIdentifier = Maybe Text
a} :: CreateGlobalCluster)
createGlobalCluster_engine :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Text)
createGlobalCluster_engine :: (Maybe Text -> f (Maybe Text))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_engine = (CreateGlobalCluster -> Maybe Text)
-> (CreateGlobalCluster -> Maybe Text -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Text
engine :: Maybe Text
$sel:engine:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
engine} -> Maybe Text
engine) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Text
a -> CreateGlobalCluster
s {$sel:engine:CreateGlobalCluster' :: Maybe Text
engine = Maybe Text
a} :: CreateGlobalCluster)
createGlobalCluster_databaseName :: Lens.Lens' CreateGlobalCluster (Prelude.Maybe Prelude.Text)
createGlobalCluster_databaseName :: (Maybe Text -> f (Maybe Text))
-> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_databaseName = (CreateGlobalCluster -> Maybe Text)
-> (CreateGlobalCluster -> Maybe Text -> CreateGlobalCluster)
-> Lens
CreateGlobalCluster CreateGlobalCluster (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Maybe Text
databaseName :: Maybe Text
$sel:databaseName:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
databaseName} -> Maybe Text
databaseName) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Maybe Text
a -> CreateGlobalCluster
s {$sel:databaseName:CreateGlobalCluster' :: Maybe Text
databaseName = Maybe Text
a} :: CreateGlobalCluster)
createGlobalCluster_globalClusterIdentifier :: Lens.Lens' CreateGlobalCluster Prelude.Text
createGlobalCluster_globalClusterIdentifier :: (Text -> f Text) -> CreateGlobalCluster -> f CreateGlobalCluster
createGlobalCluster_globalClusterIdentifier = (CreateGlobalCluster -> Text)
-> (CreateGlobalCluster -> Text -> CreateGlobalCluster)
-> Lens CreateGlobalCluster CreateGlobalCluster Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalCluster' {Text
globalClusterIdentifier :: Text
$sel:globalClusterIdentifier:CreateGlobalCluster' :: CreateGlobalCluster -> Text
globalClusterIdentifier} -> Text
globalClusterIdentifier) (\s :: CreateGlobalCluster
s@CreateGlobalCluster' {} Text
a -> CreateGlobalCluster
s {$sel:globalClusterIdentifier:CreateGlobalCluster' :: Text
globalClusterIdentifier = Text
a} :: CreateGlobalCluster)
instance Core.AWSRequest CreateGlobalCluster where
type
AWSResponse CreateGlobalCluster =
CreateGlobalClusterResponse
request :: CreateGlobalCluster -> Request CreateGlobalCluster
request = Service -> CreateGlobalCluster -> Request CreateGlobalCluster
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy CreateGlobalCluster
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse CreateGlobalCluster)))
response =
Text
-> (Int
-> ResponseHeaders
-> [Node]
-> Either String (AWSResponse CreateGlobalCluster))
-> Logger
-> Service
-> Proxy CreateGlobalCluster
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse CreateGlobalCluster)))
forall (m :: * -> *) a.
MonadResource m =>
Text
-> (Int
-> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXMLWrapper
Text
"CreateGlobalClusterResult"
( \Int
s ResponseHeaders
h [Node]
x ->
Maybe GlobalCluster -> Int -> CreateGlobalClusterResponse
CreateGlobalClusterResponse'
(Maybe GlobalCluster -> Int -> CreateGlobalClusterResponse)
-> Either String (Maybe GlobalCluster)
-> Either String (Int -> CreateGlobalClusterResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe GlobalCluster)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"GlobalCluster")
Either String (Int -> CreateGlobalClusterResponse)
-> Either String Int -> Either String CreateGlobalClusterResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable CreateGlobalCluster
instance Prelude.NFData CreateGlobalCluster
instance Core.ToHeaders CreateGlobalCluster where
toHeaders :: CreateGlobalCluster -> ResponseHeaders
toHeaders = ResponseHeaders -> CreateGlobalCluster -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const ResponseHeaders
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath CreateGlobalCluster where
toPath :: CreateGlobalCluster -> ByteString
toPath = ByteString -> CreateGlobalCluster -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery CreateGlobalCluster where
toQuery :: CreateGlobalCluster -> QueryString
toQuery CreateGlobalCluster' {Maybe Bool
Maybe Text
Text
globalClusterIdentifier :: Text
databaseName :: Maybe Text
engine :: Maybe Text
sourceDBClusterIdentifier :: Maybe Text
storageEncrypted :: Maybe Bool
deletionProtection :: Maybe Bool
engineVersion :: Maybe Text
$sel:globalClusterIdentifier:CreateGlobalCluster' :: CreateGlobalCluster -> Text
$sel:databaseName:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
$sel:engine:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
$sel:sourceDBClusterIdentifier:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
$sel:storageEncrypted:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Bool
$sel:deletionProtection:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Bool
$sel:engineVersion:CreateGlobalCluster' :: CreateGlobalCluster -> Maybe Text
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"CreateGlobalCluster" :: Prelude.ByteString),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2014-10-31" :: Prelude.ByteString),
ByteString
"EngineVersion" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
engineVersion,
ByteString
"DeletionProtection" ByteString -> Maybe Bool -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Bool
deletionProtection,
ByteString
"StorageEncrypted" ByteString -> Maybe Bool -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Bool
storageEncrypted,
ByteString
"SourceDBClusterIdentifier"
ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
sourceDBClusterIdentifier,
ByteString
"Engine" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
engine,
ByteString
"DatabaseName" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
databaseName,
ByteString
"GlobalClusterIdentifier"
ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
globalClusterIdentifier
]
data CreateGlobalClusterResponse = CreateGlobalClusterResponse'
{ CreateGlobalClusterResponse -> Maybe GlobalCluster
globalCluster :: Prelude.Maybe GlobalCluster,
CreateGlobalClusterResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateGlobalClusterResponse -> CreateGlobalClusterResponse -> Bool
(CreateGlobalClusterResponse
-> CreateGlobalClusterResponse -> Bool)
-> (CreateGlobalClusterResponse
-> CreateGlobalClusterResponse -> Bool)
-> Eq CreateGlobalClusterResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateGlobalClusterResponse -> CreateGlobalClusterResponse -> Bool
$c/= :: CreateGlobalClusterResponse -> CreateGlobalClusterResponse -> Bool
== :: CreateGlobalClusterResponse -> CreateGlobalClusterResponse -> Bool
$c== :: CreateGlobalClusterResponse -> CreateGlobalClusterResponse -> Bool
Prelude.Eq, ReadPrec [CreateGlobalClusterResponse]
ReadPrec CreateGlobalClusterResponse
Int -> ReadS CreateGlobalClusterResponse
ReadS [CreateGlobalClusterResponse]
(Int -> ReadS CreateGlobalClusterResponse)
-> ReadS [CreateGlobalClusterResponse]
-> ReadPrec CreateGlobalClusterResponse
-> ReadPrec [CreateGlobalClusterResponse]
-> Read CreateGlobalClusterResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateGlobalClusterResponse]
$creadListPrec :: ReadPrec [CreateGlobalClusterResponse]
readPrec :: ReadPrec CreateGlobalClusterResponse
$creadPrec :: ReadPrec CreateGlobalClusterResponse
readList :: ReadS [CreateGlobalClusterResponse]
$creadList :: ReadS [CreateGlobalClusterResponse]
readsPrec :: Int -> ReadS CreateGlobalClusterResponse
$creadsPrec :: Int -> ReadS CreateGlobalClusterResponse
Prelude.Read, Int -> CreateGlobalClusterResponse -> ShowS
[CreateGlobalClusterResponse] -> ShowS
CreateGlobalClusterResponse -> String
(Int -> CreateGlobalClusterResponse -> ShowS)
-> (CreateGlobalClusterResponse -> String)
-> ([CreateGlobalClusterResponse] -> ShowS)
-> Show CreateGlobalClusterResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateGlobalClusterResponse] -> ShowS
$cshowList :: [CreateGlobalClusterResponse] -> ShowS
show :: CreateGlobalClusterResponse -> String
$cshow :: CreateGlobalClusterResponse -> String
showsPrec :: Int -> CreateGlobalClusterResponse -> ShowS
$cshowsPrec :: Int -> CreateGlobalClusterResponse -> ShowS
Prelude.Show, (forall x.
CreateGlobalClusterResponse -> Rep CreateGlobalClusterResponse x)
-> (forall x.
Rep CreateGlobalClusterResponse x -> CreateGlobalClusterResponse)
-> Generic CreateGlobalClusterResponse
forall x.
Rep CreateGlobalClusterResponse x -> CreateGlobalClusterResponse
forall x.
CreateGlobalClusterResponse -> Rep CreateGlobalClusterResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateGlobalClusterResponse x -> CreateGlobalClusterResponse
$cfrom :: forall x.
CreateGlobalClusterResponse -> Rep CreateGlobalClusterResponse x
Prelude.Generic)
newCreateGlobalClusterResponse ::
Prelude.Int ->
CreateGlobalClusterResponse
newCreateGlobalClusterResponse :: Int -> CreateGlobalClusterResponse
newCreateGlobalClusterResponse Int
pHttpStatus_ =
CreateGlobalClusterResponse' :: Maybe GlobalCluster -> Int -> CreateGlobalClusterResponse
CreateGlobalClusterResponse'
{ $sel:globalCluster:CreateGlobalClusterResponse' :: Maybe GlobalCluster
globalCluster =
Maybe GlobalCluster
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateGlobalClusterResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createGlobalClusterResponse_globalCluster :: Lens.Lens' CreateGlobalClusterResponse (Prelude.Maybe GlobalCluster)
createGlobalClusterResponse_globalCluster :: (Maybe GlobalCluster -> f (Maybe GlobalCluster))
-> CreateGlobalClusterResponse -> f CreateGlobalClusterResponse
createGlobalClusterResponse_globalCluster = (CreateGlobalClusterResponse -> Maybe GlobalCluster)
-> (CreateGlobalClusterResponse
-> Maybe GlobalCluster -> CreateGlobalClusterResponse)
-> Lens
CreateGlobalClusterResponse
CreateGlobalClusterResponse
(Maybe GlobalCluster)
(Maybe GlobalCluster)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalClusterResponse' {Maybe GlobalCluster
globalCluster :: Maybe GlobalCluster
$sel:globalCluster:CreateGlobalClusterResponse' :: CreateGlobalClusterResponse -> Maybe GlobalCluster
globalCluster} -> Maybe GlobalCluster
globalCluster) (\s :: CreateGlobalClusterResponse
s@CreateGlobalClusterResponse' {} Maybe GlobalCluster
a -> CreateGlobalClusterResponse
s {$sel:globalCluster:CreateGlobalClusterResponse' :: Maybe GlobalCluster
globalCluster = Maybe GlobalCluster
a} :: CreateGlobalClusterResponse)
createGlobalClusterResponse_httpStatus :: Lens.Lens' CreateGlobalClusterResponse Prelude.Int
createGlobalClusterResponse_httpStatus :: (Int -> f Int)
-> CreateGlobalClusterResponse -> f CreateGlobalClusterResponse
createGlobalClusterResponse_httpStatus = (CreateGlobalClusterResponse -> Int)
-> (CreateGlobalClusterResponse
-> Int -> CreateGlobalClusterResponse)
-> Lens
CreateGlobalClusterResponse CreateGlobalClusterResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateGlobalClusterResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateGlobalClusterResponse' :: CreateGlobalClusterResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateGlobalClusterResponse
s@CreateGlobalClusterResponse' {} Int
a -> CreateGlobalClusterResponse
s {$sel:httpStatus:CreateGlobalClusterResponse' :: Int
httpStatus = Int
a} :: CreateGlobalClusterResponse)
instance Prelude.NFData CreateGlobalClusterResponse