{-# 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.Personalize.ListDatasets
(
ListDatasets (..),
newListDatasets,
listDatasets_nextToken,
listDatasets_datasetGroupArn,
listDatasets_maxResults,
ListDatasetsResponse (..),
newListDatasetsResponse,
listDatasetsResponse_nextToken,
listDatasetsResponse_datasets,
listDatasetsResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Personalize.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data ListDatasets = ListDatasets'
{
ListDatasets -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListDatasets -> Maybe Text
datasetGroupArn :: Prelude.Maybe Prelude.Text,
ListDatasets -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
}
deriving (ListDatasets -> ListDatasets -> Bool
(ListDatasets -> ListDatasets -> Bool)
-> (ListDatasets -> ListDatasets -> Bool) -> Eq ListDatasets
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListDatasets -> ListDatasets -> Bool
$c/= :: ListDatasets -> ListDatasets -> Bool
== :: ListDatasets -> ListDatasets -> Bool
$c== :: ListDatasets -> ListDatasets -> Bool
Prelude.Eq, ReadPrec [ListDatasets]
ReadPrec ListDatasets
Int -> ReadS ListDatasets
ReadS [ListDatasets]
(Int -> ReadS ListDatasets)
-> ReadS [ListDatasets]
-> ReadPrec ListDatasets
-> ReadPrec [ListDatasets]
-> Read ListDatasets
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListDatasets]
$creadListPrec :: ReadPrec [ListDatasets]
readPrec :: ReadPrec ListDatasets
$creadPrec :: ReadPrec ListDatasets
readList :: ReadS [ListDatasets]
$creadList :: ReadS [ListDatasets]
readsPrec :: Int -> ReadS ListDatasets
$creadsPrec :: Int -> ReadS ListDatasets
Prelude.Read, Int -> ListDatasets -> ShowS
[ListDatasets] -> ShowS
ListDatasets -> String
(Int -> ListDatasets -> ShowS)
-> (ListDatasets -> String)
-> ([ListDatasets] -> ShowS)
-> Show ListDatasets
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListDatasets] -> ShowS
$cshowList :: [ListDatasets] -> ShowS
show :: ListDatasets -> String
$cshow :: ListDatasets -> String
showsPrec :: Int -> ListDatasets -> ShowS
$cshowsPrec :: Int -> ListDatasets -> ShowS
Prelude.Show, (forall x. ListDatasets -> Rep ListDatasets x)
-> (forall x. Rep ListDatasets x -> ListDatasets)
-> Generic ListDatasets
forall x. Rep ListDatasets x -> ListDatasets
forall x. ListDatasets -> Rep ListDatasets x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListDatasets x -> ListDatasets
$cfrom :: forall x. ListDatasets -> Rep ListDatasets x
Prelude.Generic)
newListDatasets ::
ListDatasets
newListDatasets :: ListDatasets
newListDatasets =
ListDatasets' :: Maybe Text -> Maybe Text -> Maybe Natural -> ListDatasets
ListDatasets'
{ $sel:nextToken:ListDatasets' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:datasetGroupArn:ListDatasets' :: Maybe Text
datasetGroupArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListDatasets' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
listDatasets_nextToken :: Lens.Lens' ListDatasets (Prelude.Maybe Prelude.Text)
listDatasets_nextToken :: (Maybe Text -> f (Maybe Text)) -> ListDatasets -> f ListDatasets
listDatasets_nextToken = (ListDatasets -> Maybe Text)
-> (ListDatasets -> Maybe Text -> ListDatasets)
-> Lens ListDatasets ListDatasets (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasets' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListDatasets' :: ListDatasets -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListDatasets
s@ListDatasets' {} Maybe Text
a -> ListDatasets
s {$sel:nextToken:ListDatasets' :: Maybe Text
nextToken = Maybe Text
a} :: ListDatasets)
listDatasets_datasetGroupArn :: Lens.Lens' ListDatasets (Prelude.Maybe Prelude.Text)
listDatasets_datasetGroupArn :: (Maybe Text -> f (Maybe Text)) -> ListDatasets -> f ListDatasets
listDatasets_datasetGroupArn = (ListDatasets -> Maybe Text)
-> (ListDatasets -> Maybe Text -> ListDatasets)
-> Lens ListDatasets ListDatasets (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasets' {Maybe Text
datasetGroupArn :: Maybe Text
$sel:datasetGroupArn:ListDatasets' :: ListDatasets -> Maybe Text
datasetGroupArn} -> Maybe Text
datasetGroupArn) (\s :: ListDatasets
s@ListDatasets' {} Maybe Text
a -> ListDatasets
s {$sel:datasetGroupArn:ListDatasets' :: Maybe Text
datasetGroupArn = Maybe Text
a} :: ListDatasets)
listDatasets_maxResults :: Lens.Lens' ListDatasets (Prelude.Maybe Prelude.Natural)
listDatasets_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListDatasets -> f ListDatasets
listDatasets_maxResults = (ListDatasets -> Maybe Natural)
-> (ListDatasets -> Maybe Natural -> ListDatasets)
-> Lens ListDatasets ListDatasets (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasets' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListDatasets' :: ListDatasets -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListDatasets
s@ListDatasets' {} Maybe Natural
a -> ListDatasets
s {$sel:maxResults:ListDatasets' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListDatasets)
instance Core.AWSPager ListDatasets where
page :: ListDatasets -> AWSResponse ListDatasets -> Maybe ListDatasets
page ListDatasets
rq AWSResponse ListDatasets
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListDatasets
ListDatasetsResponse
rs
ListDatasetsResponse
-> Getting (First Text) ListDatasetsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListDatasetsResponse -> Const (First Text) ListDatasetsResponse
Lens' ListDatasetsResponse (Maybe Text)
listDatasetsResponse_nextToken ((Maybe Text -> Const (First Text) (Maybe Text))
-> ListDatasetsResponse -> Const (First Text) ListDatasetsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListDatasetsResponse 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 ListDatasets
forall a. Maybe a
Prelude.Nothing
| Maybe [DatasetSummary] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse ListDatasets
ListDatasetsResponse
rs
ListDatasetsResponse
-> Getting
(First [DatasetSummary]) ListDatasetsResponse [DatasetSummary]
-> Maybe [DatasetSummary]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [DatasetSummary]
-> Const (First [DatasetSummary]) (Maybe [DatasetSummary]))
-> ListDatasetsResponse
-> Const (First [DatasetSummary]) ListDatasetsResponse
Lens' ListDatasetsResponse (Maybe [DatasetSummary])
listDatasetsResponse_datasets ((Maybe [DatasetSummary]
-> Const (First [DatasetSummary]) (Maybe [DatasetSummary]))
-> ListDatasetsResponse
-> Const (First [DatasetSummary]) ListDatasetsResponse)
-> (([DatasetSummary]
-> Const (First [DatasetSummary]) [DatasetSummary])
-> Maybe [DatasetSummary]
-> Const (First [DatasetSummary]) (Maybe [DatasetSummary]))
-> Getting
(First [DatasetSummary]) ListDatasetsResponse [DatasetSummary]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([DatasetSummary]
-> Const (First [DatasetSummary]) [DatasetSummary])
-> Maybe [DatasetSummary]
-> Const (First [DatasetSummary]) (Maybe [DatasetSummary])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe ListDatasets
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
ListDatasets -> Maybe ListDatasets
forall a. a -> Maybe a
Prelude.Just (ListDatasets -> Maybe ListDatasets)
-> ListDatasets -> Maybe ListDatasets
forall a b. (a -> b) -> a -> b
Prelude.$
ListDatasets
rq
ListDatasets -> (ListDatasets -> ListDatasets) -> ListDatasets
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> ListDatasets -> Identity ListDatasets
Lens ListDatasets ListDatasets (Maybe Text) (Maybe Text)
listDatasets_nextToken
((Maybe Text -> Identity (Maybe Text))
-> ListDatasets -> Identity ListDatasets)
-> Maybe Text -> ListDatasets -> ListDatasets
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListDatasets
ListDatasetsResponse
rs
ListDatasetsResponse
-> Getting (First Text) ListDatasetsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> ListDatasetsResponse -> Const (First Text) ListDatasetsResponse
Lens' ListDatasetsResponse (Maybe Text)
listDatasetsResponse_nextToken ((Maybe Text -> Const (First Text) (Maybe Text))
-> ListDatasetsResponse -> Const (First Text) ListDatasetsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) ListDatasetsResponse 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 ListDatasets where
type AWSResponse ListDatasets = ListDatasetsResponse
request :: ListDatasets -> Request ListDatasets
request = Service -> ListDatasets -> Request ListDatasets
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ListDatasets
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListDatasets)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ListDatasets))
-> Logger
-> Service
-> Proxy ListDatasets
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListDatasets)))
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 [DatasetSummary] -> Int -> ListDatasetsResponse
ListDatasetsResponse'
(Maybe Text
-> Maybe [DatasetSummary] -> Int -> ListDatasetsResponse)
-> Either String (Maybe Text)
-> Either
String (Maybe [DatasetSummary] -> Int -> ListDatasetsResponse)
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 [DatasetSummary] -> Int -> ListDatasetsResponse)
-> Either String (Maybe [DatasetSummary])
-> Either String (Int -> ListDatasetsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe [DatasetSummary]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"datasets" Either String (Maybe (Maybe [DatasetSummary]))
-> Maybe [DatasetSummary] -> Either String (Maybe [DatasetSummary])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [DatasetSummary]
forall a. Monoid a => a
Prelude.mempty)
Either String (Int -> ListDatasetsResponse)
-> Either String Int -> Either String ListDatasetsResponse
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 ListDatasets
instance Prelude.NFData ListDatasets
instance Core.ToHeaders ListDatasets where
toHeaders :: ListDatasets -> ResponseHeaders
toHeaders =
ResponseHeaders -> ListDatasets -> 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
"AmazonPersonalize.ListDatasets" ::
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 ListDatasets where
toJSON :: ListDatasets -> Value
toJSON ListDatasets' {Maybe Natural
Maybe Text
maxResults :: Maybe Natural
datasetGroupArn :: Maybe Text
nextToken :: Maybe Text
$sel:maxResults:ListDatasets' :: ListDatasets -> Maybe Natural
$sel:datasetGroupArn:ListDatasets' :: ListDatasets -> Maybe Text
$sel:nextToken:ListDatasets' :: ListDatasets -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (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
"datasetGroupArn" 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
datasetGroupArn,
(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 ListDatasets where
toPath :: ListDatasets -> ByteString
toPath = ByteString -> ListDatasets -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ListDatasets where
toQuery :: ListDatasets -> QueryString
toQuery = QueryString -> ListDatasets -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ListDatasetsResponse = ListDatasetsResponse'
{
ListDatasetsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListDatasetsResponse -> Maybe [DatasetSummary]
datasets :: Prelude.Maybe [DatasetSummary],
ListDatasetsResponse -> Int
httpStatus :: Prelude.Int
}
deriving (ListDatasetsResponse -> ListDatasetsResponse -> Bool
(ListDatasetsResponse -> ListDatasetsResponse -> Bool)
-> (ListDatasetsResponse -> ListDatasetsResponse -> Bool)
-> Eq ListDatasetsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListDatasetsResponse -> ListDatasetsResponse -> Bool
$c/= :: ListDatasetsResponse -> ListDatasetsResponse -> Bool
== :: ListDatasetsResponse -> ListDatasetsResponse -> Bool
$c== :: ListDatasetsResponse -> ListDatasetsResponse -> Bool
Prelude.Eq, ReadPrec [ListDatasetsResponse]
ReadPrec ListDatasetsResponse
Int -> ReadS ListDatasetsResponse
ReadS [ListDatasetsResponse]
(Int -> ReadS ListDatasetsResponse)
-> ReadS [ListDatasetsResponse]
-> ReadPrec ListDatasetsResponse
-> ReadPrec [ListDatasetsResponse]
-> Read ListDatasetsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListDatasetsResponse]
$creadListPrec :: ReadPrec [ListDatasetsResponse]
readPrec :: ReadPrec ListDatasetsResponse
$creadPrec :: ReadPrec ListDatasetsResponse
readList :: ReadS [ListDatasetsResponse]
$creadList :: ReadS [ListDatasetsResponse]
readsPrec :: Int -> ReadS ListDatasetsResponse
$creadsPrec :: Int -> ReadS ListDatasetsResponse
Prelude.Read, Int -> ListDatasetsResponse -> ShowS
[ListDatasetsResponse] -> ShowS
ListDatasetsResponse -> String
(Int -> ListDatasetsResponse -> ShowS)
-> (ListDatasetsResponse -> String)
-> ([ListDatasetsResponse] -> ShowS)
-> Show ListDatasetsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListDatasetsResponse] -> ShowS
$cshowList :: [ListDatasetsResponse] -> ShowS
show :: ListDatasetsResponse -> String
$cshow :: ListDatasetsResponse -> String
showsPrec :: Int -> ListDatasetsResponse -> ShowS
$cshowsPrec :: Int -> ListDatasetsResponse -> ShowS
Prelude.Show, (forall x. ListDatasetsResponse -> Rep ListDatasetsResponse x)
-> (forall x. Rep ListDatasetsResponse x -> ListDatasetsResponse)
-> Generic ListDatasetsResponse
forall x. Rep ListDatasetsResponse x -> ListDatasetsResponse
forall x. ListDatasetsResponse -> Rep ListDatasetsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListDatasetsResponse x -> ListDatasetsResponse
$cfrom :: forall x. ListDatasetsResponse -> Rep ListDatasetsResponse x
Prelude.Generic)
newListDatasetsResponse ::
Prelude.Int ->
ListDatasetsResponse
newListDatasetsResponse :: Int -> ListDatasetsResponse
newListDatasetsResponse Int
pHttpStatus_ =
ListDatasetsResponse' :: Maybe Text -> Maybe [DatasetSummary] -> Int -> ListDatasetsResponse
ListDatasetsResponse'
{ $sel:nextToken:ListDatasetsResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:datasets:ListDatasetsResponse' :: Maybe [DatasetSummary]
datasets = Maybe [DatasetSummary]
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListDatasetsResponse' :: Int
httpStatus = Int
pHttpStatus_
}
listDatasetsResponse_nextToken :: Lens.Lens' ListDatasetsResponse (Prelude.Maybe Prelude.Text)
listDatasetsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListDatasetsResponse -> f ListDatasetsResponse
listDatasetsResponse_nextToken = (ListDatasetsResponse -> Maybe Text)
-> (ListDatasetsResponse -> Maybe Text -> ListDatasetsResponse)
-> Lens' ListDatasetsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasetsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListDatasetsResponse' :: ListDatasetsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListDatasetsResponse
s@ListDatasetsResponse' {} Maybe Text
a -> ListDatasetsResponse
s {$sel:nextToken:ListDatasetsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListDatasetsResponse)
listDatasetsResponse_datasets :: Lens.Lens' ListDatasetsResponse (Prelude.Maybe [DatasetSummary])
listDatasetsResponse_datasets :: (Maybe [DatasetSummary] -> f (Maybe [DatasetSummary]))
-> ListDatasetsResponse -> f ListDatasetsResponse
listDatasetsResponse_datasets = (ListDatasetsResponse -> Maybe [DatasetSummary])
-> (ListDatasetsResponse
-> Maybe [DatasetSummary] -> ListDatasetsResponse)
-> Lens' ListDatasetsResponse (Maybe [DatasetSummary])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasetsResponse' {Maybe [DatasetSummary]
datasets :: Maybe [DatasetSummary]
$sel:datasets:ListDatasetsResponse' :: ListDatasetsResponse -> Maybe [DatasetSummary]
datasets} -> Maybe [DatasetSummary]
datasets) (\s :: ListDatasetsResponse
s@ListDatasetsResponse' {} Maybe [DatasetSummary]
a -> ListDatasetsResponse
s {$sel:datasets:ListDatasetsResponse' :: Maybe [DatasetSummary]
datasets = Maybe [DatasetSummary]
a} :: ListDatasetsResponse) ((Maybe [DatasetSummary] -> f (Maybe [DatasetSummary]))
-> ListDatasetsResponse -> f ListDatasetsResponse)
-> ((Maybe [DatasetSummary] -> f (Maybe [DatasetSummary]))
-> Maybe [DatasetSummary] -> f (Maybe [DatasetSummary]))
-> (Maybe [DatasetSummary] -> f (Maybe [DatasetSummary]))
-> ListDatasetsResponse
-> f ListDatasetsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[DatasetSummary] [DatasetSummary] [DatasetSummary] [DatasetSummary]
-> Iso
(Maybe [DatasetSummary])
(Maybe [DatasetSummary])
(Maybe [DatasetSummary])
(Maybe [DatasetSummary])
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
[DatasetSummary] [DatasetSummary] [DatasetSummary] [DatasetSummary]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
listDatasetsResponse_httpStatus :: Lens.Lens' ListDatasetsResponse Prelude.Int
listDatasetsResponse_httpStatus :: (Int -> f Int) -> ListDatasetsResponse -> f ListDatasetsResponse
listDatasetsResponse_httpStatus = (ListDatasetsResponse -> Int)
-> (ListDatasetsResponse -> Int -> ListDatasetsResponse)
-> Lens ListDatasetsResponse ListDatasetsResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListDatasetsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListDatasetsResponse' :: ListDatasetsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListDatasetsResponse
s@ListDatasetsResponse' {} Int
a -> ListDatasetsResponse
s {$sel:httpStatus:ListDatasetsResponse' :: Int
httpStatus = Int
a} :: ListDatasetsResponse)
instance Prelude.NFData ListDatasetsResponse