{-# 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.MechanicalTurk.ListReviewableHITs
(
ListReviewableHITs (..),
newListReviewableHITs,
listReviewableHITs_status,
listReviewableHITs_hITTypeId,
listReviewableHITs_nextToken,
listReviewableHITs_maxResults,
ListReviewableHITsResponse (..),
newListReviewableHITsResponse,
listReviewableHITsResponse_nextToken,
listReviewableHITsResponse_numResults,
listReviewableHITsResponse_hITs,
listReviewableHITsResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MechanicalTurk.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data ListReviewableHITs = ListReviewableHITs'
{
ListReviewableHITs -> Maybe ReviewableHITStatus
status :: Prelude.Maybe ReviewableHITStatus,
ListReviewableHITs -> Maybe Text
hITTypeId :: Prelude.Maybe Prelude.Text,
ListReviewableHITs -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListReviewableHITs -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
}
deriving (ListReviewableHITs -> ListReviewableHITs -> Bool
(ListReviewableHITs -> ListReviewableHITs -> Bool)
-> (ListReviewableHITs -> ListReviewableHITs -> Bool)
-> Eq ListReviewableHITs
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListReviewableHITs -> ListReviewableHITs -> Bool
$c/= :: ListReviewableHITs -> ListReviewableHITs -> Bool
== :: ListReviewableHITs -> ListReviewableHITs -> Bool
$c== :: ListReviewableHITs -> ListReviewableHITs -> Bool
Prelude.Eq, ReadPrec [ListReviewableHITs]
ReadPrec ListReviewableHITs
Int -> ReadS ListReviewableHITs
ReadS [ListReviewableHITs]
(Int -> ReadS ListReviewableHITs)
-> ReadS [ListReviewableHITs]
-> ReadPrec ListReviewableHITs
-> ReadPrec [ListReviewableHITs]
-> Read ListReviewableHITs
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListReviewableHITs]
$creadListPrec :: ReadPrec [ListReviewableHITs]
readPrec :: ReadPrec ListReviewableHITs
$creadPrec :: ReadPrec ListReviewableHITs
readList :: ReadS [ListReviewableHITs]
$creadList :: ReadS [ListReviewableHITs]
readsPrec :: Int -> ReadS ListReviewableHITs
$creadsPrec :: Int -> ReadS ListReviewableHITs
Prelude.Read, Int -> ListReviewableHITs -> ShowS
[ListReviewableHITs] -> ShowS
ListReviewableHITs -> String
(Int -> ListReviewableHITs -> ShowS)
-> (ListReviewableHITs -> String)
-> ([ListReviewableHITs] -> ShowS)
-> Show ListReviewableHITs
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListReviewableHITs] -> ShowS
$cshowList :: [ListReviewableHITs] -> ShowS
show :: ListReviewableHITs -> String
$cshow :: ListReviewableHITs -> String
showsPrec :: Int -> ListReviewableHITs -> ShowS
$cshowsPrec :: Int -> ListReviewableHITs -> ShowS
Prelude.Show, (forall x. ListReviewableHITs -> Rep ListReviewableHITs x)
-> (forall x. Rep ListReviewableHITs x -> ListReviewableHITs)
-> Generic ListReviewableHITs
forall x. Rep ListReviewableHITs x -> ListReviewableHITs
forall x. ListReviewableHITs -> Rep ListReviewableHITs x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListReviewableHITs x -> ListReviewableHITs
$cfrom :: forall x. ListReviewableHITs -> Rep ListReviewableHITs x
Prelude.Generic)
newListReviewableHITs ::
ListReviewableHITs
newListReviewableHITs :: ListReviewableHITs
newListReviewableHITs =
ListReviewableHITs' :: Maybe ReviewableHITStatus
-> Maybe Text -> Maybe Text -> Maybe Natural -> ListReviewableHITs
ListReviewableHITs'
{ $sel:status:ListReviewableHITs' :: Maybe ReviewableHITStatus
status = Maybe ReviewableHITStatus
forall a. Maybe a
Prelude.Nothing,
$sel:hITTypeId:ListReviewableHITs' :: Maybe Text
hITTypeId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:ListReviewableHITs' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListReviewableHITs' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
listReviewableHITs_status :: Lens.Lens' ListReviewableHITs (Prelude.Maybe ReviewableHITStatus)
listReviewableHITs_status :: (Maybe ReviewableHITStatus -> f (Maybe ReviewableHITStatus))
-> ListReviewableHITs -> f ListReviewableHITs
listReviewableHITs_status = (ListReviewableHITs -> Maybe ReviewableHITStatus)
-> (ListReviewableHITs
-> Maybe ReviewableHITStatus -> ListReviewableHITs)
-> Lens
ListReviewableHITs
ListReviewableHITs
(Maybe ReviewableHITStatus)
(Maybe ReviewableHITStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITs' {Maybe ReviewableHITStatus
status :: Maybe ReviewableHITStatus
$sel:status:ListReviewableHITs' :: ListReviewableHITs -> Maybe ReviewableHITStatus
status} -> Maybe ReviewableHITStatus
status) (\s :: ListReviewableHITs
s@ListReviewableHITs' {} Maybe ReviewableHITStatus
a -> ListReviewableHITs
s {$sel:status:ListReviewableHITs' :: Maybe ReviewableHITStatus
status = Maybe ReviewableHITStatus
a} :: ListReviewableHITs)
listReviewableHITs_hITTypeId :: Lens.Lens' ListReviewableHITs (Prelude.Maybe Prelude.Text)
listReviewableHITs_hITTypeId :: (Maybe Text -> f (Maybe Text))
-> ListReviewableHITs -> f ListReviewableHITs
listReviewableHITs_hITTypeId = (ListReviewableHITs -> Maybe Text)
-> (ListReviewableHITs -> Maybe Text -> ListReviewableHITs)
-> Lens
ListReviewableHITs ListReviewableHITs (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITs' {Maybe Text
hITTypeId :: Maybe Text
$sel:hITTypeId:ListReviewableHITs' :: ListReviewableHITs -> Maybe Text
hITTypeId} -> Maybe Text
hITTypeId) (\s :: ListReviewableHITs
s@ListReviewableHITs' {} Maybe Text
a -> ListReviewableHITs
s {$sel:hITTypeId:ListReviewableHITs' :: Maybe Text
hITTypeId = Maybe Text
a} :: ListReviewableHITs)
listReviewableHITs_nextToken :: Lens.Lens' ListReviewableHITs (Prelude.Maybe Prelude.Text)
listReviewableHITs_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListReviewableHITs -> f ListReviewableHITs
listReviewableHITs_nextToken = (ListReviewableHITs -> Maybe Text)
-> (ListReviewableHITs -> Maybe Text -> ListReviewableHITs)
-> Lens
ListReviewableHITs ListReviewableHITs (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITs' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListReviewableHITs' :: ListReviewableHITs -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListReviewableHITs
s@ListReviewableHITs' {} Maybe Text
a -> ListReviewableHITs
s {$sel:nextToken:ListReviewableHITs' :: Maybe Text
nextToken = Maybe Text
a} :: ListReviewableHITs)
listReviewableHITs_maxResults :: Lens.Lens' ListReviewableHITs (Prelude.Maybe Prelude.Natural)
listReviewableHITs_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListReviewableHITs -> f ListReviewableHITs
listReviewableHITs_maxResults = (ListReviewableHITs -> Maybe Natural)
-> (ListReviewableHITs -> Maybe Natural -> ListReviewableHITs)
-> Lens
ListReviewableHITs
ListReviewableHITs
(Maybe Natural)
(Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITs' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListReviewableHITs' :: ListReviewableHITs -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListReviewableHITs
s@ListReviewableHITs' {} Maybe Natural
a -> ListReviewableHITs
s {$sel:maxResults:ListReviewableHITs' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListReviewableHITs)
instance Core.AWSPager ListReviewableHITs where
page :: ListReviewableHITs
-> AWSResponse ListReviewableHITs -> Maybe ListReviewableHITs
page ListReviewableHITs
rq AWSResponse ListReviewableHITs
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListReviewableHITs
ListReviewableHITsResponse
rs
ListReviewableHITsResponse
-> Getting (First Text) ListReviewableHITsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListReviewableHITsResponse
-> Const (First Text) ListReviewableHITsResponse
Lens' ListReviewableHITsResponse (Maybe Text)
listReviewableHITsResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> ListReviewableHITsResponse
-> Const (First Text) ListReviewableHITsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListReviewableHITsResponse 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 ListReviewableHITs
forall a. Maybe a
Prelude.Nothing
| Maybe [HIT] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListReviewableHITs
ListReviewableHITsResponse
rs
ListReviewableHITsResponse
-> Getting (First [HIT]) ListReviewableHITsResponse [HIT]
-> Maybe [HIT]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [HIT] -> Const (First [HIT]) (Maybe [HIT]))
-> ListReviewableHITsResponse
-> Const (First [HIT]) ListReviewableHITsResponse
Lens' ListReviewableHITsResponse (Maybe [HIT])
listReviewableHITsResponse_hITs ((Maybe [HIT] -> Const (First [HIT]) (Maybe [HIT]))
-> ListReviewableHITsResponse
-> Const (First [HIT]) ListReviewableHITsResponse)
-> (([HIT] -> Const (First [HIT]) [HIT])
-> Maybe [HIT] -> Const (First [HIT]) (Maybe [HIT]))
-> Getting (First [HIT]) ListReviewableHITsResponse [HIT]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([HIT] -> Const (First [HIT]) [HIT])
-> Maybe [HIT] -> Const (First [HIT]) (Maybe [HIT])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe ListReviewableHITs
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
ListReviewableHITs -> Maybe ListReviewableHITs
forall a. a -> Maybe a
Prelude.Just (ListReviewableHITs -> Maybe ListReviewableHITs)
-> ListReviewableHITs -> Maybe ListReviewableHITs
forall a b. (a -> b) -> a -> b
Prelude.$
ListReviewableHITs
rq
ListReviewableHITs
-> (ListReviewableHITs -> ListReviewableHITs) -> ListReviewableHITs
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListReviewableHITs -> Identity ListReviewableHITs
Lens
ListReviewableHITs ListReviewableHITs (Maybe Text) (Maybe Text)
listReviewableHITs_nextToken
((Maybe Text -> Identity (Maybe Text))
-> ListReviewableHITs -> Identity ListReviewableHITs)
-> Maybe Text -> ListReviewableHITs -> ListReviewableHITs
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListReviewableHITs
ListReviewableHITsResponse
rs
ListReviewableHITsResponse
-> Getting (First Text) ListReviewableHITsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListReviewableHITsResponse
-> Const (First Text) ListReviewableHITsResponse
Lens' ListReviewableHITsResponse (Maybe Text)
listReviewableHITsResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> ListReviewableHITsResponse
-> Const (First Text) ListReviewableHITsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListReviewableHITsResponse 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 ListReviewableHITs where
type
AWSResponse ListReviewableHITs =
ListReviewableHITsResponse
request :: ListReviewableHITs -> Request ListReviewableHITs
request = Service -> ListReviewableHITs -> Request ListReviewableHITs
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ListReviewableHITs
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ListReviewableHITs)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ListReviewableHITs))
-> Logger
-> Service
-> Proxy ListReviewableHITs
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse ListReviewableHITs)))
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 Int -> Maybe [HIT] -> Int -> ListReviewableHITsResponse
ListReviewableHITsResponse'
(Maybe Text
-> Maybe Int -> Maybe [HIT] -> Int -> ListReviewableHITsResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe Int -> Maybe [HIT] -> Int -> ListReviewableHITsResponse)
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
(Maybe Int -> Maybe [HIT] -> Int -> ListReviewableHITsResponse)
-> Either String (Maybe Int)
-> Either String (Maybe [HIT] -> Int -> ListReviewableHITsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Int)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"NumResults")
Either String (Maybe [HIT] -> Int -> ListReviewableHITsResponse)
-> Either String (Maybe [HIT])
-> Either String (Int -> ListReviewableHITsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe [HIT]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"HITs" Either String (Maybe (Maybe [HIT]))
-> Maybe [HIT] -> Either String (Maybe [HIT])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [HIT]
forall a. Monoid a => a
Prelude.mempty)
Either String (Int -> ListReviewableHITsResponse)
-> Either String Int -> Either String ListReviewableHITsResponse
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 ListReviewableHITs
instance Prelude.NFData ListReviewableHITs
instance Core.ToHeaders ListReviewableHITs where
toHeaders :: ListReviewableHITs -> ResponseHeaders
toHeaders =
ResponseHeaders -> ListReviewableHITs -> 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
"MTurkRequesterServiceV20170117.ListReviewableHITs" ::
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 ListReviewableHITs where
toJSON :: ListReviewableHITs -> Value
toJSON ListReviewableHITs' {Maybe Natural
Maybe Text
Maybe ReviewableHITStatus
maxResults :: Maybe Natural
nextToken :: Maybe Text
hITTypeId :: Maybe Text
status :: Maybe ReviewableHITStatus
$sel:maxResults:ListReviewableHITs' :: ListReviewableHITs -> Maybe Natural
$sel:nextToken:ListReviewableHITs' :: ListReviewableHITs -> Maybe Text
$sel:hITTypeId:ListReviewableHITs' :: ListReviewableHITs -> Maybe Text
$sel:status:ListReviewableHITs' :: ListReviewableHITs -> Maybe ReviewableHITStatus
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"Status" Text -> ReviewableHITStatus -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (ReviewableHITStatus -> Pair)
-> Maybe ReviewableHITStatus -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ReviewableHITStatus
status,
(Text
"HITTypeId" 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
hITTypeId,
(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
"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
]
)
instance Core.ToPath ListReviewableHITs where
toPath :: ListReviewableHITs -> ByteString
toPath = ByteString -> ListReviewableHITs -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ListReviewableHITs where
toQuery :: ListReviewableHITs -> QueryString
toQuery = QueryString -> ListReviewableHITs -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ListReviewableHITsResponse = ListReviewableHITsResponse'
{ ListReviewableHITsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListReviewableHITsResponse -> Maybe Int
numResults :: Prelude.Maybe Prelude.Int,
ListReviewableHITsResponse -> Maybe [HIT]
hITs :: Prelude.Maybe [HIT],
ListReviewableHITsResponse -> Int
httpStatus :: Prelude.Int
}
deriving (ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool
(ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool)
-> (ListReviewableHITsResponse
-> ListReviewableHITsResponse -> Bool)
-> Eq ListReviewableHITsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool
$c/= :: ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool
== :: ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool
$c== :: ListReviewableHITsResponse -> ListReviewableHITsResponse -> Bool
Prelude.Eq, ReadPrec [ListReviewableHITsResponse]
ReadPrec ListReviewableHITsResponse
Int -> ReadS ListReviewableHITsResponse
ReadS [ListReviewableHITsResponse]
(Int -> ReadS ListReviewableHITsResponse)
-> ReadS [ListReviewableHITsResponse]
-> ReadPrec ListReviewableHITsResponse
-> ReadPrec [ListReviewableHITsResponse]
-> Read ListReviewableHITsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListReviewableHITsResponse]
$creadListPrec :: ReadPrec [ListReviewableHITsResponse]
readPrec :: ReadPrec ListReviewableHITsResponse
$creadPrec :: ReadPrec ListReviewableHITsResponse
readList :: ReadS [ListReviewableHITsResponse]
$creadList :: ReadS [ListReviewableHITsResponse]
readsPrec :: Int -> ReadS ListReviewableHITsResponse
$creadsPrec :: Int -> ReadS ListReviewableHITsResponse
Prelude.Read, Int -> ListReviewableHITsResponse -> ShowS
[ListReviewableHITsResponse] -> ShowS
ListReviewableHITsResponse -> String
(Int -> ListReviewableHITsResponse -> ShowS)
-> (ListReviewableHITsResponse -> String)
-> ([ListReviewableHITsResponse] -> ShowS)
-> Show ListReviewableHITsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListReviewableHITsResponse] -> ShowS
$cshowList :: [ListReviewableHITsResponse] -> ShowS
show :: ListReviewableHITsResponse -> String
$cshow :: ListReviewableHITsResponse -> String
showsPrec :: Int -> ListReviewableHITsResponse -> ShowS
$cshowsPrec :: Int -> ListReviewableHITsResponse -> ShowS
Prelude.Show, (forall x.
ListReviewableHITsResponse -> Rep ListReviewableHITsResponse x)
-> (forall x.
Rep ListReviewableHITsResponse x -> ListReviewableHITsResponse)
-> Generic ListReviewableHITsResponse
forall x.
Rep ListReviewableHITsResponse x -> ListReviewableHITsResponse
forall x.
ListReviewableHITsResponse -> Rep ListReviewableHITsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListReviewableHITsResponse x -> ListReviewableHITsResponse
$cfrom :: forall x.
ListReviewableHITsResponse -> Rep ListReviewableHITsResponse x
Prelude.Generic)
newListReviewableHITsResponse ::
Prelude.Int ->
ListReviewableHITsResponse
newListReviewableHITsResponse :: Int -> ListReviewableHITsResponse
newListReviewableHITsResponse Int
pHttpStatus_ =
ListReviewableHITsResponse' :: Maybe Text
-> Maybe Int -> Maybe [HIT] -> Int -> ListReviewableHITsResponse
ListReviewableHITsResponse'
{ $sel:nextToken:ListReviewableHITsResponse' :: Maybe Text
nextToken =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:numResults:ListReviewableHITsResponse' :: Maybe Int
numResults = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:hITs:ListReviewableHITsResponse' :: Maybe [HIT]
hITs = Maybe [HIT]
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListReviewableHITsResponse' :: Int
httpStatus = Int
pHttpStatus_
}
listReviewableHITsResponse_nextToken :: Lens.Lens' ListReviewableHITsResponse (Prelude.Maybe Prelude.Text)
listReviewableHITsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListReviewableHITsResponse -> f ListReviewableHITsResponse
listReviewableHITsResponse_nextToken = (ListReviewableHITsResponse -> Maybe Text)
-> (ListReviewableHITsResponse
-> Maybe Text -> ListReviewableHITsResponse)
-> Lens' ListReviewableHITsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListReviewableHITsResponse' :: ListReviewableHITsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListReviewableHITsResponse
s@ListReviewableHITsResponse' {} Maybe Text
a -> ListReviewableHITsResponse
s {$sel:nextToken:ListReviewableHITsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListReviewableHITsResponse)
listReviewableHITsResponse_numResults :: Lens.Lens' ListReviewableHITsResponse (Prelude.Maybe Prelude.Int)
listReviewableHITsResponse_numResults :: (Maybe Int -> f (Maybe Int))
-> ListReviewableHITsResponse -> f ListReviewableHITsResponse
listReviewableHITsResponse_numResults = (ListReviewableHITsResponse -> Maybe Int)
-> (ListReviewableHITsResponse
-> Maybe Int -> ListReviewableHITsResponse)
-> Lens
ListReviewableHITsResponse
ListReviewableHITsResponse
(Maybe Int)
(Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITsResponse' {Maybe Int
numResults :: Maybe Int
$sel:numResults:ListReviewableHITsResponse' :: ListReviewableHITsResponse -> Maybe Int
numResults} -> Maybe Int
numResults) (\s :: ListReviewableHITsResponse
s@ListReviewableHITsResponse' {} Maybe Int
a -> ListReviewableHITsResponse
s {$sel:numResults:ListReviewableHITsResponse' :: Maybe Int
numResults = Maybe Int
a} :: ListReviewableHITsResponse)
listReviewableHITsResponse_hITs :: Lens.Lens' ListReviewableHITsResponse (Prelude.Maybe [HIT])
listReviewableHITsResponse_hITs :: (Maybe [HIT] -> f (Maybe [HIT]))
-> ListReviewableHITsResponse -> f ListReviewableHITsResponse
listReviewableHITsResponse_hITs = (ListReviewableHITsResponse -> Maybe [HIT])
-> (ListReviewableHITsResponse
-> Maybe [HIT] -> ListReviewableHITsResponse)
-> Lens' ListReviewableHITsResponse (Maybe [HIT])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITsResponse' {Maybe [HIT]
hITs :: Maybe [HIT]
$sel:hITs:ListReviewableHITsResponse' :: ListReviewableHITsResponse -> Maybe [HIT]
hITs} -> Maybe [HIT]
hITs) (\s :: ListReviewableHITsResponse
s@ListReviewableHITsResponse' {} Maybe [HIT]
a -> ListReviewableHITsResponse
s {$sel:hITs:ListReviewableHITsResponse' :: Maybe [HIT]
hITs = Maybe [HIT]
a} :: ListReviewableHITsResponse) ((Maybe [HIT] -> f (Maybe [HIT]))
-> ListReviewableHITsResponse -> f ListReviewableHITsResponse)
-> ((Maybe [HIT] -> f (Maybe [HIT]))
-> Maybe [HIT] -> f (Maybe [HIT]))
-> (Maybe [HIT] -> f (Maybe [HIT]))
-> ListReviewableHITsResponse
-> f ListReviewableHITsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [HIT] [HIT] [HIT] [HIT]
-> Iso (Maybe [HIT]) (Maybe [HIT]) (Maybe [HIT]) (Maybe [HIT])
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 [HIT] [HIT] [HIT] [HIT]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
listReviewableHITsResponse_httpStatus :: Lens.Lens' ListReviewableHITsResponse Prelude.Int
listReviewableHITsResponse_httpStatus :: (Int -> f Int)
-> ListReviewableHITsResponse -> f ListReviewableHITsResponse
listReviewableHITsResponse_httpStatus = (ListReviewableHITsResponse -> Int)
-> (ListReviewableHITsResponse
-> Int -> ListReviewableHITsResponse)
-> Lens
ListReviewableHITsResponse ListReviewableHITsResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListReviewableHITsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListReviewableHITsResponse' :: ListReviewableHITsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListReviewableHITsResponse
s@ListReviewableHITsResponse' {} Int
a -> ListReviewableHITsResponse
s {$sel:httpStatus:ListReviewableHITsResponse' :: Int
httpStatus = Int
a} :: ListReviewableHITsResponse)
instance Prelude.NFData ListReviewableHITsResponse