{-# 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.Greengrass.CreateResourceDefinitionVersion
(
CreateResourceDefinitionVersion (..),
newCreateResourceDefinitionVersion,
createResourceDefinitionVersion_amznClientToken,
createResourceDefinitionVersion_resources,
createResourceDefinitionVersion_resourceDefinitionId,
CreateResourceDefinitionVersionResponse (..),
newCreateResourceDefinitionVersionResponse,
createResourceDefinitionVersionResponse_arn,
createResourceDefinitionVersionResponse_creationTimestamp,
createResourceDefinitionVersionResponse_version,
createResourceDefinitionVersionResponse_id,
createResourceDefinitionVersionResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.Greengrass.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 CreateResourceDefinitionVersion = CreateResourceDefinitionVersion'
{
CreateResourceDefinitionVersion -> Maybe Text
amznClientToken :: Prelude.Maybe Prelude.Text,
CreateResourceDefinitionVersion -> Maybe [Resource]
resources :: Prelude.Maybe [Resource],
CreateResourceDefinitionVersion -> Text
resourceDefinitionId :: Prelude.Text
}
deriving (CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool
(CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool)
-> (CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool)
-> Eq CreateResourceDefinitionVersion
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool
$c/= :: CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool
== :: CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool
$c== :: CreateResourceDefinitionVersion
-> CreateResourceDefinitionVersion -> Bool
Prelude.Eq, ReadPrec [CreateResourceDefinitionVersion]
ReadPrec CreateResourceDefinitionVersion
Int -> ReadS CreateResourceDefinitionVersion
ReadS [CreateResourceDefinitionVersion]
(Int -> ReadS CreateResourceDefinitionVersion)
-> ReadS [CreateResourceDefinitionVersion]
-> ReadPrec CreateResourceDefinitionVersion
-> ReadPrec [CreateResourceDefinitionVersion]
-> Read CreateResourceDefinitionVersion
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateResourceDefinitionVersion]
$creadListPrec :: ReadPrec [CreateResourceDefinitionVersion]
readPrec :: ReadPrec CreateResourceDefinitionVersion
$creadPrec :: ReadPrec CreateResourceDefinitionVersion
readList :: ReadS [CreateResourceDefinitionVersion]
$creadList :: ReadS [CreateResourceDefinitionVersion]
readsPrec :: Int -> ReadS CreateResourceDefinitionVersion
$creadsPrec :: Int -> ReadS CreateResourceDefinitionVersion
Prelude.Read, Int -> CreateResourceDefinitionVersion -> ShowS
[CreateResourceDefinitionVersion] -> ShowS
CreateResourceDefinitionVersion -> String
(Int -> CreateResourceDefinitionVersion -> ShowS)
-> (CreateResourceDefinitionVersion -> String)
-> ([CreateResourceDefinitionVersion] -> ShowS)
-> Show CreateResourceDefinitionVersion
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateResourceDefinitionVersion] -> ShowS
$cshowList :: [CreateResourceDefinitionVersion] -> ShowS
show :: CreateResourceDefinitionVersion -> String
$cshow :: CreateResourceDefinitionVersion -> String
showsPrec :: Int -> CreateResourceDefinitionVersion -> ShowS
$cshowsPrec :: Int -> CreateResourceDefinitionVersion -> ShowS
Prelude.Show, (forall x.
CreateResourceDefinitionVersion
-> Rep CreateResourceDefinitionVersion x)
-> (forall x.
Rep CreateResourceDefinitionVersion x
-> CreateResourceDefinitionVersion)
-> Generic CreateResourceDefinitionVersion
forall x.
Rep CreateResourceDefinitionVersion x
-> CreateResourceDefinitionVersion
forall x.
CreateResourceDefinitionVersion
-> Rep CreateResourceDefinitionVersion x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateResourceDefinitionVersion x
-> CreateResourceDefinitionVersion
$cfrom :: forall x.
CreateResourceDefinitionVersion
-> Rep CreateResourceDefinitionVersion x
Prelude.Generic)
newCreateResourceDefinitionVersion ::
Prelude.Text ->
CreateResourceDefinitionVersion
newCreateResourceDefinitionVersion :: Text -> CreateResourceDefinitionVersion
newCreateResourceDefinitionVersion
Text
pResourceDefinitionId_ =
CreateResourceDefinitionVersion' :: Maybe Text
-> Maybe [Resource] -> Text -> CreateResourceDefinitionVersion
CreateResourceDefinitionVersion'
{ $sel:amznClientToken:CreateResourceDefinitionVersion' :: Maybe Text
amznClientToken =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:resources:CreateResourceDefinitionVersion' :: Maybe [Resource]
resources = Maybe [Resource]
forall a. Maybe a
Prelude.Nothing,
$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: Text
resourceDefinitionId =
Text
pResourceDefinitionId_
}
createResourceDefinitionVersion_amznClientToken :: Lens.Lens' CreateResourceDefinitionVersion (Prelude.Maybe Prelude.Text)
createResourceDefinitionVersion_amznClientToken :: (Maybe Text -> f (Maybe Text))
-> CreateResourceDefinitionVersion
-> f CreateResourceDefinitionVersion
createResourceDefinitionVersion_amznClientToken = (CreateResourceDefinitionVersion -> Maybe Text)
-> (CreateResourceDefinitionVersion
-> Maybe Text -> CreateResourceDefinitionVersion)
-> Lens
CreateResourceDefinitionVersion
CreateResourceDefinitionVersion
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersion' {Maybe Text
amznClientToken :: Maybe Text
$sel:amznClientToken:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe Text
amznClientToken} -> Maybe Text
amznClientToken) (\s :: CreateResourceDefinitionVersion
s@CreateResourceDefinitionVersion' {} Maybe Text
a -> CreateResourceDefinitionVersion
s {$sel:amznClientToken:CreateResourceDefinitionVersion' :: Maybe Text
amznClientToken = Maybe Text
a} :: CreateResourceDefinitionVersion)
createResourceDefinitionVersion_resources :: Lens.Lens' CreateResourceDefinitionVersion (Prelude.Maybe [Resource])
createResourceDefinitionVersion_resources :: (Maybe [Resource] -> f (Maybe [Resource]))
-> CreateResourceDefinitionVersion
-> f CreateResourceDefinitionVersion
createResourceDefinitionVersion_resources = (CreateResourceDefinitionVersion -> Maybe [Resource])
-> (CreateResourceDefinitionVersion
-> Maybe [Resource] -> CreateResourceDefinitionVersion)
-> Lens
CreateResourceDefinitionVersion
CreateResourceDefinitionVersion
(Maybe [Resource])
(Maybe [Resource])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersion' {Maybe [Resource]
resources :: Maybe [Resource]
$sel:resources:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe [Resource]
resources} -> Maybe [Resource]
resources) (\s :: CreateResourceDefinitionVersion
s@CreateResourceDefinitionVersion' {} Maybe [Resource]
a -> CreateResourceDefinitionVersion
s {$sel:resources:CreateResourceDefinitionVersion' :: Maybe [Resource]
resources = Maybe [Resource]
a} :: CreateResourceDefinitionVersion) ((Maybe [Resource] -> f (Maybe [Resource]))
-> CreateResourceDefinitionVersion
-> f CreateResourceDefinitionVersion)
-> ((Maybe [Resource] -> f (Maybe [Resource]))
-> Maybe [Resource] -> f (Maybe [Resource]))
-> (Maybe [Resource] -> f (Maybe [Resource]))
-> CreateResourceDefinitionVersion
-> f CreateResourceDefinitionVersion
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Resource] [Resource] [Resource] [Resource]
-> Iso
(Maybe [Resource])
(Maybe [Resource])
(Maybe [Resource])
(Maybe [Resource])
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 [Resource] [Resource] [Resource] [Resource]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createResourceDefinitionVersion_resourceDefinitionId :: Lens.Lens' CreateResourceDefinitionVersion Prelude.Text
createResourceDefinitionVersion_resourceDefinitionId :: (Text -> f Text)
-> CreateResourceDefinitionVersion
-> f CreateResourceDefinitionVersion
createResourceDefinitionVersion_resourceDefinitionId = (CreateResourceDefinitionVersion -> Text)
-> (CreateResourceDefinitionVersion
-> Text -> CreateResourceDefinitionVersion)
-> Lens
CreateResourceDefinitionVersion
CreateResourceDefinitionVersion
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersion' {Text
resourceDefinitionId :: Text
$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Text
resourceDefinitionId} -> Text
resourceDefinitionId) (\s :: CreateResourceDefinitionVersion
s@CreateResourceDefinitionVersion' {} Text
a -> CreateResourceDefinitionVersion
s {$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: Text
resourceDefinitionId = Text
a} :: CreateResourceDefinitionVersion)
instance
Core.AWSRequest
CreateResourceDefinitionVersion
where
type
AWSResponse CreateResourceDefinitionVersion =
CreateResourceDefinitionVersionResponse
request :: CreateResourceDefinitionVersion
-> Request CreateResourceDefinitionVersion
request = Service
-> CreateResourceDefinitionVersion
-> Request CreateResourceDefinitionVersion
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CreateResourceDefinitionVersion
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse CreateResourceDefinitionVersion)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CreateResourceDefinitionVersion))
-> Logger
-> Service
-> Proxy CreateResourceDefinitionVersion
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse CreateResourceDefinitionVersion)))
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 Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse'
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> CreateResourceDefinitionVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> CreateResourceDefinitionVersionResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Arn")
Either
String
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> CreateResourceDefinitionVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe Text -> Int -> CreateResourceDefinitionVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"CreationTimestamp")
Either
String
(Maybe Text
-> Maybe Text -> Int -> CreateResourceDefinitionVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text -> Int -> CreateResourceDefinitionVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Version")
Either
String
(Maybe Text -> Int -> CreateResourceDefinitionVersionResponse)
-> Either String (Maybe Text)
-> Either String (Int -> CreateResourceDefinitionVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Id")
Either String (Int -> CreateResourceDefinitionVersionResponse)
-> Either String Int
-> Either String CreateResourceDefinitionVersionResponse
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
CreateResourceDefinitionVersion
instance
Prelude.NFData
CreateResourceDefinitionVersion
instance
Core.ToHeaders
CreateResourceDefinitionVersion
where
toHeaders :: CreateResourceDefinitionVersion -> ResponseHeaders
toHeaders CreateResourceDefinitionVersion' {Maybe [Resource]
Maybe Text
Text
resourceDefinitionId :: Text
resources :: Maybe [Resource]
amznClientToken :: Maybe Text
$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Text
$sel:resources:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe [Resource]
$sel:amznClientToken:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe Text
..} =
[ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amzn-Client-Token" HeaderName -> Maybe Text -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe Text
amznClientToken,
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 CreateResourceDefinitionVersion where
toJSON :: CreateResourceDefinitionVersion -> Value
toJSON CreateResourceDefinitionVersion' {Maybe [Resource]
Maybe Text
Text
resourceDefinitionId :: Text
resources :: Maybe [Resource]
amznClientToken :: Maybe Text
$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Text
$sel:resources:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe [Resource]
$sel:amznClientToken:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[(Text
"Resources" Text -> [Resource] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([Resource] -> Pair) -> Maybe [Resource] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Resource]
resources]
)
instance Core.ToPath CreateResourceDefinitionVersion where
toPath :: CreateResourceDefinitionVersion -> ByteString
toPath CreateResourceDefinitionVersion' {Maybe [Resource]
Maybe Text
Text
resourceDefinitionId :: Text
resources :: Maybe [Resource]
amznClientToken :: Maybe Text
$sel:resourceDefinitionId:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Text
$sel:resources:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe [Resource]
$sel:amznClientToken:CreateResourceDefinitionVersion' :: CreateResourceDefinitionVersion -> Maybe Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/greengrass/definition/resources/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
resourceDefinitionId,
ByteString
"/versions"
]
instance Core.ToQuery CreateResourceDefinitionVersion where
toQuery :: CreateResourceDefinitionVersion -> QueryString
toQuery = QueryString -> CreateResourceDefinitionVersion -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CreateResourceDefinitionVersionResponse = CreateResourceDefinitionVersionResponse'
{
CreateResourceDefinitionVersionResponse -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
CreateResourceDefinitionVersionResponse -> Maybe Text
creationTimestamp :: Prelude.Maybe Prelude.Text,
CreateResourceDefinitionVersionResponse -> Maybe Text
version :: Prelude.Maybe Prelude.Text,
CreateResourceDefinitionVersionResponse -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
CreateResourceDefinitionVersionResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool
(CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool)
-> (CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool)
-> Eq CreateResourceDefinitionVersionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool
$c/= :: CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool
== :: CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool
$c== :: CreateResourceDefinitionVersionResponse
-> CreateResourceDefinitionVersionResponse -> Bool
Prelude.Eq, ReadPrec [CreateResourceDefinitionVersionResponse]
ReadPrec CreateResourceDefinitionVersionResponse
Int -> ReadS CreateResourceDefinitionVersionResponse
ReadS [CreateResourceDefinitionVersionResponse]
(Int -> ReadS CreateResourceDefinitionVersionResponse)
-> ReadS [CreateResourceDefinitionVersionResponse]
-> ReadPrec CreateResourceDefinitionVersionResponse
-> ReadPrec [CreateResourceDefinitionVersionResponse]
-> Read CreateResourceDefinitionVersionResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateResourceDefinitionVersionResponse]
$creadListPrec :: ReadPrec [CreateResourceDefinitionVersionResponse]
readPrec :: ReadPrec CreateResourceDefinitionVersionResponse
$creadPrec :: ReadPrec CreateResourceDefinitionVersionResponse
readList :: ReadS [CreateResourceDefinitionVersionResponse]
$creadList :: ReadS [CreateResourceDefinitionVersionResponse]
readsPrec :: Int -> ReadS CreateResourceDefinitionVersionResponse
$creadsPrec :: Int -> ReadS CreateResourceDefinitionVersionResponse
Prelude.Read, Int -> CreateResourceDefinitionVersionResponse -> ShowS
[CreateResourceDefinitionVersionResponse] -> ShowS
CreateResourceDefinitionVersionResponse -> String
(Int -> CreateResourceDefinitionVersionResponse -> ShowS)
-> (CreateResourceDefinitionVersionResponse -> String)
-> ([CreateResourceDefinitionVersionResponse] -> ShowS)
-> Show CreateResourceDefinitionVersionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateResourceDefinitionVersionResponse] -> ShowS
$cshowList :: [CreateResourceDefinitionVersionResponse] -> ShowS
show :: CreateResourceDefinitionVersionResponse -> String
$cshow :: CreateResourceDefinitionVersionResponse -> String
showsPrec :: Int -> CreateResourceDefinitionVersionResponse -> ShowS
$cshowsPrec :: Int -> CreateResourceDefinitionVersionResponse -> ShowS
Prelude.Show, (forall x.
CreateResourceDefinitionVersionResponse
-> Rep CreateResourceDefinitionVersionResponse x)
-> (forall x.
Rep CreateResourceDefinitionVersionResponse x
-> CreateResourceDefinitionVersionResponse)
-> Generic CreateResourceDefinitionVersionResponse
forall x.
Rep CreateResourceDefinitionVersionResponse x
-> CreateResourceDefinitionVersionResponse
forall x.
CreateResourceDefinitionVersionResponse
-> Rep CreateResourceDefinitionVersionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateResourceDefinitionVersionResponse x
-> CreateResourceDefinitionVersionResponse
$cfrom :: forall x.
CreateResourceDefinitionVersionResponse
-> Rep CreateResourceDefinitionVersionResponse x
Prelude.Generic)
newCreateResourceDefinitionVersionResponse ::
Prelude.Int ->
CreateResourceDefinitionVersionResponse
newCreateResourceDefinitionVersionResponse :: Int -> CreateResourceDefinitionVersionResponse
newCreateResourceDefinitionVersionResponse
Int
pHttpStatus_ =
CreateResourceDefinitionVersionResponse' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse'
{ $sel:arn:CreateResourceDefinitionVersionResponse' :: Maybe Text
arn =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:creationTimestamp:CreateResourceDefinitionVersionResponse' :: Maybe Text
creationTimestamp =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:version:CreateResourceDefinitionVersionResponse' :: Maybe Text
version = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:id:CreateResourceDefinitionVersionResponse' :: Maybe Text
id = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateResourceDefinitionVersionResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createResourceDefinitionVersionResponse_arn :: Lens.Lens' CreateResourceDefinitionVersionResponse (Prelude.Maybe Prelude.Text)
createResourceDefinitionVersionResponse_arn :: (Maybe Text -> f (Maybe Text))
-> CreateResourceDefinitionVersionResponse
-> f CreateResourceDefinitionVersionResponse
createResourceDefinitionVersionResponse_arn = (CreateResourceDefinitionVersionResponse -> Maybe Text)
-> (CreateResourceDefinitionVersionResponse
-> Maybe Text -> CreateResourceDefinitionVersionResponse)
-> Lens
CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersionResponse' {Maybe Text
arn :: Maybe Text
$sel:arn:CreateResourceDefinitionVersionResponse' :: CreateResourceDefinitionVersionResponse -> Maybe Text
arn} -> Maybe Text
arn) (\s :: CreateResourceDefinitionVersionResponse
s@CreateResourceDefinitionVersionResponse' {} Maybe Text
a -> CreateResourceDefinitionVersionResponse
s {$sel:arn:CreateResourceDefinitionVersionResponse' :: Maybe Text
arn = Maybe Text
a} :: CreateResourceDefinitionVersionResponse)
createResourceDefinitionVersionResponse_creationTimestamp :: Lens.Lens' CreateResourceDefinitionVersionResponse (Prelude.Maybe Prelude.Text)
createResourceDefinitionVersionResponse_creationTimestamp :: (Maybe Text -> f (Maybe Text))
-> CreateResourceDefinitionVersionResponse
-> f CreateResourceDefinitionVersionResponse
createResourceDefinitionVersionResponse_creationTimestamp = (CreateResourceDefinitionVersionResponse -> Maybe Text)
-> (CreateResourceDefinitionVersionResponse
-> Maybe Text -> CreateResourceDefinitionVersionResponse)
-> Lens
CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersionResponse' {Maybe Text
creationTimestamp :: Maybe Text
$sel:creationTimestamp:CreateResourceDefinitionVersionResponse' :: CreateResourceDefinitionVersionResponse -> Maybe Text
creationTimestamp} -> Maybe Text
creationTimestamp) (\s :: CreateResourceDefinitionVersionResponse
s@CreateResourceDefinitionVersionResponse' {} Maybe Text
a -> CreateResourceDefinitionVersionResponse
s {$sel:creationTimestamp:CreateResourceDefinitionVersionResponse' :: Maybe Text
creationTimestamp = Maybe Text
a} :: CreateResourceDefinitionVersionResponse)
createResourceDefinitionVersionResponse_version :: Lens.Lens' CreateResourceDefinitionVersionResponse (Prelude.Maybe Prelude.Text)
createResourceDefinitionVersionResponse_version :: (Maybe Text -> f (Maybe Text))
-> CreateResourceDefinitionVersionResponse
-> f CreateResourceDefinitionVersionResponse
createResourceDefinitionVersionResponse_version = (CreateResourceDefinitionVersionResponse -> Maybe Text)
-> (CreateResourceDefinitionVersionResponse
-> Maybe Text -> CreateResourceDefinitionVersionResponse)
-> Lens
CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersionResponse' {Maybe Text
version :: Maybe Text
$sel:version:CreateResourceDefinitionVersionResponse' :: CreateResourceDefinitionVersionResponse -> Maybe Text
version} -> Maybe Text
version) (\s :: CreateResourceDefinitionVersionResponse
s@CreateResourceDefinitionVersionResponse' {} Maybe Text
a -> CreateResourceDefinitionVersionResponse
s {$sel:version:CreateResourceDefinitionVersionResponse' :: Maybe Text
version = Maybe Text
a} :: CreateResourceDefinitionVersionResponse)
createResourceDefinitionVersionResponse_id :: Lens.Lens' CreateResourceDefinitionVersionResponse (Prelude.Maybe Prelude.Text)
createResourceDefinitionVersionResponse_id :: (Maybe Text -> f (Maybe Text))
-> CreateResourceDefinitionVersionResponse
-> f CreateResourceDefinitionVersionResponse
createResourceDefinitionVersionResponse_id = (CreateResourceDefinitionVersionResponse -> Maybe Text)
-> (CreateResourceDefinitionVersionResponse
-> Maybe Text -> CreateResourceDefinitionVersionResponse)
-> Lens
CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersionResponse' {Maybe Text
id :: Maybe Text
$sel:id:CreateResourceDefinitionVersionResponse' :: CreateResourceDefinitionVersionResponse -> Maybe Text
id} -> Maybe Text
id) (\s :: CreateResourceDefinitionVersionResponse
s@CreateResourceDefinitionVersionResponse' {} Maybe Text
a -> CreateResourceDefinitionVersionResponse
s {$sel:id:CreateResourceDefinitionVersionResponse' :: Maybe Text
id = Maybe Text
a} :: CreateResourceDefinitionVersionResponse)
createResourceDefinitionVersionResponse_httpStatus :: Lens.Lens' CreateResourceDefinitionVersionResponse Prelude.Int
createResourceDefinitionVersionResponse_httpStatus :: (Int -> f Int)
-> CreateResourceDefinitionVersionResponse
-> f CreateResourceDefinitionVersionResponse
createResourceDefinitionVersionResponse_httpStatus = (CreateResourceDefinitionVersionResponse -> Int)
-> (CreateResourceDefinitionVersionResponse
-> Int -> CreateResourceDefinitionVersionResponse)
-> Lens
CreateResourceDefinitionVersionResponse
CreateResourceDefinitionVersionResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateResourceDefinitionVersionResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateResourceDefinitionVersionResponse' :: CreateResourceDefinitionVersionResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateResourceDefinitionVersionResponse
s@CreateResourceDefinitionVersionResponse' {} Int
a -> CreateResourceDefinitionVersionResponse
s {$sel:httpStatus:CreateResourceDefinitionVersionResponse' :: Int
httpStatus = Int
a} :: CreateResourceDefinitionVersionResponse)
instance
Prelude.NFData
CreateResourceDefinitionVersionResponse