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