{-# 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.ListDeviceFleets
(
ListDeviceFleets (..),
newListDeviceFleets,
listDeviceFleets_creationTimeAfter,
listDeviceFleets_creationTimeBefore,
listDeviceFleets_lastModifiedTimeAfter,
listDeviceFleets_lastModifiedTimeBefore,
listDeviceFleets_maxResults,
listDeviceFleets_nameContains,
listDeviceFleets_nextToken,
listDeviceFleets_sortBy,
listDeviceFleets_sortOrder,
ListDeviceFleetsResponse (..),
newListDeviceFleetsResponse,
listDeviceFleetsResponse_nextToken,
listDeviceFleetsResponse_httpStatus,
listDeviceFleetsResponse_deviceFleetSummaries,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.SageMaker.Types
data ListDeviceFleets = ListDeviceFleets'
{
ListDeviceFleets -> Maybe POSIX
creationTimeAfter :: Prelude.Maybe Data.POSIX,
ListDeviceFleets -> Maybe POSIX
creationTimeBefore :: Prelude.Maybe Data.POSIX,
ListDeviceFleets -> Maybe POSIX
lastModifiedTimeAfter :: Prelude.Maybe Data.POSIX,
ListDeviceFleets -> Maybe POSIX
lastModifiedTimeBefore :: Prelude.Maybe Data.POSIX,
ListDeviceFleets -> Maybe Int
maxResults :: Prelude.Maybe Prelude.Int,
ListDeviceFleets -> Maybe Text
nameContains :: Prelude.Maybe Prelude.Text,
ListDeviceFleets -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListDeviceFleets -> Maybe ListDeviceFleetsSortBy
sortBy :: Prelude.Maybe ListDeviceFleetsSortBy,
ListDeviceFleets -> Maybe SortOrder
sortOrder :: Prelude.Maybe SortOrder
}
deriving (ListDeviceFleets -> ListDeviceFleets -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListDeviceFleets -> ListDeviceFleets -> Bool
$c/= :: ListDeviceFleets -> ListDeviceFleets -> Bool
== :: ListDeviceFleets -> ListDeviceFleets -> Bool
$c== :: ListDeviceFleets -> ListDeviceFleets -> Bool
Prelude.Eq, ReadPrec [ListDeviceFleets]
ReadPrec ListDeviceFleets
Int -> ReadS ListDeviceFleets
ReadS [ListDeviceFleets]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListDeviceFleets]
$creadListPrec :: ReadPrec [ListDeviceFleets]
readPrec :: ReadPrec ListDeviceFleets
$creadPrec :: ReadPrec ListDeviceFleets
readList :: ReadS [ListDeviceFleets]
$creadList :: ReadS [ListDeviceFleets]
readsPrec :: Int -> ReadS ListDeviceFleets
$creadsPrec :: Int -> ReadS ListDeviceFleets
Prelude.Read, Int -> ListDeviceFleets -> ShowS
[ListDeviceFleets] -> ShowS
ListDeviceFleets -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListDeviceFleets] -> ShowS
$cshowList :: [ListDeviceFleets] -> ShowS
show :: ListDeviceFleets -> String
$cshow :: ListDeviceFleets -> String
showsPrec :: Int -> ListDeviceFleets -> ShowS
$cshowsPrec :: Int -> ListDeviceFleets -> ShowS
Prelude.Show, forall x. Rep ListDeviceFleets x -> ListDeviceFleets
forall x. ListDeviceFleets -> Rep ListDeviceFleets x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListDeviceFleets x -> ListDeviceFleets
$cfrom :: forall x. ListDeviceFleets -> Rep ListDeviceFleets x
Prelude.Generic)
newListDeviceFleets ::
ListDeviceFleets
newListDeviceFleets :: ListDeviceFleets
newListDeviceFleets =
ListDeviceFleets'
{ $sel:creationTimeAfter:ListDeviceFleets' :: Maybe POSIX
creationTimeAfter =
forall a. Maybe a
Prelude.Nothing,
$sel:creationTimeBefore:ListDeviceFleets' :: Maybe POSIX
creationTimeBefore = forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedTimeAfter:ListDeviceFleets' :: Maybe POSIX
lastModifiedTimeAfter = forall a. Maybe a
Prelude.Nothing,
$sel:lastModifiedTimeBefore:ListDeviceFleets' :: Maybe POSIX
lastModifiedTimeBefore = forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListDeviceFleets' :: Maybe Int
maxResults = forall a. Maybe a
Prelude.Nothing,
$sel:nameContains:ListDeviceFleets' :: Maybe Text
nameContains = forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:ListDeviceFleets' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
$sel:sortBy:ListDeviceFleets' :: Maybe ListDeviceFleetsSortBy
sortBy = forall a. Maybe a
Prelude.Nothing,
$sel:sortOrder:ListDeviceFleets' :: Maybe SortOrder
sortOrder = forall a. Maybe a
Prelude.Nothing
}
listDeviceFleets_creationTimeAfter :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.UTCTime)
listDeviceFleets_creationTimeAfter :: Lens' ListDeviceFleets (Maybe UTCTime)
listDeviceFleets_creationTimeAfter = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:creationTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
creationTimeAfter} -> Maybe POSIX
creationTimeAfter) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe POSIX
a -> ListDeviceFleets
s {$sel:creationTimeAfter:ListDeviceFleets' :: Maybe POSIX
creationTimeAfter = Maybe POSIX
a} :: ListDeviceFleets) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
listDeviceFleets_creationTimeBefore :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.UTCTime)
listDeviceFleets_creationTimeBefore :: Lens' ListDeviceFleets (Maybe UTCTime)
listDeviceFleets_creationTimeBefore = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe POSIX
creationTimeBefore :: Maybe POSIX
$sel:creationTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
creationTimeBefore} -> Maybe POSIX
creationTimeBefore) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe POSIX
a -> ListDeviceFleets
s {$sel:creationTimeBefore:ListDeviceFleets' :: Maybe POSIX
creationTimeBefore = Maybe POSIX
a} :: ListDeviceFleets) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
listDeviceFleets_lastModifiedTimeAfter :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.UTCTime)
listDeviceFleets_lastModifiedTimeAfter :: Lens' ListDeviceFleets (Maybe UTCTime)
listDeviceFleets_lastModifiedTimeAfter = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
$sel:lastModifiedTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
lastModifiedTimeAfter} -> Maybe POSIX
lastModifiedTimeAfter) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe POSIX
a -> ListDeviceFleets
s {$sel:lastModifiedTimeAfter:ListDeviceFleets' :: Maybe POSIX
lastModifiedTimeAfter = Maybe POSIX
a} :: ListDeviceFleets) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
listDeviceFleets_lastModifiedTimeBefore :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.UTCTime)
listDeviceFleets_lastModifiedTimeBefore :: Lens' ListDeviceFleets (Maybe UTCTime)
listDeviceFleets_lastModifiedTimeBefore = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe POSIX
lastModifiedTimeBefore :: Maybe POSIX
$sel:lastModifiedTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
lastModifiedTimeBefore} -> Maybe POSIX
lastModifiedTimeBefore) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe POSIX
a -> ListDeviceFleets
s {$sel:lastModifiedTimeBefore:ListDeviceFleets' :: Maybe POSIX
lastModifiedTimeBefore = Maybe POSIX
a} :: ListDeviceFleets) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall (a :: Format). Iso' (Time a) UTCTime
Data._Time
listDeviceFleets_maxResults :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.Int)
listDeviceFleets_maxResults :: Lens' ListDeviceFleets (Maybe Int)
listDeviceFleets_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe Int
maxResults :: Maybe Int
$sel:maxResults:ListDeviceFleets' :: ListDeviceFleets -> Maybe Int
maxResults} -> Maybe Int
maxResults) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe Int
a -> ListDeviceFleets
s {$sel:maxResults:ListDeviceFleets' :: Maybe Int
maxResults = Maybe Int
a} :: ListDeviceFleets)
listDeviceFleets_nameContains :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.Text)
listDeviceFleets_nameContains :: Lens' ListDeviceFleets (Maybe Text)
listDeviceFleets_nameContains = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe Text
nameContains :: Maybe Text
$sel:nameContains:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
nameContains} -> Maybe Text
nameContains) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe Text
a -> ListDeviceFleets
s {$sel:nameContains:ListDeviceFleets' :: Maybe Text
nameContains = Maybe Text
a} :: ListDeviceFleets)
listDeviceFleets_nextToken :: Lens.Lens' ListDeviceFleets (Prelude.Maybe Prelude.Text)
listDeviceFleets_nextToken :: Lens' ListDeviceFleets (Maybe Text)
listDeviceFleets_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe Text
a -> ListDeviceFleets
s {$sel:nextToken:ListDeviceFleets' :: Maybe Text
nextToken = Maybe Text
a} :: ListDeviceFleets)
listDeviceFleets_sortBy :: Lens.Lens' ListDeviceFleets (Prelude.Maybe ListDeviceFleetsSortBy)
listDeviceFleets_sortBy :: Lens' ListDeviceFleets (Maybe ListDeviceFleetsSortBy)
listDeviceFleets_sortBy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe ListDeviceFleetsSortBy
sortBy :: Maybe ListDeviceFleetsSortBy
$sel:sortBy:ListDeviceFleets' :: ListDeviceFleets -> Maybe ListDeviceFleetsSortBy
sortBy} -> Maybe ListDeviceFleetsSortBy
sortBy) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe ListDeviceFleetsSortBy
a -> ListDeviceFleets
s {$sel:sortBy:ListDeviceFleets' :: Maybe ListDeviceFleetsSortBy
sortBy = Maybe ListDeviceFleetsSortBy
a} :: ListDeviceFleets)
listDeviceFleets_sortOrder :: Lens.Lens' ListDeviceFleets (Prelude.Maybe SortOrder)
listDeviceFleets_sortOrder :: Lens' ListDeviceFleets (Maybe SortOrder)
listDeviceFleets_sortOrder = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleets' {Maybe SortOrder
sortOrder :: Maybe SortOrder
$sel:sortOrder:ListDeviceFleets' :: ListDeviceFleets -> Maybe SortOrder
sortOrder} -> Maybe SortOrder
sortOrder) (\s :: ListDeviceFleets
s@ListDeviceFleets' {} Maybe SortOrder
a -> ListDeviceFleets
s {$sel:sortOrder:ListDeviceFleets' :: Maybe SortOrder
sortOrder = Maybe SortOrder
a} :: ListDeviceFleets)
instance Core.AWSPager ListDeviceFleets where
page :: ListDeviceFleets
-> AWSResponse ListDeviceFleets -> Maybe ListDeviceFleets
page ListDeviceFleets
rq AWSResponse ListDeviceFleets
rs
| forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListDeviceFleets
rs
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListDeviceFleetsResponse (Maybe Text)
listDeviceFleetsResponse_nextToken
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
forall a. Maybe a
Prelude.Nothing
| forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListDeviceFleets
rs
forall s a. s -> Getting a s a -> a
Lens.^. Lens' ListDeviceFleetsResponse [DeviceFleetSummary]
listDeviceFleetsResponse_deviceFleetSummaries
) =
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
forall a. a -> Maybe a
Prelude.Just
forall a b. (a -> b) -> a -> b
Prelude.$ ListDeviceFleets
rq
forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListDeviceFleets (Maybe Text)
listDeviceFleets_nextToken
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListDeviceFleets
rs
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListDeviceFleetsResponse (Maybe Text)
listDeviceFleetsResponse_nextToken
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
instance Core.AWSRequest ListDeviceFleets where
type
AWSResponse ListDeviceFleets =
ListDeviceFleetsResponse
request :: (Service -> Service)
-> ListDeviceFleets -> Request ListDeviceFleets
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListDeviceFleets
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListDeviceFleets)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text
-> Int -> [DeviceFleetSummary] -> ListDeviceFleetsResponse
ListDeviceFleetsResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"NextToken")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"DeviceFleetSummaries"
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
)
)
instance Prelude.Hashable ListDeviceFleets where
hashWithSalt :: Int -> ListDeviceFleets -> Int
hashWithSalt Int
_salt ListDeviceFleets' {Maybe Int
Maybe Text
Maybe POSIX
Maybe ListDeviceFleetsSortBy
Maybe SortOrder
sortOrder :: Maybe SortOrder
sortBy :: Maybe ListDeviceFleetsSortBy
nextToken :: Maybe Text
nameContains :: Maybe Text
maxResults :: Maybe Int
lastModifiedTimeBefore :: Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
creationTimeBefore :: Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:sortOrder:ListDeviceFleets' :: ListDeviceFleets -> Maybe SortOrder
$sel:sortBy:ListDeviceFleets' :: ListDeviceFleets -> Maybe ListDeviceFleetsSortBy
$sel:nextToken:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:nameContains:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:maxResults:ListDeviceFleets' :: ListDeviceFleets -> Maybe Int
$sel:lastModifiedTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:lastModifiedTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
creationTimeAfter
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
creationTimeBefore
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
lastModifiedTimeAfter
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe POSIX
lastModifiedTimeBefore
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
maxResults
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nameContains
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextToken
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ListDeviceFleetsSortBy
sortBy
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SortOrder
sortOrder
instance Prelude.NFData ListDeviceFleets where
rnf :: ListDeviceFleets -> ()
rnf ListDeviceFleets' {Maybe Int
Maybe Text
Maybe POSIX
Maybe ListDeviceFleetsSortBy
Maybe SortOrder
sortOrder :: Maybe SortOrder
sortBy :: Maybe ListDeviceFleetsSortBy
nextToken :: Maybe Text
nameContains :: Maybe Text
maxResults :: Maybe Int
lastModifiedTimeBefore :: Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
creationTimeBefore :: Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:sortOrder:ListDeviceFleets' :: ListDeviceFleets -> Maybe SortOrder
$sel:sortBy:ListDeviceFleets' :: ListDeviceFleets -> Maybe ListDeviceFleetsSortBy
$sel:nextToken:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:nameContains:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:maxResults:ListDeviceFleets' :: ListDeviceFleets -> Maybe Int
$sel:lastModifiedTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:lastModifiedTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
creationTimeAfter
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
creationTimeBefore
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
lastModifiedTimeAfter
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe POSIX
lastModifiedTimeBefore
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
maxResults
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nameContains
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ListDeviceFleetsSortBy
sortBy
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SortOrder
sortOrder
instance Data.ToHeaders ListDeviceFleets where
toHeaders :: ListDeviceFleets -> ResponseHeaders
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# (ByteString
"SageMaker.ListDeviceFleets" :: Prelude.ByteString),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON ListDeviceFleets where
toJSON :: ListDeviceFleets -> Value
toJSON ListDeviceFleets' {Maybe Int
Maybe Text
Maybe POSIX
Maybe ListDeviceFleetsSortBy
Maybe SortOrder
sortOrder :: Maybe SortOrder
sortBy :: Maybe ListDeviceFleetsSortBy
nextToken :: Maybe Text
nameContains :: Maybe Text
maxResults :: Maybe Int
lastModifiedTimeBefore :: Maybe POSIX
lastModifiedTimeAfter :: Maybe POSIX
creationTimeBefore :: Maybe POSIX
creationTimeAfter :: Maybe POSIX
$sel:sortOrder:ListDeviceFleets' :: ListDeviceFleets -> Maybe SortOrder
$sel:sortBy:ListDeviceFleets' :: ListDeviceFleets -> Maybe ListDeviceFleetsSortBy
$sel:nextToken:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:nameContains:ListDeviceFleets' :: ListDeviceFleets -> Maybe Text
$sel:maxResults:ListDeviceFleets' :: ListDeviceFleets -> Maybe Int
$sel:lastModifiedTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:lastModifiedTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeBefore:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
$sel:creationTimeAfter:ListDeviceFleets' :: ListDeviceFleets -> Maybe POSIX
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"CreationTimeAfter" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeAfter,
(Key
"CreationTimeBefore" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
creationTimeBefore,
(Key
"LastModifiedTimeAfter" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeAfter,
(Key
"LastModifiedTimeBefore" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe POSIX
lastModifiedTimeBefore,
(Key
"MaxResults" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
maxResults,
(Key
"NameContains" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
nameContains,
(Key
"NextToken" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
nextToken,
(Key
"SortBy" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ListDeviceFleetsSortBy
sortBy,
(Key
"SortOrder" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SortOrder
sortOrder
]
)
instance Data.ToPath ListDeviceFleets where
toPath :: ListDeviceFleets -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery ListDeviceFleets where
toQuery :: ListDeviceFleets -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data ListDeviceFleetsResponse = ListDeviceFleetsResponse'
{
ListDeviceFleetsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListDeviceFleetsResponse -> Int
httpStatus :: Prelude.Int,
ListDeviceFleetsResponse -> [DeviceFleetSummary]
deviceFleetSummaries :: [DeviceFleetSummary]
}
deriving (ListDeviceFleetsResponse -> ListDeviceFleetsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListDeviceFleetsResponse -> ListDeviceFleetsResponse -> Bool
$c/= :: ListDeviceFleetsResponse -> ListDeviceFleetsResponse -> Bool
== :: ListDeviceFleetsResponse -> ListDeviceFleetsResponse -> Bool
$c== :: ListDeviceFleetsResponse -> ListDeviceFleetsResponse -> Bool
Prelude.Eq, ReadPrec [ListDeviceFleetsResponse]
ReadPrec ListDeviceFleetsResponse
Int -> ReadS ListDeviceFleetsResponse
ReadS [ListDeviceFleetsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListDeviceFleetsResponse]
$creadListPrec :: ReadPrec [ListDeviceFleetsResponse]
readPrec :: ReadPrec ListDeviceFleetsResponse
$creadPrec :: ReadPrec ListDeviceFleetsResponse
readList :: ReadS [ListDeviceFleetsResponse]
$creadList :: ReadS [ListDeviceFleetsResponse]
readsPrec :: Int -> ReadS ListDeviceFleetsResponse
$creadsPrec :: Int -> ReadS ListDeviceFleetsResponse
Prelude.Read, Int -> ListDeviceFleetsResponse -> ShowS
[ListDeviceFleetsResponse] -> ShowS
ListDeviceFleetsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListDeviceFleetsResponse] -> ShowS
$cshowList :: [ListDeviceFleetsResponse] -> ShowS
show :: ListDeviceFleetsResponse -> String
$cshow :: ListDeviceFleetsResponse -> String
showsPrec :: Int -> ListDeviceFleetsResponse -> ShowS
$cshowsPrec :: Int -> ListDeviceFleetsResponse -> ShowS
Prelude.Show, forall x.
Rep ListDeviceFleetsResponse x -> ListDeviceFleetsResponse
forall x.
ListDeviceFleetsResponse -> Rep ListDeviceFleetsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListDeviceFleetsResponse x -> ListDeviceFleetsResponse
$cfrom :: forall x.
ListDeviceFleetsResponse -> Rep ListDeviceFleetsResponse x
Prelude.Generic)
newListDeviceFleetsResponse ::
Prelude.Int ->
ListDeviceFleetsResponse
newListDeviceFleetsResponse :: Int -> ListDeviceFleetsResponse
newListDeviceFleetsResponse Int
pHttpStatus_ =
ListDeviceFleetsResponse'
{ $sel:nextToken:ListDeviceFleetsResponse' :: Maybe Text
nextToken =
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListDeviceFleetsResponse' :: Int
httpStatus = Int
pHttpStatus_,
$sel:deviceFleetSummaries:ListDeviceFleetsResponse' :: [DeviceFleetSummary]
deviceFleetSummaries = forall a. Monoid a => a
Prelude.mempty
}
listDeviceFleetsResponse_nextToken :: Lens.Lens' ListDeviceFleetsResponse (Prelude.Maybe Prelude.Text)
listDeviceFleetsResponse_nextToken :: Lens' ListDeviceFleetsResponse (Maybe Text)
listDeviceFleetsResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleetsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListDeviceFleetsResponse
s@ListDeviceFleetsResponse' {} Maybe Text
a -> ListDeviceFleetsResponse
s {$sel:nextToken:ListDeviceFleetsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListDeviceFleetsResponse)
listDeviceFleetsResponse_httpStatus :: Lens.Lens' ListDeviceFleetsResponse Prelude.Int
listDeviceFleetsResponse_httpStatus :: Lens' ListDeviceFleetsResponse Int
listDeviceFleetsResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleetsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListDeviceFleetsResponse
s@ListDeviceFleetsResponse' {} Int
a -> ListDeviceFleetsResponse
s {$sel:httpStatus:ListDeviceFleetsResponse' :: Int
httpStatus = Int
a} :: ListDeviceFleetsResponse)
listDeviceFleetsResponse_deviceFleetSummaries :: Lens.Lens' ListDeviceFleetsResponse [DeviceFleetSummary]
listDeviceFleetsResponse_deviceFleetSummaries :: Lens' ListDeviceFleetsResponse [DeviceFleetSummary]
listDeviceFleetsResponse_deviceFleetSummaries = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDeviceFleetsResponse' {[DeviceFleetSummary]
deviceFleetSummaries :: [DeviceFleetSummary]
$sel:deviceFleetSummaries:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> [DeviceFleetSummary]
deviceFleetSummaries} -> [DeviceFleetSummary]
deviceFleetSummaries) (\s :: ListDeviceFleetsResponse
s@ListDeviceFleetsResponse' {} [DeviceFleetSummary]
a -> ListDeviceFleetsResponse
s {$sel:deviceFleetSummaries:ListDeviceFleetsResponse' :: [DeviceFleetSummary]
deviceFleetSummaries = [DeviceFleetSummary]
a} :: ListDeviceFleetsResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Prelude.NFData ListDeviceFleetsResponse where
rnf :: ListDeviceFleetsResponse -> ()
rnf ListDeviceFleetsResponse' {Int
[DeviceFleetSummary]
Maybe Text
deviceFleetSummaries :: [DeviceFleetSummary]
httpStatus :: Int
nextToken :: Maybe Text
$sel:deviceFleetSummaries:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> [DeviceFleetSummary]
$sel:httpStatus:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> Int
$sel:nextToken:ListDeviceFleetsResponse' :: ListDeviceFleetsResponse -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf [DeviceFleetSummary]
deviceFleetSummaries