{-# 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.ListProcessingJobs
(
ListProcessingJobs (..),
newListProcessingJobs,
listProcessingJobs_nameContains,
listProcessingJobs_lastModifiedTimeBefore,
listProcessingJobs_creationTimeAfter,
listProcessingJobs_nextToken,
listProcessingJobs_sortOrder,
listProcessingJobs_lastModifiedTimeAfter,
listProcessingJobs_creationTimeBefore,
listProcessingJobs_statusEquals,
listProcessingJobs_maxResults,
listProcessingJobs_sortBy,
ListProcessingJobsResponse (..),
newListProcessingJobsResponse,
listProcessingJobsResponse_nextToken,
listProcessingJobsResponse_httpStatus,
listProcessingJobsResponse_processingJobSummaries,
)
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 ListProcessingJobs = ListProcessingJobs'
{
ListProcessingJobs -> Maybe Text
nameContains :: Prelude.Maybe Prelude.Text,
ListProcessingJobs -> Maybe POSIX
lastModifiedTimeBefore :: Prelude.Maybe Core.POSIX,
ListProcessingJobs -> Maybe POSIX
creationTimeAfter :: Prelude.Maybe Core.POSIX,
ListProcessingJobs -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListProcessingJobs -> Maybe SortOrder
sortOrder :: Prelude.Maybe SortOrder,
ListProcessingJobs -> Maybe POSIX
lastModifiedTimeAfter :: Prelude.Maybe Core.POSIX,
ListProcessingJobs -> Maybe POSIX
creationTimeBefore :: Prelude.Maybe Core.POSIX,
ListProcessingJobs -> Maybe ProcessingJobStatus
statusEquals :: Prelude.Maybe ProcessingJobStatus,
ListProcessingJobs -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
ListProcessingJobs -> Maybe SortBy
sortBy :: Prelude.Maybe SortBy
}
deriving (ListProcessingJobs -> ListProcessingJobs -> Bool
(ListProcessingJobs -> ListProcessingJobs -> Bool)
-> (ListProcessingJobs -> ListProcessingJobs -> Bool)
-> Eq ListProcessingJobs
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListProcessingJobs -> ListProcessingJobs -> Bool
$c/= :: ListProcessingJobs -> ListProcessingJobs -> Bool
== :: ListProcessingJobs -> ListProcessingJobs -> Bool
$c== :: ListProcessingJobs -> ListProcessingJobs -> Bool
Prelude.Eq, ReadPrec [ListProcessingJobs]
ReadPrec ListProcessingJobs
Int -> ReadS ListProcessingJobs
ReadS [ListProcessingJobs]
(Int -> ReadS ListProcessingJobs)
-> ReadS [ListProcessingJobs]
-> ReadPrec ListProcessingJobs
-> ReadPrec [ListProcessingJobs]
-> Read ListProcessingJobs
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListProcessingJobs]
$creadListPrec :: ReadPrec [ListProcessingJobs]
readPrec :: ReadPrec ListProcessingJobs
$creadPrec :: ReadPrec ListProcessingJobs
readList :: ReadS [ListProcessingJobs]
$creadList :: ReadS [ListProcessingJobs]
readsPrec :: Int -> ReadS ListProcessingJobs
$creadsPrec :: Int -> ReadS ListProcessingJobs
Prelude.Read, Int -> ListProcessingJobs -> ShowS
[ListProcessingJobs] -> ShowS
ListProcessingJobs -> String
(Int -> ListProcessingJobs -> ShowS)
-> (ListProcessingJobs -> String)
-> ([ListProcessingJobs] -> ShowS)
-> Show ListProcessingJobs
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListProcessingJobs] -> ShowS
$cshowList :: [ListProcessingJobs] -> ShowS
show :: ListProcessingJobs -> String
$cshow :: ListProcessingJobs -> String
showsPrec :: Int -> ListProcessingJobs -> ShowS
$cshowsPrec :: Int -> ListProcessingJobs -> ShowS
Prelude.Show, (forall x. ListProcessingJobs -> Rep ListProcessingJobs x)
-> (forall x. Rep ListProcessingJobs x -> ListProcessingJobs)
-> Generic ListProcessingJobs
forall x. Rep ListProcessingJobs x -> ListProcessingJobs
forall x. ListProcessingJobs -> Rep ListProcessingJobs x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListProcessingJobs x -> ListProcessingJobs
$cfrom :: forall x. ListProcessingJobs -> Rep ListProcessingJobs x
Prelude.Generic)
newListProcessingJobs ::
ListProcessingJobs
newListProcessingJobs :: ListProcessingJobs
newListProcessingJobs =
ListProcessingJobs' :: Maybe Text
-> Maybe POSIX
-> Maybe POSIX
-> Maybe Text
-> Maybe SortOrder
-> Maybe POSIX
-> Maybe POSIX
-> Maybe ProcessingJobStatus
-> Maybe Natural
-> Maybe SortBy
-> ListProcessingJobs
ListProcessingJobs'
{ $sel:nameContains:ListProcessingJobs' :: Maybe Text
nameContains = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedTimeBefore:ListProcessingJobs' :: Maybe POSIX
lastModifiedTimeBefore = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:creationTimeAfter:ListProcessingJobs' :: Maybe POSIX
creationTimeAfter = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:ListProcessingJobs' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sortOrder:ListProcessingJobs' :: Maybe SortOrder
sortOrder = Maybe SortOrder
forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedTimeAfter:ListProcessingJobs' :: Maybe POSIX
lastModifiedTimeAfter = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:creationTimeBefore:ListProcessingJobs' :: Maybe POSIX
creationTimeBefore = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:statusEquals:ListProcessingJobs' :: Maybe ProcessingJobStatus
statusEquals = Maybe ProcessingJobStatus
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListProcessingJobs' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
$sel:sortBy:ListProcessingJobs' :: Maybe SortBy
sortBy = Maybe SortBy
forall a. Maybe a
Prelude.Nothing
}
listProcessingJobs_nameContains :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.Text)
listProcessingJobs_nameContains :: (Maybe Text -> f (Maybe Text))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_nameContains = (ListProcessingJobs -> Maybe Text)
-> (ListProcessingJobs -> Maybe Text -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe Text
nameContains :: Maybe Text
$sel:nameContains:ListProcessingJobs' :: ListProcessingJobs -> Maybe Text
nameContains} -> Maybe Text
nameContains) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe Text
a -> ListProcessingJobs
s {$sel:nameContains:ListProcessingJobs' :: Maybe Text
nameContains = Maybe Text
a} :: ListProcessingJobs)
listProcessingJobs_lastModifiedTimeBefore :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.UTCTime)
listProcessingJobs_lastModifiedTimeBefore :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_lastModifiedTimeBefore = (ListProcessingJobs -> Maybe POSIX)
-> (ListProcessingJobs -> Maybe POSIX -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe POSIX
lastModifiedTimeBefore :: Maybe POSIX
$sel:lastModifiedTimeBefore:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
lastModifiedTimeBefore} -> Maybe POSIX
lastModifiedTimeBefore) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe POSIX
a -> ListProcessingJobs
s {$sel:lastModifiedTimeBefore:ListProcessingJobs' :: Maybe POSIX
lastModifiedTimeBefore = Maybe POSIX
a} :: ListProcessingJobs) ((Maybe POSIX -> f (Maybe POSIX))
-> ListProcessingJobs -> f ListProcessingJobs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs
-> f ListProcessingJobs
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
listProcessingJobs_creationTimeAfter :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.UTCTime)
listProcessingJobs_creationTimeAfter :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_creationTimeAfter = (ListProcessingJobs -> Maybe POSIX)
-> (ListProcessingJobs -> Maybe POSIX -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:creationTimeAfter:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
creationTimeAfter} -> Maybe POSIX
creationTimeAfter) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe POSIX
a -> ListProcessingJobs
s {$sel:creationTimeAfter:ListProcessingJobs' :: Maybe POSIX
creationTimeAfter = Maybe POSIX
a} :: ListProcessingJobs) ((Maybe POSIX -> f (Maybe POSIX))
-> ListProcessingJobs -> f ListProcessingJobs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs
-> f ListProcessingJobs
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
listProcessingJobs_nextToken :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.Text)
listProcessingJobs_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_nextToken = (ListProcessingJobs -> Maybe Text)
-> (ListProcessingJobs -> Maybe Text -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListProcessingJobs' :: ListProcessingJobs -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe Text
a -> ListProcessingJobs
s {$sel:nextToken:ListProcessingJobs' :: Maybe Text
nextToken = Maybe Text
a} :: ListProcessingJobs)
listProcessingJobs_sortOrder :: Lens.Lens' ListProcessingJobs (Prelude.Maybe SortOrder)
listProcessingJobs_sortOrder :: (Maybe SortOrder -> f (Maybe SortOrder))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_sortOrder = (ListProcessingJobs -> Maybe SortOrder)
-> (ListProcessingJobs -> Maybe SortOrder -> ListProcessingJobs)
-> Lens
ListProcessingJobs
ListProcessingJobs
(Maybe SortOrder)
(Maybe SortOrder)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe SortOrder
sortOrder :: Maybe SortOrder
$sel:sortOrder:ListProcessingJobs' :: ListProcessingJobs -> Maybe SortOrder
sortOrder} -> Maybe SortOrder
sortOrder) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe SortOrder
a -> ListProcessingJobs
s {$sel:sortOrder:ListProcessingJobs' :: Maybe SortOrder
sortOrder = Maybe SortOrder
a} :: ListProcessingJobs)
listProcessingJobs_lastModifiedTimeAfter :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.UTCTime)
listProcessingJobs_lastModifiedTimeAfter :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_lastModifiedTimeAfter = (ListProcessingJobs -> Maybe POSIX)
-> (ListProcessingJobs -> Maybe POSIX -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
$sel:lastModifiedTimeAfter:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
lastModifiedTimeAfter} -> Maybe POSIX
lastModifiedTimeAfter) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe POSIX
a -> ListProcessingJobs
s {$sel:lastModifiedTimeAfter:ListProcessingJobs' :: Maybe POSIX
lastModifiedTimeAfter = Maybe POSIX
a} :: ListProcessingJobs) ((Maybe POSIX -> f (Maybe POSIX))
-> ListProcessingJobs -> f ListProcessingJobs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs
-> f ListProcessingJobs
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
listProcessingJobs_creationTimeBefore :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.UTCTime)
listProcessingJobs_creationTimeBefore :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_creationTimeBefore = (ListProcessingJobs -> Maybe POSIX)
-> (ListProcessingJobs -> Maybe POSIX -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe POSIX
creationTimeBefore :: Maybe POSIX
$sel:creationTimeBefore:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
creationTimeBefore} -> Maybe POSIX
creationTimeBefore) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe POSIX
a -> ListProcessingJobs
s {$sel:creationTimeBefore:ListProcessingJobs' :: Maybe POSIX
creationTimeBefore = Maybe POSIX
a} :: ListProcessingJobs) ((Maybe POSIX -> f (Maybe POSIX))
-> ListProcessingJobs -> f ListProcessingJobs)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ListProcessingJobs
-> f ListProcessingJobs
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
listProcessingJobs_statusEquals :: Lens.Lens' ListProcessingJobs (Prelude.Maybe ProcessingJobStatus)
listProcessingJobs_statusEquals :: (Maybe ProcessingJobStatus -> f (Maybe ProcessingJobStatus))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_statusEquals = (ListProcessingJobs -> Maybe ProcessingJobStatus)
-> (ListProcessingJobs
-> Maybe ProcessingJobStatus -> ListProcessingJobs)
-> Lens
ListProcessingJobs
ListProcessingJobs
(Maybe ProcessingJobStatus)
(Maybe ProcessingJobStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe ProcessingJobStatus
statusEquals :: Maybe ProcessingJobStatus
$sel:statusEquals:ListProcessingJobs' :: ListProcessingJobs -> Maybe ProcessingJobStatus
statusEquals} -> Maybe ProcessingJobStatus
statusEquals) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe ProcessingJobStatus
a -> ListProcessingJobs
s {$sel:statusEquals:ListProcessingJobs' :: Maybe ProcessingJobStatus
statusEquals = Maybe ProcessingJobStatus
a} :: ListProcessingJobs)
listProcessingJobs_maxResults :: Lens.Lens' ListProcessingJobs (Prelude.Maybe Prelude.Natural)
listProcessingJobs_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_maxResults = (ListProcessingJobs -> Maybe Natural)
-> (ListProcessingJobs -> Maybe Natural -> ListProcessingJobs)
-> Lens
ListProcessingJobs
ListProcessingJobs
(Maybe Natural)
(Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListProcessingJobs' :: ListProcessingJobs -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe Natural
a -> ListProcessingJobs
s {$sel:maxResults:ListProcessingJobs' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListProcessingJobs)
listProcessingJobs_sortBy :: Lens.Lens' ListProcessingJobs (Prelude.Maybe SortBy)
listProcessingJobs_sortBy :: (Maybe SortBy -> f (Maybe SortBy))
-> ListProcessingJobs -> f ListProcessingJobs
listProcessingJobs_sortBy = (ListProcessingJobs -> Maybe SortBy)
-> (ListProcessingJobs -> Maybe SortBy -> ListProcessingJobs)
-> Lens
ListProcessingJobs ListProcessingJobs (Maybe SortBy) (Maybe SortBy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobs' {Maybe SortBy
sortBy :: Maybe SortBy
$sel:sortBy:ListProcessingJobs' :: ListProcessingJobs -> Maybe SortBy
sortBy} -> Maybe SortBy
sortBy) (\s :: ListProcessingJobs
s@ListProcessingJobs' {} Maybe SortBy
a -> ListProcessingJobs
s {$sel:sortBy:ListProcessingJobs' :: Maybe SortBy
sortBy = Maybe SortBy
a} :: ListProcessingJobs)
instance Core.AWSPager ListProcessingJobs where
page :: ListProcessingJobs
-> AWSResponse ListProcessingJobs -> Maybe ListProcessingJobs
page ListProcessingJobs
rq AWSResponse ListProcessingJobs
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListProcessingJobs
ListProcessingJobsResponse
rs
ListProcessingJobsResponse
-> Getting (First Text) ListProcessingJobsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListProcessingJobsResponse
-> Const (First Text) ListProcessingJobsResponse
Lens' ListProcessingJobsResponse (Maybe Text)
listProcessingJobsResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> ListProcessingJobsResponse
-> Const (First Text) ListProcessingJobsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListProcessingJobsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe ListProcessingJobs
forall a. Maybe a
Prelude.Nothing
| [ProcessingJobSummary] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListProcessingJobs
ListProcessingJobsResponse
rs
ListProcessingJobsResponse
-> Getting
[ProcessingJobSummary]
ListProcessingJobsResponse
[ProcessingJobSummary]
-> [ProcessingJobSummary]
forall s a. s -> Getting a s a -> a
Lens.^. Getting
[ProcessingJobSummary]
ListProcessingJobsResponse
[ProcessingJobSummary]
Lens' ListProcessingJobsResponse [ProcessingJobSummary]
listProcessingJobsResponse_processingJobSummaries
) =
Maybe ListProcessingJobs
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
ListProcessingJobs -> Maybe ListProcessingJobs
forall a. a -> Maybe a
Prelude.Just (ListProcessingJobs -> Maybe ListProcessingJobs)
-> ListProcessingJobs -> Maybe ListProcessingJobs
forall a b. (a -> b) -> a -> b
Prelude.$
ListProcessingJobs
rq
ListProcessingJobs
-> (ListProcessingJobs -> ListProcessingJobs) -> ListProcessingJobs
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListProcessingJobs -> Identity ListProcessingJobs
Lens
ListProcessingJobs ListProcessingJobs (Maybe Text) (Maybe Text)
listProcessingJobs_nextToken
((Maybe Text -> Identity (Maybe Text))
-> ListProcessingJobs -> Identity ListProcessingJobs)
-> Maybe Text -> ListProcessingJobs -> ListProcessingJobs
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListProcessingJobs
ListProcessingJobsResponse
rs
ListProcessingJobsResponse
-> Getting (First Text) ListProcessingJobsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListProcessingJobsResponse
-> Const (First Text) ListProcessingJobsResponse
Lens' ListProcessingJobsResponse (Maybe Text)
listProcessingJobsResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> ListProcessingJobsResponse
-> Const (First Text) ListProcessingJobsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListProcessingJobsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
instance Core.AWSRequest ListProcessingJobs where
type
AWSResponse ListProcessingJobs =
ListProcessingJobsResponse
request :: ListProcessingJobs -> Request ListProcessingJobs
request = Service -> ListProcessingJobs -> Request ListProcessingJobs
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ListProcessingJobs
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ListProcessingJobs)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ListProcessingJobs))
-> Logger
-> Service
-> Proxy ListProcessingJobs
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ListProcessingJobs)))
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
-> Int -> [ProcessingJobSummary] -> ListProcessingJobsResponse
ListProcessingJobsResponse'
(Maybe Text
-> Int -> [ProcessingJobSummary] -> ListProcessingJobsResponse)
-> Either String (Maybe Text)
-> Either
String
(Int -> [ProcessingJobSummary] -> ListProcessingJobsResponse)
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
"NextToken")
Either
String
(Int -> [ProcessingJobSummary] -> ListProcessingJobsResponse)
-> Either String Int
-> Either
String ([ProcessingJobSummary] -> ListProcessingJobsResponse)
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 ([ProcessingJobSummary] -> ListProcessingJobsResponse)
-> Either String [ProcessingJobSummary]
-> Either String ListProcessingJobsResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Either String (Maybe [ProcessingJobSummary])
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"ProcessingJobSummaries"
Either String (Maybe [ProcessingJobSummary])
-> [ProcessingJobSummary] -> Either String [ProcessingJobSummary]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [ProcessingJobSummary]
forall a. Monoid a => a
Prelude.mempty
)
)
instance Prelude.Hashable ListProcessingJobs
instance Prelude.NFData ListProcessingJobs
instance Core.ToHeaders ListProcessingJobs where
toHeaders :: ListProcessingJobs -> ResponseHeaders
toHeaders =
ResponseHeaders -> ListProcessingJobs -> 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.ListProcessingJobs" ::
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 ListProcessingJobs where
toJSON :: ListProcessingJobs -> Value
toJSON ListProcessingJobs' {Maybe Natural
Maybe Text
Maybe POSIX
Maybe ProcessingJobStatus
Maybe SortBy
Maybe SortOrder
sortBy :: Maybe SortBy
maxResults :: Maybe Natural
statusEquals :: Maybe ProcessingJobStatus
creationTimeBefore :: Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
sortOrder :: Maybe SortOrder
nextToken :: Maybe Text
creationTimeAfter :: Maybe POSIX
lastModifiedTimeBefore :: Maybe POSIX
nameContains :: Maybe Text
$sel:sortBy:ListProcessingJobs' :: ListProcessingJobs -> Maybe SortBy
$sel:maxResults:ListProcessingJobs' :: ListProcessingJobs -> Maybe Natural
$sel:statusEquals:ListProcessingJobs' :: ListProcessingJobs -> Maybe ProcessingJobStatus
$sel:creationTimeBefore:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
$sel:lastModifiedTimeAfter:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
$sel:sortOrder:ListProcessingJobs' :: ListProcessingJobs -> Maybe SortOrder
$sel:nextToken:ListProcessingJobs' :: ListProcessingJobs -> Maybe Text
$sel:creationTimeAfter:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
$sel:lastModifiedTimeBefore:ListProcessingJobs' :: ListProcessingJobs -> Maybe POSIX
$sel:nameContains:ListProcessingJobs' :: ListProcessingJobs -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"NameContains" 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
nameContains,
(Text
"LastModifiedTimeBefore" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeBefore,
(Text
"CreationTimeAfter" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeAfter,
(Text
"NextToken" 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
nextToken,
(Text
"SortOrder" Text -> SortOrder -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (SortOrder -> Pair) -> Maybe SortOrder -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SortOrder
sortOrder,
(Text
"LastModifiedTimeAfter" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeAfter,
(Text
"CreationTimeBefore" Text -> POSIX -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(POSIX -> Pair) -> Maybe POSIX -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeBefore,
(Text
"StatusEquals" Text -> ProcessingJobStatus -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (ProcessingJobStatus -> Pair)
-> Maybe ProcessingJobStatus -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ProcessingJobStatus
statusEquals,
(Text
"MaxResults" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxResults,
(Text
"SortBy" Text -> SortBy -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (SortBy -> Pair) -> Maybe SortBy -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SortBy
sortBy
]
)
instance Core.ToPath ListProcessingJobs where
toPath :: ListProcessingJobs -> ByteString
toPath = ByteString -> ListProcessingJobs -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ListProcessingJobs where
toQuery :: ListProcessingJobs -> QueryString
toQuery = QueryString -> ListProcessingJobs -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ListProcessingJobsResponse = ListProcessingJobsResponse'
{
ListProcessingJobsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListProcessingJobsResponse -> Int
httpStatus :: Prelude.Int,
ListProcessingJobsResponse -> [ProcessingJobSummary]
processingJobSummaries :: [ProcessingJobSummary]
}
deriving (ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool
(ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool)
-> (ListProcessingJobsResponse
-> ListProcessingJobsResponse -> Bool)
-> Eq ListProcessingJobsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool
$c/= :: ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool
== :: ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool
$c== :: ListProcessingJobsResponse -> ListProcessingJobsResponse -> Bool
Prelude.Eq, ReadPrec [ListProcessingJobsResponse]
ReadPrec ListProcessingJobsResponse
Int -> ReadS ListProcessingJobsResponse
ReadS [ListProcessingJobsResponse]
(Int -> ReadS ListProcessingJobsResponse)
-> ReadS [ListProcessingJobsResponse]
-> ReadPrec ListProcessingJobsResponse
-> ReadPrec [ListProcessingJobsResponse]
-> Read ListProcessingJobsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListProcessingJobsResponse]
$creadListPrec :: ReadPrec [ListProcessingJobsResponse]
readPrec :: ReadPrec ListProcessingJobsResponse
$creadPrec :: ReadPrec ListProcessingJobsResponse
readList :: ReadS [ListProcessingJobsResponse]
$creadList :: ReadS [ListProcessingJobsResponse]
readsPrec :: Int -> ReadS ListProcessingJobsResponse
$creadsPrec :: Int -> ReadS ListProcessingJobsResponse
Prelude.Read, Int -> ListProcessingJobsResponse -> ShowS
[ListProcessingJobsResponse] -> ShowS
ListProcessingJobsResponse -> String
(Int -> ListProcessingJobsResponse -> ShowS)
-> (ListProcessingJobsResponse -> String)
-> ([ListProcessingJobsResponse] -> ShowS)
-> Show ListProcessingJobsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListProcessingJobsResponse] -> ShowS
$cshowList :: [ListProcessingJobsResponse] -> ShowS
show :: ListProcessingJobsResponse -> String
$cshow :: ListProcessingJobsResponse -> String
showsPrec :: Int -> ListProcessingJobsResponse -> ShowS
$cshowsPrec :: Int -> ListProcessingJobsResponse -> ShowS
Prelude.Show, (forall x.
ListProcessingJobsResponse -> Rep ListProcessingJobsResponse x)
-> (forall x.
Rep ListProcessingJobsResponse x -> ListProcessingJobsResponse)
-> Generic ListProcessingJobsResponse
forall x.
Rep ListProcessingJobsResponse x -> ListProcessingJobsResponse
forall x.
ListProcessingJobsResponse -> Rep ListProcessingJobsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListProcessingJobsResponse x -> ListProcessingJobsResponse
$cfrom :: forall x.
ListProcessingJobsResponse -> Rep ListProcessingJobsResponse x
Prelude.Generic)
newListProcessingJobsResponse ::
Prelude.Int ->
ListProcessingJobsResponse
newListProcessingJobsResponse :: Int -> ListProcessingJobsResponse
newListProcessingJobsResponse Int
pHttpStatus_ =
ListProcessingJobsResponse' :: Maybe Text
-> Int -> [ProcessingJobSummary] -> ListProcessingJobsResponse
ListProcessingJobsResponse'
{ $sel:nextToken:ListProcessingJobsResponse' :: Maybe Text
nextToken =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListProcessingJobsResponse' :: Int
httpStatus = Int
pHttpStatus_,
$sel:processingJobSummaries:ListProcessingJobsResponse' :: [ProcessingJobSummary]
processingJobSummaries = [ProcessingJobSummary]
forall a. Monoid a => a
Prelude.mempty
}
listProcessingJobsResponse_nextToken :: Lens.Lens' ListProcessingJobsResponse (Prelude.Maybe Prelude.Text)
listProcessingJobsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListProcessingJobsResponse -> f ListProcessingJobsResponse
listProcessingJobsResponse_nextToken = (ListProcessingJobsResponse -> Maybe Text)
-> (ListProcessingJobsResponse
-> Maybe Text -> ListProcessingJobsResponse)
-> Lens' ListProcessingJobsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListProcessingJobsResponse' :: ListProcessingJobsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListProcessingJobsResponse
s@ListProcessingJobsResponse' {} Maybe Text
a -> ListProcessingJobsResponse
s {$sel:nextToken:ListProcessingJobsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListProcessingJobsResponse)
listProcessingJobsResponse_httpStatus :: Lens.Lens' ListProcessingJobsResponse Prelude.Int
listProcessingJobsResponse_httpStatus :: (Int -> f Int)
-> ListProcessingJobsResponse -> f ListProcessingJobsResponse
listProcessingJobsResponse_httpStatus = (ListProcessingJobsResponse -> Int)
-> (ListProcessingJobsResponse
-> Int -> ListProcessingJobsResponse)
-> Lens
ListProcessingJobsResponse ListProcessingJobsResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListProcessingJobsResponse' :: ListProcessingJobsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListProcessingJobsResponse
s@ListProcessingJobsResponse' {} Int
a -> ListProcessingJobsResponse
s {$sel:httpStatus:ListProcessingJobsResponse' :: Int
httpStatus = Int
a} :: ListProcessingJobsResponse)
listProcessingJobsResponse_processingJobSummaries :: Lens.Lens' ListProcessingJobsResponse [ProcessingJobSummary]
listProcessingJobsResponse_processingJobSummaries :: ([ProcessingJobSummary] -> f [ProcessingJobSummary])
-> ListProcessingJobsResponse -> f ListProcessingJobsResponse
listProcessingJobsResponse_processingJobSummaries = (ListProcessingJobsResponse -> [ProcessingJobSummary])
-> (ListProcessingJobsResponse
-> [ProcessingJobSummary] -> ListProcessingJobsResponse)
-> Lens' ListProcessingJobsResponse [ProcessingJobSummary]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListProcessingJobsResponse' {[ProcessingJobSummary]
processingJobSummaries :: [ProcessingJobSummary]
$sel:processingJobSummaries:ListProcessingJobsResponse' :: ListProcessingJobsResponse -> [ProcessingJobSummary]
processingJobSummaries} -> [ProcessingJobSummary]
processingJobSummaries) (\s :: ListProcessingJobsResponse
s@ListProcessingJobsResponse' {} [ProcessingJobSummary]
a -> ListProcessingJobsResponse
s {$sel:processingJobSummaries:ListProcessingJobsResponse' :: [ProcessingJobSummary]
processingJobSummaries = [ProcessingJobSummary]
a} :: ListProcessingJobsResponse) (([ProcessingJobSummary] -> f [ProcessingJobSummary])
-> ListProcessingJobsResponse -> f ListProcessingJobsResponse)
-> (([ProcessingJobSummary] -> f [ProcessingJobSummary])
-> [ProcessingJobSummary] -> f [ProcessingJobSummary])
-> ([ProcessingJobSummary] -> f [ProcessingJobSummary])
-> ListProcessingJobsResponse
-> f ListProcessingJobsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([ProcessingJobSummary] -> f [ProcessingJobSummary])
-> [ProcessingJobSummary] -> f [ProcessingJobSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Prelude.NFData ListProcessingJobsResponse