{-# 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.Panorama.DescribePackageVersion
(
DescribePackageVersion (..),
newDescribePackageVersion,
describePackageVersion_patchVersion,
describePackageVersion_ownerAccount,
describePackageVersion_packageId,
describePackageVersion_packageVersion,
DescribePackageVersionResponse (..),
newDescribePackageVersionResponse,
describePackageVersionResponse_statusDescription,
describePackageVersionResponse_packageArn,
describePackageVersionResponse_registeredTime,
describePackageVersionResponse_ownerAccount,
describePackageVersionResponse_httpStatus,
describePackageVersionResponse_packageId,
describePackageVersionResponse_packageName,
describePackageVersionResponse_packageVersion,
describePackageVersionResponse_patchVersion,
describePackageVersionResponse_isLatestPatch,
describePackageVersionResponse_status,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Panorama.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DescribePackageVersion = DescribePackageVersion'
{
DescribePackageVersion -> Maybe Text
patchVersion :: Prelude.Maybe Prelude.Text,
DescribePackageVersion -> Maybe Text
ownerAccount :: Prelude.Maybe Prelude.Text,
DescribePackageVersion -> Text
packageId :: Prelude.Text,
DescribePackageVersion -> Text
packageVersion :: Prelude.Text
}
deriving (DescribePackageVersion -> DescribePackageVersion -> Bool
(DescribePackageVersion -> DescribePackageVersion -> Bool)
-> (DescribePackageVersion -> DescribePackageVersion -> Bool)
-> Eq DescribePackageVersion
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribePackageVersion -> DescribePackageVersion -> Bool
$c/= :: DescribePackageVersion -> DescribePackageVersion -> Bool
== :: DescribePackageVersion -> DescribePackageVersion -> Bool
$c== :: DescribePackageVersion -> DescribePackageVersion -> Bool
Prelude.Eq, ReadPrec [DescribePackageVersion]
ReadPrec DescribePackageVersion
Int -> ReadS DescribePackageVersion
ReadS [DescribePackageVersion]
(Int -> ReadS DescribePackageVersion)
-> ReadS [DescribePackageVersion]
-> ReadPrec DescribePackageVersion
-> ReadPrec [DescribePackageVersion]
-> Read DescribePackageVersion
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribePackageVersion]
$creadListPrec :: ReadPrec [DescribePackageVersion]
readPrec :: ReadPrec DescribePackageVersion
$creadPrec :: ReadPrec DescribePackageVersion
readList :: ReadS [DescribePackageVersion]
$creadList :: ReadS [DescribePackageVersion]
readsPrec :: Int -> ReadS DescribePackageVersion
$creadsPrec :: Int -> ReadS DescribePackageVersion
Prelude.Read, Int -> DescribePackageVersion -> ShowS
[DescribePackageVersion] -> ShowS
DescribePackageVersion -> String
(Int -> DescribePackageVersion -> ShowS)
-> (DescribePackageVersion -> String)
-> ([DescribePackageVersion] -> ShowS)
-> Show DescribePackageVersion
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribePackageVersion] -> ShowS
$cshowList :: [DescribePackageVersion] -> ShowS
show :: DescribePackageVersion -> String
$cshow :: DescribePackageVersion -> String
showsPrec :: Int -> DescribePackageVersion -> ShowS
$cshowsPrec :: Int -> DescribePackageVersion -> ShowS
Prelude.Show, (forall x. DescribePackageVersion -> Rep DescribePackageVersion x)
-> (forall x.
Rep DescribePackageVersion x -> DescribePackageVersion)
-> Generic DescribePackageVersion
forall x. Rep DescribePackageVersion x -> DescribePackageVersion
forall x. DescribePackageVersion -> Rep DescribePackageVersion x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribePackageVersion x -> DescribePackageVersion
$cfrom :: forall x. DescribePackageVersion -> Rep DescribePackageVersion x
Prelude.Generic)
newDescribePackageVersion ::
Prelude.Text ->
Prelude.Text ->
DescribePackageVersion
newDescribePackageVersion :: Text -> Text -> DescribePackageVersion
newDescribePackageVersion
Text
pPackageId_
Text
pPackageVersion_ =
DescribePackageVersion' :: Maybe Text -> Maybe Text -> Text -> Text -> DescribePackageVersion
DescribePackageVersion'
{ $sel:patchVersion:DescribePackageVersion' :: Maybe Text
patchVersion =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:ownerAccount:DescribePackageVersion' :: Maybe Text
ownerAccount = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:packageId:DescribePackageVersion' :: Text
packageId = Text
pPackageId_,
$sel:packageVersion:DescribePackageVersion' :: Text
packageVersion = Text
pPackageVersion_
}
describePackageVersion_patchVersion :: Lens.Lens' DescribePackageVersion (Prelude.Maybe Prelude.Text)
describePackageVersion_patchVersion :: (Maybe Text -> f (Maybe Text))
-> DescribePackageVersion -> f DescribePackageVersion
describePackageVersion_patchVersion = (DescribePackageVersion -> Maybe Text)
-> (DescribePackageVersion -> Maybe Text -> DescribePackageVersion)
-> Lens
DescribePackageVersion
DescribePackageVersion
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersion' {Maybe Text
patchVersion :: Maybe Text
$sel:patchVersion:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
patchVersion} -> Maybe Text
patchVersion) (\s :: DescribePackageVersion
s@DescribePackageVersion' {} Maybe Text
a -> DescribePackageVersion
s {$sel:patchVersion:DescribePackageVersion' :: Maybe Text
patchVersion = Maybe Text
a} :: DescribePackageVersion)
describePackageVersion_ownerAccount :: Lens.Lens' DescribePackageVersion (Prelude.Maybe Prelude.Text)
describePackageVersion_ownerAccount :: (Maybe Text -> f (Maybe Text))
-> DescribePackageVersion -> f DescribePackageVersion
describePackageVersion_ownerAccount = (DescribePackageVersion -> Maybe Text)
-> (DescribePackageVersion -> Maybe Text -> DescribePackageVersion)
-> Lens
DescribePackageVersion
DescribePackageVersion
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersion' {Maybe Text
ownerAccount :: Maybe Text
$sel:ownerAccount:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
ownerAccount} -> Maybe Text
ownerAccount) (\s :: DescribePackageVersion
s@DescribePackageVersion' {} Maybe Text
a -> DescribePackageVersion
s {$sel:ownerAccount:DescribePackageVersion' :: Maybe Text
ownerAccount = Maybe Text
a} :: DescribePackageVersion)
describePackageVersion_packageId :: Lens.Lens' DescribePackageVersion Prelude.Text
describePackageVersion_packageId :: (Text -> f Text)
-> DescribePackageVersion -> f DescribePackageVersion
describePackageVersion_packageId = (DescribePackageVersion -> Text)
-> (DescribePackageVersion -> Text -> DescribePackageVersion)
-> Lens DescribePackageVersion DescribePackageVersion Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersion' {Text
packageId :: Text
$sel:packageId:DescribePackageVersion' :: DescribePackageVersion -> Text
packageId} -> Text
packageId) (\s :: DescribePackageVersion
s@DescribePackageVersion' {} Text
a -> DescribePackageVersion
s {$sel:packageId:DescribePackageVersion' :: Text
packageId = Text
a} :: DescribePackageVersion)
describePackageVersion_packageVersion :: Lens.Lens' DescribePackageVersion Prelude.Text
describePackageVersion_packageVersion :: (Text -> f Text)
-> DescribePackageVersion -> f DescribePackageVersion
describePackageVersion_packageVersion = (DescribePackageVersion -> Text)
-> (DescribePackageVersion -> Text -> DescribePackageVersion)
-> Lens DescribePackageVersion DescribePackageVersion Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersion' {Text
packageVersion :: Text
$sel:packageVersion:DescribePackageVersion' :: DescribePackageVersion -> Text
packageVersion} -> Text
packageVersion) (\s :: DescribePackageVersion
s@DescribePackageVersion' {} Text
a -> DescribePackageVersion
s {$sel:packageVersion:DescribePackageVersion' :: Text
packageVersion = Text
a} :: DescribePackageVersion)
instance Core.AWSRequest DescribePackageVersion where
type
AWSResponse DescribePackageVersion =
DescribePackageVersionResponse
request :: DescribePackageVersion -> Request DescribePackageVersion
request = Service -> DescribePackageVersion -> Request DescribePackageVersion
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
response :: Logger
-> Service
-> Proxy DescribePackageVersion
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribePackageVersion)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse DescribePackageVersion))
-> Logger
-> Service
-> Proxy DescribePackageVersion
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribePackageVersion)))
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 POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse
DescribePackageVersionResponse'
(Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
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
"StatusDescription")
Either
String
(Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
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
"PackageArn")
Either
String
(Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String (Maybe POSIX)
-> Either
String
(Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"RegisteredTime")
Either
String
(Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String (Maybe Text)
-> Either
String
(Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
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
"OwnerAccount")
Either
String
(Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String Int
-> Either
String
(Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
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))
Either
String
(Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String Text
-> Either
String
(Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"PackageId")
Either
String
(Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String Text
-> Either
String
(Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"PackageName")
Either
String
(Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse)
-> Either String Text
-> Either
String
(Text
-> Bool -> PackageVersionStatus -> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"PackageVersion")
Either
String
(Text
-> Bool -> PackageVersionStatus -> DescribePackageVersionResponse)
-> Either String Text
-> Either
String
(Bool -> PackageVersionStatus -> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"PatchVersion")
Either
String
(Bool -> PackageVersionStatus -> DescribePackageVersionResponse)
-> Either String Bool
-> Either
String (PackageVersionStatus -> DescribePackageVersionResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Bool
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"IsLatestPatch")
Either
String (PackageVersionStatus -> DescribePackageVersionResponse)
-> Either String PackageVersionStatus
-> Either String DescribePackageVersionResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String PackageVersionStatus
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"Status")
)
instance Prelude.Hashable DescribePackageVersion
instance Prelude.NFData DescribePackageVersion
instance Core.ToHeaders DescribePackageVersion where
toHeaders :: DescribePackageVersion -> ResponseHeaders
toHeaders =
ResponseHeaders -> DescribePackageVersion -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ 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.ToPath DescribePackageVersion where
toPath :: DescribePackageVersion -> ByteString
toPath DescribePackageVersion' {Maybe Text
Text
packageVersion :: Text
packageId :: Text
ownerAccount :: Maybe Text
patchVersion :: Maybe Text
$sel:packageVersion:DescribePackageVersion' :: DescribePackageVersion -> Text
$sel:packageId:DescribePackageVersion' :: DescribePackageVersion -> Text
$sel:ownerAccount:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
$sel:patchVersion:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/packages/metadata/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
packageId,
ByteString
"/versions/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
packageVersion
]
instance Core.ToQuery DescribePackageVersion where
toQuery :: DescribePackageVersion -> QueryString
toQuery DescribePackageVersion' {Maybe Text
Text
packageVersion :: Text
packageId :: Text
ownerAccount :: Maybe Text
patchVersion :: Maybe Text
$sel:packageVersion:DescribePackageVersion' :: DescribePackageVersion -> Text
$sel:packageId:DescribePackageVersion' :: DescribePackageVersion -> Text
$sel:ownerAccount:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
$sel:patchVersion:DescribePackageVersion' :: DescribePackageVersion -> Maybe Text
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"PatchVersion" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
patchVersion,
ByteString
"OwnerAccount" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
ownerAccount
]
data DescribePackageVersionResponse = DescribePackageVersionResponse'
{
DescribePackageVersionResponse -> Maybe Text
statusDescription :: Prelude.Maybe Prelude.Text,
DescribePackageVersionResponse -> Maybe Text
packageArn :: Prelude.Maybe Prelude.Text,
DescribePackageVersionResponse -> Maybe POSIX
registeredTime :: Prelude.Maybe Core.POSIX,
DescribePackageVersionResponse -> Maybe Text
ownerAccount :: Prelude.Maybe Prelude.Text,
DescribePackageVersionResponse -> Int
httpStatus :: Prelude.Int,
DescribePackageVersionResponse -> Text
packageId :: Prelude.Text,
DescribePackageVersionResponse -> Text
packageName :: Prelude.Text,
DescribePackageVersionResponse -> Text
packageVersion :: Prelude.Text,
DescribePackageVersionResponse -> Text
patchVersion :: Prelude.Text,
DescribePackageVersionResponse -> Bool
isLatestPatch :: Prelude.Bool,
DescribePackageVersionResponse -> PackageVersionStatus
status :: PackageVersionStatus
}
deriving (DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool
(DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool)
-> (DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool)
-> Eq DescribePackageVersionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool
$c/= :: DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool
== :: DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool
$c== :: DescribePackageVersionResponse
-> DescribePackageVersionResponse -> Bool
Prelude.Eq, ReadPrec [DescribePackageVersionResponse]
ReadPrec DescribePackageVersionResponse
Int -> ReadS DescribePackageVersionResponse
ReadS [DescribePackageVersionResponse]
(Int -> ReadS DescribePackageVersionResponse)
-> ReadS [DescribePackageVersionResponse]
-> ReadPrec DescribePackageVersionResponse
-> ReadPrec [DescribePackageVersionResponse]
-> Read DescribePackageVersionResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribePackageVersionResponse]
$creadListPrec :: ReadPrec [DescribePackageVersionResponse]
readPrec :: ReadPrec DescribePackageVersionResponse
$creadPrec :: ReadPrec DescribePackageVersionResponse
readList :: ReadS [DescribePackageVersionResponse]
$creadList :: ReadS [DescribePackageVersionResponse]
readsPrec :: Int -> ReadS DescribePackageVersionResponse
$creadsPrec :: Int -> ReadS DescribePackageVersionResponse
Prelude.Read, Int -> DescribePackageVersionResponse -> ShowS
[DescribePackageVersionResponse] -> ShowS
DescribePackageVersionResponse -> String
(Int -> DescribePackageVersionResponse -> ShowS)
-> (DescribePackageVersionResponse -> String)
-> ([DescribePackageVersionResponse] -> ShowS)
-> Show DescribePackageVersionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribePackageVersionResponse] -> ShowS
$cshowList :: [DescribePackageVersionResponse] -> ShowS
show :: DescribePackageVersionResponse -> String
$cshow :: DescribePackageVersionResponse -> String
showsPrec :: Int -> DescribePackageVersionResponse -> ShowS
$cshowsPrec :: Int -> DescribePackageVersionResponse -> ShowS
Prelude.Show, (forall x.
DescribePackageVersionResponse
-> Rep DescribePackageVersionResponse x)
-> (forall x.
Rep DescribePackageVersionResponse x
-> DescribePackageVersionResponse)
-> Generic DescribePackageVersionResponse
forall x.
Rep DescribePackageVersionResponse x
-> DescribePackageVersionResponse
forall x.
DescribePackageVersionResponse
-> Rep DescribePackageVersionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribePackageVersionResponse x
-> DescribePackageVersionResponse
$cfrom :: forall x.
DescribePackageVersionResponse
-> Rep DescribePackageVersionResponse x
Prelude.Generic)
newDescribePackageVersionResponse ::
Prelude.Int ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.Text ->
Prelude.Bool ->
PackageVersionStatus ->
DescribePackageVersionResponse
newDescribePackageVersionResponse :: Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse
newDescribePackageVersionResponse
Int
pHttpStatus_
Text
pPackageId_
Text
pPackageName_
Text
pPackageVersion_
Text
pPatchVersion_
Bool
pIsLatestPatch_
PackageVersionStatus
pStatus_ =
DescribePackageVersionResponse' :: Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Int
-> Text
-> Text
-> Text
-> Text
-> Bool
-> PackageVersionStatus
-> DescribePackageVersionResponse
DescribePackageVersionResponse'
{ $sel:statusDescription:DescribePackageVersionResponse' :: Maybe Text
statusDescription =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:packageArn:DescribePackageVersionResponse' :: Maybe Text
packageArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:registeredTime:DescribePackageVersionResponse' :: Maybe POSIX
registeredTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:ownerAccount:DescribePackageVersionResponse' :: Maybe Text
ownerAccount = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DescribePackageVersionResponse' :: Int
httpStatus = Int
pHttpStatus_,
$sel:packageId:DescribePackageVersionResponse' :: Text
packageId = Text
pPackageId_,
$sel:packageName:DescribePackageVersionResponse' :: Text
packageName = Text
pPackageName_,
$sel:packageVersion:DescribePackageVersionResponse' :: Text
packageVersion = Text
pPackageVersion_,
$sel:patchVersion:DescribePackageVersionResponse' :: Text
patchVersion = Text
pPatchVersion_,
$sel:isLatestPatch:DescribePackageVersionResponse' :: Bool
isLatestPatch = Bool
pIsLatestPatch_,
$sel:status:DescribePackageVersionResponse' :: PackageVersionStatus
status = PackageVersionStatus
pStatus_
}
describePackageVersionResponse_statusDescription :: Lens.Lens' DescribePackageVersionResponse (Prelude.Maybe Prelude.Text)
describePackageVersionResponse_statusDescription :: (Maybe Text -> f (Maybe Text))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_statusDescription = (DescribePackageVersionResponse -> Maybe Text)
-> (DescribePackageVersionResponse
-> Maybe Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Maybe Text
statusDescription :: Maybe Text
$sel:statusDescription:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Maybe Text
statusDescription} -> Maybe Text
statusDescription) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Maybe Text
a -> DescribePackageVersionResponse
s {$sel:statusDescription:DescribePackageVersionResponse' :: Maybe Text
statusDescription = Maybe Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_packageArn :: Lens.Lens' DescribePackageVersionResponse (Prelude.Maybe Prelude.Text)
describePackageVersionResponse_packageArn :: (Maybe Text -> f (Maybe Text))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_packageArn = (DescribePackageVersionResponse -> Maybe Text)
-> (DescribePackageVersionResponse
-> Maybe Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Maybe Text
packageArn :: Maybe Text
$sel:packageArn:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Maybe Text
packageArn} -> Maybe Text
packageArn) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Maybe Text
a -> DescribePackageVersionResponse
s {$sel:packageArn:DescribePackageVersionResponse' :: Maybe Text
packageArn = Maybe Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_registeredTime :: Lens.Lens' DescribePackageVersionResponse (Prelude.Maybe Prelude.UTCTime)
describePackageVersionResponse_registeredTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_registeredTime = (DescribePackageVersionResponse -> Maybe POSIX)
-> (DescribePackageVersionResponse
-> Maybe POSIX -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
(Maybe POSIX)
(Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Maybe POSIX
registeredTime :: Maybe POSIX
$sel:registeredTime:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Maybe POSIX
registeredTime} -> Maybe POSIX
registeredTime) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Maybe POSIX
a -> DescribePackageVersionResponse
s {$sel:registeredTime:DescribePackageVersionResponse' :: Maybe POSIX
registeredTime = Maybe POSIX
a} :: DescribePackageVersionResponse) ((Maybe POSIX -> f (Maybe POSIX))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
describePackageVersionResponse_ownerAccount :: Lens.Lens' DescribePackageVersionResponse (Prelude.Maybe Prelude.Text)
describePackageVersionResponse_ownerAccount :: (Maybe Text -> f (Maybe Text))
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_ownerAccount = (DescribePackageVersionResponse -> Maybe Text)
-> (DescribePackageVersionResponse
-> Maybe Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Maybe Text
ownerAccount :: Maybe Text
$sel:ownerAccount:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Maybe Text
ownerAccount} -> Maybe Text
ownerAccount) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Maybe Text
a -> DescribePackageVersionResponse
s {$sel:ownerAccount:DescribePackageVersionResponse' :: Maybe Text
ownerAccount = Maybe Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_httpStatus :: Lens.Lens' DescribePackageVersionResponse Prelude.Int
describePackageVersionResponse_httpStatus :: (Int -> f Int)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_httpStatus = (DescribePackageVersionResponse -> Int)
-> (DescribePackageVersionResponse
-> Int -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Int
a -> DescribePackageVersionResponse
s {$sel:httpStatus:DescribePackageVersionResponse' :: Int
httpStatus = Int
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_packageId :: Lens.Lens' DescribePackageVersionResponse Prelude.Text
describePackageVersionResponse_packageId :: (Text -> f Text)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_packageId = (DescribePackageVersionResponse -> Text)
-> (DescribePackageVersionResponse
-> Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Text
packageId :: Text
$sel:packageId:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Text
packageId} -> Text
packageId) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Text
a -> DescribePackageVersionResponse
s {$sel:packageId:DescribePackageVersionResponse' :: Text
packageId = Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_packageName :: Lens.Lens' DescribePackageVersionResponse Prelude.Text
describePackageVersionResponse_packageName :: (Text -> f Text)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_packageName = (DescribePackageVersionResponse -> Text)
-> (DescribePackageVersionResponse
-> Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Text
packageName :: Text
$sel:packageName:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Text
packageName} -> Text
packageName) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Text
a -> DescribePackageVersionResponse
s {$sel:packageName:DescribePackageVersionResponse' :: Text
packageName = Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_packageVersion :: Lens.Lens' DescribePackageVersionResponse Prelude.Text
describePackageVersionResponse_packageVersion :: (Text -> f Text)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_packageVersion = (DescribePackageVersionResponse -> Text)
-> (DescribePackageVersionResponse
-> Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Text
packageVersion :: Text
$sel:packageVersion:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Text
packageVersion} -> Text
packageVersion) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Text
a -> DescribePackageVersionResponse
s {$sel:packageVersion:DescribePackageVersionResponse' :: Text
packageVersion = Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_patchVersion :: Lens.Lens' DescribePackageVersionResponse Prelude.Text
describePackageVersionResponse_patchVersion :: (Text -> f Text)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_patchVersion = (DescribePackageVersionResponse -> Text)
-> (DescribePackageVersionResponse
-> Text -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Text
patchVersion :: Text
$sel:patchVersion:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Text
patchVersion} -> Text
patchVersion) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Text
a -> DescribePackageVersionResponse
s {$sel:patchVersion:DescribePackageVersionResponse' :: Text
patchVersion = Text
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_isLatestPatch :: Lens.Lens' DescribePackageVersionResponse Prelude.Bool
describePackageVersionResponse_isLatestPatch :: (Bool -> f Bool)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_isLatestPatch = (DescribePackageVersionResponse -> Bool)
-> (DescribePackageVersionResponse
-> Bool -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
Bool
Bool
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {Bool
isLatestPatch :: Bool
$sel:isLatestPatch:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> Bool
isLatestPatch} -> Bool
isLatestPatch) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} Bool
a -> DescribePackageVersionResponse
s {$sel:isLatestPatch:DescribePackageVersionResponse' :: Bool
isLatestPatch = Bool
a} :: DescribePackageVersionResponse)
describePackageVersionResponse_status :: Lens.Lens' DescribePackageVersionResponse PackageVersionStatus
describePackageVersionResponse_status :: (PackageVersionStatus -> f PackageVersionStatus)
-> DescribePackageVersionResponse
-> f DescribePackageVersionResponse
describePackageVersionResponse_status = (DescribePackageVersionResponse -> PackageVersionStatus)
-> (DescribePackageVersionResponse
-> PackageVersionStatus -> DescribePackageVersionResponse)
-> Lens
DescribePackageVersionResponse
DescribePackageVersionResponse
PackageVersionStatus
PackageVersionStatus
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribePackageVersionResponse' {PackageVersionStatus
status :: PackageVersionStatus
$sel:status:DescribePackageVersionResponse' :: DescribePackageVersionResponse -> PackageVersionStatus
status} -> PackageVersionStatus
status) (\s :: DescribePackageVersionResponse
s@DescribePackageVersionResponse' {} PackageVersionStatus
a -> DescribePackageVersionResponse
s {$sel:status:DescribePackageVersionResponse' :: PackageVersionStatus
status = PackageVersionStatus
a} :: DescribePackageVersionResponse)
instance
Prelude.NFData
DescribePackageVersionResponse