{-# 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.Proton.CreateServiceTemplate
(
CreateServiceTemplate (..),
newCreateServiceTemplate,
createServiceTemplate_displayName,
createServiceTemplate_encryptionKey,
createServiceTemplate_pipelineProvisioning,
createServiceTemplate_description,
createServiceTemplate_tags,
createServiceTemplate_name,
CreateServiceTemplateResponse (..),
newCreateServiceTemplateResponse,
createServiceTemplateResponse_httpStatus,
createServiceTemplateResponse_serviceTemplate,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.Proton.Types
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateServiceTemplate = CreateServiceTemplate'
{
CreateServiceTemplate -> Maybe (Sensitive Text)
displayName :: Prelude.Maybe (Core.Sensitive Prelude.Text),
CreateServiceTemplate -> Maybe Text
encryptionKey :: Prelude.Maybe Prelude.Text,
CreateServiceTemplate -> Maybe Provisioning
pipelineProvisioning :: Prelude.Maybe Provisioning,
CreateServiceTemplate -> Maybe (Sensitive Text)
description :: Prelude.Maybe (Core.Sensitive Prelude.Text),
CreateServiceTemplate -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
CreateServiceTemplate -> Text
name :: Prelude.Text
}
deriving (CreateServiceTemplate -> CreateServiceTemplate -> Bool
(CreateServiceTemplate -> CreateServiceTemplate -> Bool)
-> (CreateServiceTemplate -> CreateServiceTemplate -> Bool)
-> Eq CreateServiceTemplate
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateServiceTemplate -> CreateServiceTemplate -> Bool
$c/= :: CreateServiceTemplate -> CreateServiceTemplate -> Bool
== :: CreateServiceTemplate -> CreateServiceTemplate -> Bool
$c== :: CreateServiceTemplate -> CreateServiceTemplate -> Bool
Prelude.Eq, Int -> CreateServiceTemplate -> ShowS
[CreateServiceTemplate] -> ShowS
CreateServiceTemplate -> String
(Int -> CreateServiceTemplate -> ShowS)
-> (CreateServiceTemplate -> String)
-> ([CreateServiceTemplate] -> ShowS)
-> Show CreateServiceTemplate
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateServiceTemplate] -> ShowS
$cshowList :: [CreateServiceTemplate] -> ShowS
show :: CreateServiceTemplate -> String
$cshow :: CreateServiceTemplate -> String
showsPrec :: Int -> CreateServiceTemplate -> ShowS
$cshowsPrec :: Int -> CreateServiceTemplate -> ShowS
Prelude.Show, (forall x. CreateServiceTemplate -> Rep CreateServiceTemplate x)
-> (forall x. Rep CreateServiceTemplate x -> CreateServiceTemplate)
-> Generic CreateServiceTemplate
forall x. Rep CreateServiceTemplate x -> CreateServiceTemplate
forall x. CreateServiceTemplate -> Rep CreateServiceTemplate x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateServiceTemplate x -> CreateServiceTemplate
$cfrom :: forall x. CreateServiceTemplate -> Rep CreateServiceTemplate x
Prelude.Generic)
newCreateServiceTemplate ::
Prelude.Text ->
CreateServiceTemplate
newCreateServiceTemplate :: Text -> CreateServiceTemplate
newCreateServiceTemplate Text
pName_ =
CreateServiceTemplate' :: Maybe (Sensitive Text)
-> Maybe Text
-> Maybe Provisioning
-> Maybe (Sensitive Text)
-> Maybe [Tag]
-> Text
-> CreateServiceTemplate
CreateServiceTemplate'
{ $sel:displayName:CreateServiceTemplate' :: Maybe (Sensitive Text)
displayName =
Maybe (Sensitive Text)
forall a. Maybe a
Prelude.Nothing,
$sel:encryptionKey:CreateServiceTemplate' :: Maybe Text
encryptionKey = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:pipelineProvisioning:CreateServiceTemplate' :: Maybe Provisioning
pipelineProvisioning = Maybe Provisioning
forall a. Maybe a
Prelude.Nothing,
$sel:description:CreateServiceTemplate' :: Maybe (Sensitive Text)
description = Maybe (Sensitive Text)
forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateServiceTemplate' :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing,
$sel:name:CreateServiceTemplate' :: Text
name = Text
pName_
}
createServiceTemplate_displayName :: Lens.Lens' CreateServiceTemplate (Prelude.Maybe Prelude.Text)
createServiceTemplate_displayName :: (Maybe Text -> f (Maybe Text))
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_displayName = (CreateServiceTemplate -> Maybe (Sensitive Text))
-> (CreateServiceTemplate
-> Maybe (Sensitive Text) -> CreateServiceTemplate)
-> Lens
CreateServiceTemplate
CreateServiceTemplate
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Maybe (Sensitive Text)
displayName :: Maybe (Sensitive Text)
$sel:displayName:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe (Sensitive Text)
displayName} -> Maybe (Sensitive Text)
displayName) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Maybe (Sensitive Text)
a -> CreateServiceTemplate
s {$sel:displayName:CreateServiceTemplate' :: Maybe (Sensitive Text)
displayName = Maybe (Sensitive Text)
a} :: CreateServiceTemplate) ((Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> CreateServiceTemplate -> f CreateServiceTemplate)
-> ((Maybe Text -> f (Maybe Text))
-> Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> (Maybe Text -> f (Maybe Text))
-> CreateServiceTemplate
-> f CreateServiceTemplate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso (Sensitive Text) (Sensitive Text) Text Text
-> Iso
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
(Maybe Text)
(Maybe 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 (Sensitive Text) (Sensitive Text) Text Text
forall a. Iso' (Sensitive a) a
Core._Sensitive
createServiceTemplate_encryptionKey :: Lens.Lens' CreateServiceTemplate (Prelude.Maybe Prelude.Text)
createServiceTemplate_encryptionKey :: (Maybe Text -> f (Maybe Text))
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_encryptionKey = (CreateServiceTemplate -> Maybe Text)
-> (CreateServiceTemplate -> Maybe Text -> CreateServiceTemplate)
-> Lens
CreateServiceTemplate
CreateServiceTemplate
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Maybe Text
encryptionKey :: Maybe Text
$sel:encryptionKey:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe Text
encryptionKey} -> Maybe Text
encryptionKey) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Maybe Text
a -> CreateServiceTemplate
s {$sel:encryptionKey:CreateServiceTemplate' :: Maybe Text
encryptionKey = Maybe Text
a} :: CreateServiceTemplate)
createServiceTemplate_pipelineProvisioning :: Lens.Lens' CreateServiceTemplate (Prelude.Maybe Provisioning)
createServiceTemplate_pipelineProvisioning :: (Maybe Provisioning -> f (Maybe Provisioning))
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_pipelineProvisioning = (CreateServiceTemplate -> Maybe Provisioning)
-> (CreateServiceTemplate
-> Maybe Provisioning -> CreateServiceTemplate)
-> Lens
CreateServiceTemplate
CreateServiceTemplate
(Maybe Provisioning)
(Maybe Provisioning)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Maybe Provisioning
pipelineProvisioning :: Maybe Provisioning
$sel:pipelineProvisioning:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe Provisioning
pipelineProvisioning} -> Maybe Provisioning
pipelineProvisioning) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Maybe Provisioning
a -> CreateServiceTemplate
s {$sel:pipelineProvisioning:CreateServiceTemplate' :: Maybe Provisioning
pipelineProvisioning = Maybe Provisioning
a} :: CreateServiceTemplate)
createServiceTemplate_description :: Lens.Lens' CreateServiceTemplate (Prelude.Maybe Prelude.Text)
createServiceTemplate_description :: (Maybe Text -> f (Maybe Text))
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_description = (CreateServiceTemplate -> Maybe (Sensitive Text))
-> (CreateServiceTemplate
-> Maybe (Sensitive Text) -> CreateServiceTemplate)
-> Lens
CreateServiceTemplate
CreateServiceTemplate
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Maybe (Sensitive Text)
description :: Maybe (Sensitive Text)
$sel:description:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe (Sensitive Text)
description} -> Maybe (Sensitive Text)
description) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Maybe (Sensitive Text)
a -> CreateServiceTemplate
s {$sel:description:CreateServiceTemplate' :: Maybe (Sensitive Text)
description = Maybe (Sensitive Text)
a} :: CreateServiceTemplate) ((Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> CreateServiceTemplate -> f CreateServiceTemplate)
-> ((Maybe Text -> f (Maybe Text))
-> Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> (Maybe Text -> f (Maybe Text))
-> CreateServiceTemplate
-> f CreateServiceTemplate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso (Sensitive Text) (Sensitive Text) Text Text
-> Iso
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
(Maybe Text)
(Maybe 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 (Sensitive Text) (Sensitive Text) Text Text
forall a. Iso' (Sensitive a) a
Core._Sensitive
createServiceTemplate_tags :: Lens.Lens' CreateServiceTemplate (Prelude.Maybe [Tag])
createServiceTemplate_tags :: (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_tags = (CreateServiceTemplate -> Maybe [Tag])
-> (CreateServiceTemplate -> Maybe [Tag] -> CreateServiceTemplate)
-> Lens
CreateServiceTemplate
CreateServiceTemplate
(Maybe [Tag])
(Maybe [Tag])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Maybe [Tag]
a -> CreateServiceTemplate
s {$sel:tags:CreateServiceTemplate' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: CreateServiceTemplate) ((Maybe [Tag] -> f (Maybe [Tag]))
-> CreateServiceTemplate -> f CreateServiceTemplate)
-> ((Maybe [Tag] -> f (Maybe [Tag]))
-> Maybe [Tag] -> f (Maybe [Tag]))
-> (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateServiceTemplate
-> f CreateServiceTemplate
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Tag] [Tag] [Tag] [Tag]
-> Iso (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag])
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 [Tag] [Tag] [Tag] [Tag]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createServiceTemplate_name :: Lens.Lens' CreateServiceTemplate Prelude.Text
createServiceTemplate_name :: (Text -> f Text)
-> CreateServiceTemplate -> f CreateServiceTemplate
createServiceTemplate_name = (CreateServiceTemplate -> Text)
-> (CreateServiceTemplate -> Text -> CreateServiceTemplate)
-> Lens CreateServiceTemplate CreateServiceTemplate Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplate' {Text
name :: Text
$sel:name:CreateServiceTemplate' :: CreateServiceTemplate -> Text
name} -> Text
name) (\s :: CreateServiceTemplate
s@CreateServiceTemplate' {} Text
a -> CreateServiceTemplate
s {$sel:name:CreateServiceTemplate' :: Text
name = Text
a} :: CreateServiceTemplate)
instance Core.AWSRequest CreateServiceTemplate where
type
AWSResponse CreateServiceTemplate =
CreateServiceTemplateResponse
request :: CreateServiceTemplate -> Request CreateServiceTemplate
request = Service -> CreateServiceTemplate -> Request CreateServiceTemplate
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CreateServiceTemplate
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse CreateServiceTemplate)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CreateServiceTemplate))
-> Logger
-> Service
-> Proxy CreateServiceTemplate
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse CreateServiceTemplate)))
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 ->
Int -> ServiceTemplate -> CreateServiceTemplateResponse
CreateServiceTemplateResponse'
(Int -> ServiceTemplate -> CreateServiceTemplateResponse)
-> Either String Int
-> Either String (ServiceTemplate -> CreateServiceTemplateResponse)
forall (f :: * -> *) a b. Functor 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))
Either String (ServiceTemplate -> CreateServiceTemplateResponse)
-> Either String ServiceTemplate
-> Either String CreateServiceTemplateResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String ServiceTemplate
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"serviceTemplate")
)
instance Prelude.Hashable CreateServiceTemplate
instance Prelude.NFData CreateServiceTemplate
instance Core.ToHeaders CreateServiceTemplate where
toHeaders :: CreateServiceTemplate -> ResponseHeaders
toHeaders =
ResponseHeaders -> CreateServiceTemplate -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AwsProton20200720.CreateServiceTemplate" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.0" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON CreateServiceTemplate where
toJSON :: CreateServiceTemplate -> Value
toJSON CreateServiceTemplate' {Maybe [Tag]
Maybe Text
Maybe (Sensitive Text)
Maybe Provisioning
Text
name :: Text
tags :: Maybe [Tag]
description :: Maybe (Sensitive Text)
pipelineProvisioning :: Maybe Provisioning
encryptionKey :: Maybe Text
displayName :: Maybe (Sensitive Text)
$sel:name:CreateServiceTemplate' :: CreateServiceTemplate -> Text
$sel:tags:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe [Tag]
$sel:description:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe (Sensitive Text)
$sel:pipelineProvisioning:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe Provisioning
$sel:encryptionKey:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe Text
$sel:displayName:CreateServiceTemplate' :: CreateServiceTemplate -> Maybe (Sensitive Text)
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"displayName" Text -> Sensitive Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Sensitive Text -> Pair) -> Maybe (Sensitive Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Sensitive Text)
displayName,
(Text
"encryptionKey" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
encryptionKey,
(Text
"pipelineProvisioning" Text -> Provisioning -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Provisioning -> Pair) -> Maybe Provisioning -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Provisioning
pipelineProvisioning,
(Text
"description" Text -> Sensitive Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Sensitive Text -> Pair) -> Maybe (Sensitive Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Sensitive Text)
description,
(Text
"tags" Text -> [Tag] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Tag] -> Pair) -> Maybe [Tag] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name)
]
)
instance Core.ToPath CreateServiceTemplate where
toPath :: CreateServiceTemplate -> ByteString
toPath = ByteString -> CreateServiceTemplate -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery CreateServiceTemplate where
toQuery :: CreateServiceTemplate -> QueryString
toQuery = QueryString -> CreateServiceTemplate -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CreateServiceTemplateResponse = CreateServiceTemplateResponse'
{
CreateServiceTemplateResponse -> Int
httpStatus :: Prelude.Int,
CreateServiceTemplateResponse -> ServiceTemplate
serviceTemplate :: ServiceTemplate
}
deriving (CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool
(CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool)
-> (CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool)
-> Eq CreateServiceTemplateResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool
$c/= :: CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool
== :: CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool
$c== :: CreateServiceTemplateResponse
-> CreateServiceTemplateResponse -> Bool
Prelude.Eq, Int -> CreateServiceTemplateResponse -> ShowS
[CreateServiceTemplateResponse] -> ShowS
CreateServiceTemplateResponse -> String
(Int -> CreateServiceTemplateResponse -> ShowS)
-> (CreateServiceTemplateResponse -> String)
-> ([CreateServiceTemplateResponse] -> ShowS)
-> Show CreateServiceTemplateResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateServiceTemplateResponse] -> ShowS
$cshowList :: [CreateServiceTemplateResponse] -> ShowS
show :: CreateServiceTemplateResponse -> String
$cshow :: CreateServiceTemplateResponse -> String
showsPrec :: Int -> CreateServiceTemplateResponse -> ShowS
$cshowsPrec :: Int -> CreateServiceTemplateResponse -> ShowS
Prelude.Show, (forall x.
CreateServiceTemplateResponse
-> Rep CreateServiceTemplateResponse x)
-> (forall x.
Rep CreateServiceTemplateResponse x
-> CreateServiceTemplateResponse)
-> Generic CreateServiceTemplateResponse
forall x.
Rep CreateServiceTemplateResponse x
-> CreateServiceTemplateResponse
forall x.
CreateServiceTemplateResponse
-> Rep CreateServiceTemplateResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateServiceTemplateResponse x
-> CreateServiceTemplateResponse
$cfrom :: forall x.
CreateServiceTemplateResponse
-> Rep CreateServiceTemplateResponse x
Prelude.Generic)
newCreateServiceTemplateResponse ::
Prelude.Int ->
ServiceTemplate ->
CreateServiceTemplateResponse
newCreateServiceTemplateResponse :: Int -> ServiceTemplate -> CreateServiceTemplateResponse
newCreateServiceTemplateResponse
Int
pHttpStatus_
ServiceTemplate
pServiceTemplate_ =
CreateServiceTemplateResponse' :: Int -> ServiceTemplate -> CreateServiceTemplateResponse
CreateServiceTemplateResponse'
{ $sel:httpStatus:CreateServiceTemplateResponse' :: Int
httpStatus =
Int
pHttpStatus_,
$sel:serviceTemplate:CreateServiceTemplateResponse' :: ServiceTemplate
serviceTemplate = ServiceTemplate
pServiceTemplate_
}
createServiceTemplateResponse_httpStatus :: Lens.Lens' CreateServiceTemplateResponse Prelude.Int
createServiceTemplateResponse_httpStatus :: (Int -> f Int)
-> CreateServiceTemplateResponse -> f CreateServiceTemplateResponse
createServiceTemplateResponse_httpStatus = (CreateServiceTemplateResponse -> Int)
-> (CreateServiceTemplateResponse
-> Int -> CreateServiceTemplateResponse)
-> Lens
CreateServiceTemplateResponse CreateServiceTemplateResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplateResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateServiceTemplateResponse' :: CreateServiceTemplateResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateServiceTemplateResponse
s@CreateServiceTemplateResponse' {} Int
a -> CreateServiceTemplateResponse
s {$sel:httpStatus:CreateServiceTemplateResponse' :: Int
httpStatus = Int
a} :: CreateServiceTemplateResponse)
createServiceTemplateResponse_serviceTemplate :: Lens.Lens' CreateServiceTemplateResponse ServiceTemplate
createServiceTemplateResponse_serviceTemplate :: (ServiceTemplate -> f ServiceTemplate)
-> CreateServiceTemplateResponse -> f CreateServiceTemplateResponse
createServiceTemplateResponse_serviceTemplate = (CreateServiceTemplateResponse -> ServiceTemplate)
-> (CreateServiceTemplateResponse
-> ServiceTemplate -> CreateServiceTemplateResponse)
-> Lens
CreateServiceTemplateResponse
CreateServiceTemplateResponse
ServiceTemplate
ServiceTemplate
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateServiceTemplateResponse' {ServiceTemplate
serviceTemplate :: ServiceTemplate
$sel:serviceTemplate:CreateServiceTemplateResponse' :: CreateServiceTemplateResponse -> ServiceTemplate
serviceTemplate} -> ServiceTemplate
serviceTemplate) (\s :: CreateServiceTemplateResponse
s@CreateServiceTemplateResponse' {} ServiceTemplate
a -> CreateServiceTemplateResponse
s {$sel:serviceTemplate:CreateServiceTemplateResponse' :: ServiceTemplate
serviceTemplate = ServiceTemplate
a} :: CreateServiceTemplateResponse)
instance Prelude.NFData CreateServiceTemplateResponse