{-# 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.SageMaker.GetSagemakerServicecatalogPortfolioStatus
(
GetSagemakerServicecatalogPortfolioStatus (..),
newGetSagemakerServicecatalogPortfolioStatus,
GetSagemakerServicecatalogPortfolioStatusResponse (..),
newGetSagemakerServicecatalogPortfolioStatusResponse,
getSagemakerServicecatalogPortfolioStatusResponse_status,
getSagemakerServicecatalogPortfolioStatusResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.SageMaker.Types
data GetSagemakerServicecatalogPortfolioStatus = GetSagemakerServicecatalogPortfolioStatus'
{
}
deriving (GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool
(GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool)
-> (GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool)
-> Eq GetSagemakerServicecatalogPortfolioStatus
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool
$c/= :: GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool
== :: GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool
$c== :: GetSagemakerServicecatalogPortfolioStatus
-> GetSagemakerServicecatalogPortfolioStatus -> Bool
Prelude.Eq, ReadPrec [GetSagemakerServicecatalogPortfolioStatus]
ReadPrec GetSagemakerServicecatalogPortfolioStatus
Int -> ReadS GetSagemakerServicecatalogPortfolioStatus
ReadS [GetSagemakerServicecatalogPortfolioStatus]
(Int -> ReadS GetSagemakerServicecatalogPortfolioStatus)
-> ReadS [GetSagemakerServicecatalogPortfolioStatus]
-> ReadPrec GetSagemakerServicecatalogPortfolioStatus
-> ReadPrec [GetSagemakerServicecatalogPortfolioStatus]
-> Read GetSagemakerServicecatalogPortfolioStatus
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetSagemakerServicecatalogPortfolioStatus]
$creadListPrec :: ReadPrec [GetSagemakerServicecatalogPortfolioStatus]
readPrec :: ReadPrec GetSagemakerServicecatalogPortfolioStatus
$creadPrec :: ReadPrec GetSagemakerServicecatalogPortfolioStatus
readList :: ReadS [GetSagemakerServicecatalogPortfolioStatus]
$creadList :: ReadS [GetSagemakerServicecatalogPortfolioStatus]
readsPrec :: Int -> ReadS GetSagemakerServicecatalogPortfolioStatus
$creadsPrec :: Int -> ReadS GetSagemakerServicecatalogPortfolioStatus
Prelude.Read, Int -> GetSagemakerServicecatalogPortfolioStatus -> ShowS
[GetSagemakerServicecatalogPortfolioStatus] -> ShowS
GetSagemakerServicecatalogPortfolioStatus -> String
(Int -> GetSagemakerServicecatalogPortfolioStatus -> ShowS)
-> (GetSagemakerServicecatalogPortfolioStatus -> String)
-> ([GetSagemakerServicecatalogPortfolioStatus] -> ShowS)
-> Show GetSagemakerServicecatalogPortfolioStatus
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetSagemakerServicecatalogPortfolioStatus] -> ShowS
$cshowList :: [GetSagemakerServicecatalogPortfolioStatus] -> ShowS
show :: GetSagemakerServicecatalogPortfolioStatus -> String
$cshow :: GetSagemakerServicecatalogPortfolioStatus -> String
showsPrec :: Int -> GetSagemakerServicecatalogPortfolioStatus -> ShowS
$cshowsPrec :: Int -> GetSagemakerServicecatalogPortfolioStatus -> ShowS
Prelude.Show, (forall x.
GetSagemakerServicecatalogPortfolioStatus
-> Rep GetSagemakerServicecatalogPortfolioStatus x)
-> (forall x.
Rep GetSagemakerServicecatalogPortfolioStatus x
-> GetSagemakerServicecatalogPortfolioStatus)
-> Generic GetSagemakerServicecatalogPortfolioStatus
forall x.
Rep GetSagemakerServicecatalogPortfolioStatus x
-> GetSagemakerServicecatalogPortfolioStatus
forall x.
GetSagemakerServicecatalogPortfolioStatus
-> Rep GetSagemakerServicecatalogPortfolioStatus x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep GetSagemakerServicecatalogPortfolioStatus x
-> GetSagemakerServicecatalogPortfolioStatus
$cfrom :: forall x.
GetSagemakerServicecatalogPortfolioStatus
-> Rep GetSagemakerServicecatalogPortfolioStatus x
Prelude.Generic)
newGetSagemakerServicecatalogPortfolioStatus ::
GetSagemakerServicecatalogPortfolioStatus
newGetSagemakerServicecatalogPortfolioStatus :: GetSagemakerServicecatalogPortfolioStatus
newGetSagemakerServicecatalogPortfolioStatus =
GetSagemakerServicecatalogPortfolioStatus
GetSagemakerServicecatalogPortfolioStatus'
instance
Core.AWSRequest
GetSagemakerServicecatalogPortfolioStatus
where
type
AWSResponse
GetSagemakerServicecatalogPortfolioStatus =
GetSagemakerServicecatalogPortfolioStatusResponse
request :: GetSagemakerServicecatalogPortfolioStatus
-> Request GetSagemakerServicecatalogPortfolioStatus
request = Service
-> GetSagemakerServicecatalogPortfolioStatus
-> Request GetSagemakerServicecatalogPortfolioStatus
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy GetSagemakerServicecatalogPortfolioStatus
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse
(AWSResponse GetSagemakerServicecatalogPortfolioStatus)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either
String (AWSResponse GetSagemakerServicecatalogPortfolioStatus))
-> Logger
-> Service
-> Proxy GetSagemakerServicecatalogPortfolioStatus
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse
(AWSResponse GetSagemakerServicecatalogPortfolioStatus)))
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 SagemakerServicecatalogStatus
-> Int -> GetSagemakerServicecatalogPortfolioStatusResponse
GetSagemakerServicecatalogPortfolioStatusResponse'
(Maybe SagemakerServicecatalogStatus
-> Int -> GetSagemakerServicecatalogPortfolioStatusResponse)
-> Either String (Maybe SagemakerServicecatalogStatus)
-> Either
String (Int -> GetSagemakerServicecatalogPortfolioStatusResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object
-> Key -> Either String (Maybe SagemakerServicecatalogStatus)
forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Core..?> Key
"Status")
Either
String (Int -> GetSagemakerServicecatalogPortfolioStatusResponse)
-> Either String Int
-> Either String GetSagemakerServicecatalogPortfolioStatusResponse
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
GetSagemakerServicecatalogPortfolioStatus
instance
Prelude.NFData
GetSagemakerServicecatalogPortfolioStatus
instance
Core.ToHeaders
GetSagemakerServicecatalogPortfolioStatus
where
toHeaders :: GetSagemakerServicecatalogPortfolioStatus -> ResponseHeaders
toHeaders =
ResponseHeaders
-> GetSagemakerServicecatalogPortfolioStatus -> 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
"SageMaker.GetSagemakerServicecatalogPortfolioStatus" ::
Prelude.ByteString
),
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
GetSagemakerServicecatalogPortfolioStatus
where
toJSON :: GetSagemakerServicecatalogPortfolioStatus -> Value
toJSON = Value -> GetSagemakerServicecatalogPortfolioStatus -> Value
forall a b. a -> b -> a
Prelude.const (Object -> Value
Core.Object Object
forall a. Monoid a => a
Prelude.mempty)
instance
Core.ToPath
GetSagemakerServicecatalogPortfolioStatus
where
toPath :: GetSagemakerServicecatalogPortfolioStatus -> ByteString
toPath = ByteString
-> GetSagemakerServicecatalogPortfolioStatus -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance
Core.ToQuery
GetSagemakerServicecatalogPortfolioStatus
where
toQuery :: GetSagemakerServicecatalogPortfolioStatus -> QueryString
toQuery = QueryString
-> GetSagemakerServicecatalogPortfolioStatus -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data GetSagemakerServicecatalogPortfolioStatusResponse = GetSagemakerServicecatalogPortfolioStatusResponse'
{
GetSagemakerServicecatalogPortfolioStatusResponse
-> Maybe SagemakerServicecatalogStatus
status :: Prelude.Maybe SagemakerServicecatalogStatus,
GetSagemakerServicecatalogPortfolioStatusResponse -> Int
httpStatus :: Prelude.Int
}
deriving (GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool
(GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool)
-> (GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool)
-> Eq GetSagemakerServicecatalogPortfolioStatusResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool
$c/= :: GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool
== :: GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool
$c== :: GetSagemakerServicecatalogPortfolioStatusResponse
-> GetSagemakerServicecatalogPortfolioStatusResponse -> Bool
Prelude.Eq, ReadPrec [GetSagemakerServicecatalogPortfolioStatusResponse]
ReadPrec GetSagemakerServicecatalogPortfolioStatusResponse
Int -> ReadS GetSagemakerServicecatalogPortfolioStatusResponse
ReadS [GetSagemakerServicecatalogPortfolioStatusResponse]
(Int -> ReadS GetSagemakerServicecatalogPortfolioStatusResponse)
-> ReadS [GetSagemakerServicecatalogPortfolioStatusResponse]
-> ReadPrec GetSagemakerServicecatalogPortfolioStatusResponse
-> ReadPrec [GetSagemakerServicecatalogPortfolioStatusResponse]
-> Read GetSagemakerServicecatalogPortfolioStatusResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetSagemakerServicecatalogPortfolioStatusResponse]
$creadListPrec :: ReadPrec [GetSagemakerServicecatalogPortfolioStatusResponse]
readPrec :: ReadPrec GetSagemakerServicecatalogPortfolioStatusResponse
$creadPrec :: ReadPrec GetSagemakerServicecatalogPortfolioStatusResponse
readList :: ReadS [GetSagemakerServicecatalogPortfolioStatusResponse]
$creadList :: ReadS [GetSagemakerServicecatalogPortfolioStatusResponse]
readsPrec :: Int -> ReadS GetSagemakerServicecatalogPortfolioStatusResponse
$creadsPrec :: Int -> ReadS GetSagemakerServicecatalogPortfolioStatusResponse
Prelude.Read, Int -> GetSagemakerServicecatalogPortfolioStatusResponse -> ShowS
[GetSagemakerServicecatalogPortfolioStatusResponse] -> ShowS
GetSagemakerServicecatalogPortfolioStatusResponse -> String
(Int -> GetSagemakerServicecatalogPortfolioStatusResponse -> ShowS)
-> (GetSagemakerServicecatalogPortfolioStatusResponse -> String)
-> ([GetSagemakerServicecatalogPortfolioStatusResponse] -> ShowS)
-> Show GetSagemakerServicecatalogPortfolioStatusResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetSagemakerServicecatalogPortfolioStatusResponse] -> ShowS
$cshowList :: [GetSagemakerServicecatalogPortfolioStatusResponse] -> ShowS
show :: GetSagemakerServicecatalogPortfolioStatusResponse -> String
$cshow :: GetSagemakerServicecatalogPortfolioStatusResponse -> String
showsPrec :: Int -> GetSagemakerServicecatalogPortfolioStatusResponse -> ShowS
$cshowsPrec :: Int -> GetSagemakerServicecatalogPortfolioStatusResponse -> ShowS
Prelude.Show, (forall x.
GetSagemakerServicecatalogPortfolioStatusResponse
-> Rep GetSagemakerServicecatalogPortfolioStatusResponse x)
-> (forall x.
Rep GetSagemakerServicecatalogPortfolioStatusResponse x
-> GetSagemakerServicecatalogPortfolioStatusResponse)
-> Generic GetSagemakerServicecatalogPortfolioStatusResponse
forall x.
Rep GetSagemakerServicecatalogPortfolioStatusResponse x
-> GetSagemakerServicecatalogPortfolioStatusResponse
forall x.
GetSagemakerServicecatalogPortfolioStatusResponse
-> Rep GetSagemakerServicecatalogPortfolioStatusResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep GetSagemakerServicecatalogPortfolioStatusResponse x
-> GetSagemakerServicecatalogPortfolioStatusResponse
$cfrom :: forall x.
GetSagemakerServicecatalogPortfolioStatusResponse
-> Rep GetSagemakerServicecatalogPortfolioStatusResponse x
Prelude.Generic)
newGetSagemakerServicecatalogPortfolioStatusResponse ::
Prelude.Int ->
GetSagemakerServicecatalogPortfolioStatusResponse
newGetSagemakerServicecatalogPortfolioStatusResponse :: Int -> GetSagemakerServicecatalogPortfolioStatusResponse
newGetSagemakerServicecatalogPortfolioStatusResponse
Int
pHttpStatus_ =
GetSagemakerServicecatalogPortfolioStatusResponse' :: Maybe SagemakerServicecatalogStatus
-> Int -> GetSagemakerServicecatalogPortfolioStatusResponse
GetSagemakerServicecatalogPortfolioStatusResponse'
{ $sel:status:GetSagemakerServicecatalogPortfolioStatusResponse' :: Maybe SagemakerServicecatalogStatus
status =
Maybe SagemakerServicecatalogStatus
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:GetSagemakerServicecatalogPortfolioStatusResponse' :: Int
httpStatus =
Int
pHttpStatus_
}
getSagemakerServicecatalogPortfolioStatusResponse_status :: Lens.Lens' GetSagemakerServicecatalogPortfolioStatusResponse (Prelude.Maybe SagemakerServicecatalogStatus)
getSagemakerServicecatalogPortfolioStatusResponse_status :: (Maybe SagemakerServicecatalogStatus
-> f (Maybe SagemakerServicecatalogStatus))
-> GetSagemakerServicecatalogPortfolioStatusResponse
-> f GetSagemakerServicecatalogPortfolioStatusResponse
getSagemakerServicecatalogPortfolioStatusResponse_status = (GetSagemakerServicecatalogPortfolioStatusResponse
-> Maybe SagemakerServicecatalogStatus)
-> (GetSagemakerServicecatalogPortfolioStatusResponse
-> Maybe SagemakerServicecatalogStatus
-> GetSagemakerServicecatalogPortfolioStatusResponse)
-> Lens
GetSagemakerServicecatalogPortfolioStatusResponse
GetSagemakerServicecatalogPortfolioStatusResponse
(Maybe SagemakerServicecatalogStatus)
(Maybe SagemakerServicecatalogStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSagemakerServicecatalogPortfolioStatusResponse' {Maybe SagemakerServicecatalogStatus
status :: Maybe SagemakerServicecatalogStatus
$sel:status:GetSagemakerServicecatalogPortfolioStatusResponse' :: GetSagemakerServicecatalogPortfolioStatusResponse
-> Maybe SagemakerServicecatalogStatus
status} -> Maybe SagemakerServicecatalogStatus
status) (\s :: GetSagemakerServicecatalogPortfolioStatusResponse
s@GetSagemakerServicecatalogPortfolioStatusResponse' {} Maybe SagemakerServicecatalogStatus
a -> GetSagemakerServicecatalogPortfolioStatusResponse
s {$sel:status:GetSagemakerServicecatalogPortfolioStatusResponse' :: Maybe SagemakerServicecatalogStatus
status = Maybe SagemakerServicecatalogStatus
a} :: GetSagemakerServicecatalogPortfolioStatusResponse)
getSagemakerServicecatalogPortfolioStatusResponse_httpStatus :: Lens.Lens' GetSagemakerServicecatalogPortfolioStatusResponse Prelude.Int
getSagemakerServicecatalogPortfolioStatusResponse_httpStatus :: (Int -> f Int)
-> GetSagemakerServicecatalogPortfolioStatusResponse
-> f GetSagemakerServicecatalogPortfolioStatusResponse
getSagemakerServicecatalogPortfolioStatusResponse_httpStatus = (GetSagemakerServicecatalogPortfolioStatusResponse -> Int)
-> (GetSagemakerServicecatalogPortfolioStatusResponse
-> Int -> GetSagemakerServicecatalogPortfolioStatusResponse)
-> Lens
GetSagemakerServicecatalogPortfolioStatusResponse
GetSagemakerServicecatalogPortfolioStatusResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetSagemakerServicecatalogPortfolioStatusResponse' {Int
httpStatus :: Int
$sel:httpStatus:GetSagemakerServicecatalogPortfolioStatusResponse' :: GetSagemakerServicecatalogPortfolioStatusResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: GetSagemakerServicecatalogPortfolioStatusResponse
s@GetSagemakerServicecatalogPortfolioStatusResponse' {} Int
a -> GetSagemakerServicecatalogPortfolioStatusResponse
s {$sel:httpStatus:GetSagemakerServicecatalogPortfolioStatusResponse' :: Int
httpStatus = Int
a} :: GetSagemakerServicecatalogPortfolioStatusResponse)
instance
Prelude.NFData
GetSagemakerServicecatalogPortfolioStatusResponse