{-# 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.Nimble.CreateStudio
(
CreateStudio (..),
newCreateStudio,
createStudio_studioEncryptionConfiguration,
createStudio_clientToken,
createStudio_tags,
createStudio_displayName,
createStudio_studioName,
createStudio_userRoleArn,
createStudio_adminRoleArn,
CreateStudioResponse (..),
newCreateStudioResponse,
createStudioResponse_studio,
createStudioResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Nimble.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateStudio = CreateStudio'
{
CreateStudio -> Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration :: Prelude.Maybe StudioEncryptionConfiguration,
CreateStudio -> Maybe Text
clientToken :: Prelude.Maybe Prelude.Text,
CreateStudio -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
CreateStudio -> Text
displayName :: Prelude.Text,
CreateStudio -> Text
studioName :: Prelude.Text,
CreateStudio -> Text
userRoleArn :: Prelude.Text,
CreateStudio -> Text
adminRoleArn :: Prelude.Text
}
deriving (CreateStudio -> CreateStudio -> Bool
(CreateStudio -> CreateStudio -> Bool)
-> (CreateStudio -> CreateStudio -> Bool) -> Eq CreateStudio
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateStudio -> CreateStudio -> Bool
$c/= :: CreateStudio -> CreateStudio -> Bool
== :: CreateStudio -> CreateStudio -> Bool
$c== :: CreateStudio -> CreateStudio -> Bool
Prelude.Eq, ReadPrec [CreateStudio]
ReadPrec CreateStudio
Int -> ReadS CreateStudio
ReadS [CreateStudio]
(Int -> ReadS CreateStudio)
-> ReadS [CreateStudio]
-> ReadPrec CreateStudio
-> ReadPrec [CreateStudio]
-> Read CreateStudio
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateStudio]
$creadListPrec :: ReadPrec [CreateStudio]
readPrec :: ReadPrec CreateStudio
$creadPrec :: ReadPrec CreateStudio
readList :: ReadS [CreateStudio]
$creadList :: ReadS [CreateStudio]
readsPrec :: Int -> ReadS CreateStudio
$creadsPrec :: Int -> ReadS CreateStudio
Prelude.Read, Int -> CreateStudio -> ShowS
[CreateStudio] -> ShowS
CreateStudio -> String
(Int -> CreateStudio -> ShowS)
-> (CreateStudio -> String)
-> ([CreateStudio] -> ShowS)
-> Show CreateStudio
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateStudio] -> ShowS
$cshowList :: [CreateStudio] -> ShowS
show :: CreateStudio -> String
$cshow :: CreateStudio -> String
showsPrec :: Int -> CreateStudio -> ShowS
$cshowsPrec :: Int -> CreateStudio -> ShowS
Prelude.Show, (forall x. CreateStudio -> Rep CreateStudio x)
-> (forall x. Rep CreateStudio x -> CreateStudio)
-> Generic CreateStudio
forall x. Rep CreateStudio x -> CreateStudio
forall x. CreateStudio -> Rep CreateStudio x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateStudio x -> CreateStudio
$cfrom :: forall x. CreateStudio -> Rep CreateStudio x
Prelude.Generic)
newCreateStudio ::
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
CreateStudio
newCreateStudio :: Text -> Text -> Text -> Text -> CreateStudio
newCreateStudio
Text
pDisplayName_
Text
pStudioName_
Text
pUserRoleArn_
Text
pAdminRoleArn_ =
CreateStudio' :: Maybe StudioEncryptionConfiguration
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Text
-> Text
-> Text
-> Text
-> CreateStudio
CreateStudio'
{ $sel:studioEncryptionConfiguration:CreateStudio' :: Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration =
Maybe StudioEncryptionConfiguration
forall a. Maybe a
Prelude.Nothing,
$sel:clientToken:CreateStudio' :: Maybe Text
clientToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateStudio' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
$sel:displayName:CreateStudio' :: Text
displayName = Text
pDisplayName_,
$sel:studioName:CreateStudio' :: Text
studioName = Text
pStudioName_,
$sel:userRoleArn:CreateStudio' :: Text
userRoleArn = Text
pUserRoleArn_,
$sel:adminRoleArn:CreateStudio' :: Text
adminRoleArn = Text
pAdminRoleArn_
}
createStudio_studioEncryptionConfiguration :: Lens.Lens' CreateStudio (Prelude.Maybe StudioEncryptionConfiguration)
createStudio_studioEncryptionConfiguration :: (Maybe StudioEncryptionConfiguration
-> f (Maybe StudioEncryptionConfiguration))
-> CreateStudio -> f CreateStudio
createStudio_studioEncryptionConfiguration = (CreateStudio -> Maybe StudioEncryptionConfiguration)
-> (CreateStudio
-> Maybe StudioEncryptionConfiguration -> CreateStudio)
-> Lens
CreateStudio
CreateStudio
(Maybe StudioEncryptionConfiguration)
(Maybe StudioEncryptionConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration :: Maybe StudioEncryptionConfiguration
$sel:studioEncryptionConfiguration:CreateStudio' :: CreateStudio -> Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration} -> Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration) (\s :: CreateStudio
s@CreateStudio' {} Maybe StudioEncryptionConfiguration
a -> CreateStudio
s {$sel:studioEncryptionConfiguration:CreateStudio' :: Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration = Maybe StudioEncryptionConfiguration
a} :: CreateStudio)
createStudio_clientToken :: Lens.Lens' CreateStudio (Prelude.Maybe Prelude.Text)
createStudio_clientToken :: (Maybe Text -> f (Maybe Text)) -> CreateStudio -> f CreateStudio
createStudio_clientToken = (CreateStudio -> Maybe Text)
-> (CreateStudio -> Maybe Text -> CreateStudio)
-> Lens CreateStudio CreateStudio (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Maybe Text
clientToken :: Maybe Text
$sel:clientToken:CreateStudio' :: CreateStudio -> Maybe Text
clientToken} -> Maybe Text
clientToken) (\s :: CreateStudio
s@CreateStudio' {} Maybe Text
a -> CreateStudio
s {$sel:clientToken:CreateStudio' :: Maybe Text
clientToken = Maybe Text
a} :: CreateStudio)
createStudio_tags :: Lens.Lens' CreateStudio (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createStudio_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateStudio -> f CreateStudio
createStudio_tags = (CreateStudio -> Maybe (HashMap Text Text))
-> (CreateStudio -> Maybe (HashMap Text Text) -> CreateStudio)
-> Lens
CreateStudio
CreateStudio
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:CreateStudio' :: CreateStudio -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: CreateStudio
s@CreateStudio' {} Maybe (HashMap Text Text)
a -> CreateStudio
s {$sel:tags:CreateStudio' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: CreateStudio) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateStudio -> f CreateStudio)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateStudio
-> f CreateStudio
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
-> Iso
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
(Maybe (HashMap Text Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
(HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createStudio_displayName :: Lens.Lens' CreateStudio Prelude.Text
createStudio_displayName :: (Text -> f Text) -> CreateStudio -> f CreateStudio
createStudio_displayName = (CreateStudio -> Text)
-> (CreateStudio -> Text -> CreateStudio)
-> Lens CreateStudio CreateStudio Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Text
displayName :: Text
$sel:displayName:CreateStudio' :: CreateStudio -> Text
displayName} -> Text
displayName) (\s :: CreateStudio
s@CreateStudio' {} Text
a -> CreateStudio
s {$sel:displayName:CreateStudio' :: Text
displayName = Text
a} :: CreateStudio)
createStudio_studioName :: Lens.Lens' CreateStudio Prelude.Text
createStudio_studioName :: (Text -> f Text) -> CreateStudio -> f CreateStudio
createStudio_studioName = (CreateStudio -> Text)
-> (CreateStudio -> Text -> CreateStudio)
-> Lens CreateStudio CreateStudio Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Text
studioName :: Text
$sel:studioName:CreateStudio' :: CreateStudio -> Text
studioName} -> Text
studioName) (\s :: CreateStudio
s@CreateStudio' {} Text
a -> CreateStudio
s {$sel:studioName:CreateStudio' :: Text
studioName = Text
a} :: CreateStudio)
createStudio_userRoleArn :: Lens.Lens' CreateStudio Prelude.Text
createStudio_userRoleArn :: (Text -> f Text) -> CreateStudio -> f CreateStudio
createStudio_userRoleArn = (CreateStudio -> Text)
-> (CreateStudio -> Text -> CreateStudio)
-> Lens CreateStudio CreateStudio Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Text
userRoleArn :: Text
$sel:userRoleArn:CreateStudio' :: CreateStudio -> Text
userRoleArn} -> Text
userRoleArn) (\s :: CreateStudio
s@CreateStudio' {} Text
a -> CreateStudio
s {$sel:userRoleArn:CreateStudio' :: Text
userRoleArn = Text
a} :: CreateStudio)
createStudio_adminRoleArn :: Lens.Lens' CreateStudio Prelude.Text
createStudio_adminRoleArn :: (Text -> f Text) -> CreateStudio -> f CreateStudio
createStudio_adminRoleArn = (CreateStudio -> Text)
-> (CreateStudio -> Text -> CreateStudio)
-> Lens CreateStudio CreateStudio Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudio' {Text
adminRoleArn :: Text
$sel:adminRoleArn:CreateStudio' :: CreateStudio -> Text
adminRoleArn} -> Text
adminRoleArn) (\s :: CreateStudio
s@CreateStudio' {} Text
a -> CreateStudio
s {$sel:adminRoleArn:CreateStudio' :: Text
adminRoleArn = Text
a} :: CreateStudio)
instance Core.AWSRequest CreateStudio where
type AWSResponse CreateStudio = CreateStudioResponse
request :: CreateStudio -> Request CreateStudio
request = Service -> CreateStudio -> Request CreateStudio
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CreateStudio
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateStudio)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CreateStudio))
-> Logger
-> Service
-> Proxy CreateStudio
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateStudio)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Studio -> Int -> CreateStudioResponse
CreateStudioResponse'
(Maybe Studio -> Int -> CreateStudioResponse)
-> Either String (Maybe Studio)
-> Either String (Int -> CreateStudioResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Studio)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"studio")
Either String (Int -> CreateStudioResponse)
-> Either String Int -> Either String CreateStudioResponse
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 CreateStudio
instance Prelude.NFData CreateStudio
instance Core.ToHeaders CreateStudio where
toHeaders :: CreateStudio -> ResponseHeaders
toHeaders CreateStudio' {Maybe Text
Maybe (HashMap Text Text)
Maybe StudioEncryptionConfiguration
Text
adminRoleArn :: Text
userRoleArn :: Text
studioName :: Text
displayName :: Text
tags :: Maybe (HashMap Text Text)
clientToken :: Maybe Text
studioEncryptionConfiguration :: Maybe StudioEncryptionConfiguration
$sel:adminRoleArn:CreateStudio' :: CreateStudio -> Text
$sel:userRoleArn:CreateStudio' :: CreateStudio -> Text
$sel:studioName:CreateStudio' :: CreateStudio -> Text
$sel:displayName:CreateStudio' :: CreateStudio -> Text
$sel:tags:CreateStudio' :: CreateStudio -> Maybe (HashMap Text Text)
$sel:clientToken:CreateStudio' :: CreateStudio -> Maybe Text
$sel:studioEncryptionConfiguration:CreateStudio' :: CreateStudio -> Maybe StudioEncryptionConfiguration
..} =
[ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Client-Token" HeaderName -> Maybe Text -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe Text
clientToken,
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# (ByteString
"application/x-amz-json-1.1" :: Prelude.ByteString)
]
instance Core.ToJSON CreateStudio where
toJSON :: CreateStudio -> Value
toJSON CreateStudio' {Maybe Text
Maybe (HashMap Text Text)
Maybe StudioEncryptionConfiguration
Text
adminRoleArn :: Text
userRoleArn :: Text
studioName :: Text
displayName :: Text
tags :: Maybe (HashMap Text Text)
clientToken :: Maybe Text
studioEncryptionConfiguration :: Maybe StudioEncryptionConfiguration
$sel:adminRoleArn:CreateStudio' :: CreateStudio -> Text
$sel:userRoleArn:CreateStudio' :: CreateStudio -> Text
$sel:studioName:CreateStudio' :: CreateStudio -> Text
$sel:displayName:CreateStudio' :: CreateStudio -> Text
$sel:tags:CreateStudio' :: CreateStudio -> Maybe (HashMap Text Text)
$sel:clientToken:CreateStudio' :: CreateStudio -> Maybe Text
$sel:studioEncryptionConfiguration:CreateStudio' :: CreateStudio -> Maybe StudioEncryptionConfiguration
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"studioEncryptionConfiguration" Text -> StudioEncryptionConfiguration -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(StudioEncryptionConfiguration -> Pair)
-> Maybe StudioEncryptionConfiguration -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe StudioEncryptionConfiguration
studioEncryptionConfiguration,
(Text
"tags" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
tags,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"displayName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
displayName),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"studioName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
studioName),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"userRoleArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
userRoleArn),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"adminRoleArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
adminRoleArn)
]
)
instance Core.ToPath CreateStudio where
toPath :: CreateStudio -> ByteString
toPath = ByteString -> CreateStudio -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/2020-08-01/studios"
instance Core.ToQuery CreateStudio where
toQuery :: CreateStudio -> QueryString
toQuery = QueryString -> CreateStudio -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CreateStudioResponse = CreateStudioResponse'
{
CreateStudioResponse -> Maybe Studio
studio :: Prelude.Maybe Studio,
CreateStudioResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateStudioResponse -> CreateStudioResponse -> Bool
(CreateStudioResponse -> CreateStudioResponse -> Bool)
-> (CreateStudioResponse -> CreateStudioResponse -> Bool)
-> Eq CreateStudioResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateStudioResponse -> CreateStudioResponse -> Bool
$c/= :: CreateStudioResponse -> CreateStudioResponse -> Bool
== :: CreateStudioResponse -> CreateStudioResponse -> Bool
$c== :: CreateStudioResponse -> CreateStudioResponse -> Bool
Prelude.Eq, ReadPrec [CreateStudioResponse]
ReadPrec CreateStudioResponse
Int -> ReadS CreateStudioResponse
ReadS [CreateStudioResponse]
(Int -> ReadS CreateStudioResponse)
-> ReadS [CreateStudioResponse]
-> ReadPrec CreateStudioResponse
-> ReadPrec [CreateStudioResponse]
-> Read CreateStudioResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateStudioResponse]
$creadListPrec :: ReadPrec [CreateStudioResponse]
readPrec :: ReadPrec CreateStudioResponse
$creadPrec :: ReadPrec CreateStudioResponse
readList :: ReadS [CreateStudioResponse]
$creadList :: ReadS [CreateStudioResponse]
readsPrec :: Int -> ReadS CreateStudioResponse
$creadsPrec :: Int -> ReadS CreateStudioResponse
Prelude.Read, Int -> CreateStudioResponse -> ShowS
[CreateStudioResponse] -> ShowS
CreateStudioResponse -> String
(Int -> CreateStudioResponse -> ShowS)
-> (CreateStudioResponse -> String)
-> ([CreateStudioResponse] -> ShowS)
-> Show CreateStudioResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateStudioResponse] -> ShowS
$cshowList :: [CreateStudioResponse] -> ShowS
show :: CreateStudioResponse -> String
$cshow :: CreateStudioResponse -> String
showsPrec :: Int -> CreateStudioResponse -> ShowS
$cshowsPrec :: Int -> CreateStudioResponse -> ShowS
Prelude.Show, (forall x. CreateStudioResponse -> Rep CreateStudioResponse x)
-> (forall x. Rep CreateStudioResponse x -> CreateStudioResponse)
-> Generic CreateStudioResponse
forall x. Rep CreateStudioResponse x -> CreateStudioResponse
forall x. CreateStudioResponse -> Rep CreateStudioResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateStudioResponse x -> CreateStudioResponse
$cfrom :: forall x. CreateStudioResponse -> Rep CreateStudioResponse x
Prelude.Generic)
newCreateStudioResponse ::
Prelude.Int ->
CreateStudioResponse
newCreateStudioResponse :: Int -> CreateStudioResponse
newCreateStudioResponse Int
pHttpStatus_ =
CreateStudioResponse' :: Maybe Studio -> Int -> CreateStudioResponse
CreateStudioResponse'
{ $sel:studio:CreateStudioResponse' :: Maybe Studio
studio = Maybe Studio
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateStudioResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createStudioResponse_studio :: Lens.Lens' CreateStudioResponse (Prelude.Maybe Studio)
createStudioResponse_studio :: (Maybe Studio -> f (Maybe Studio))
-> CreateStudioResponse -> f CreateStudioResponse
createStudioResponse_studio = (CreateStudioResponse -> Maybe Studio)
-> (CreateStudioResponse -> Maybe Studio -> CreateStudioResponse)
-> Lens
CreateStudioResponse
CreateStudioResponse
(Maybe Studio)
(Maybe Studio)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudioResponse' {Maybe Studio
studio :: Maybe Studio
$sel:studio:CreateStudioResponse' :: CreateStudioResponse -> Maybe Studio
studio} -> Maybe Studio
studio) (\s :: CreateStudioResponse
s@CreateStudioResponse' {} Maybe Studio
a -> CreateStudioResponse
s {$sel:studio:CreateStudioResponse' :: Maybe Studio
studio = Maybe Studio
a} :: CreateStudioResponse)
createStudioResponse_httpStatus :: Lens.Lens' CreateStudioResponse Prelude.Int
createStudioResponse_httpStatus :: (Int -> f Int) -> CreateStudioResponse -> f CreateStudioResponse
createStudioResponse_httpStatus = (CreateStudioResponse -> Int)
-> (CreateStudioResponse -> Int -> CreateStudioResponse)
-> Lens CreateStudioResponse CreateStudioResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateStudioResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateStudioResponse' :: CreateStudioResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateStudioResponse
s@CreateStudioResponse' {} Int
a -> CreateStudioResponse
s {$sel:httpStatus:CreateStudioResponse' :: Int
httpStatus = Int
a} :: CreateStudioResponse)
instance Prelude.NFData CreateStudioResponse