{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.ServiceQuotas.ListAWSDefaultServiceQuotas
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Lists the default values for the quotas for the specified AWS service. A
-- default value does not reflect any quota increases.
--
-- This operation returns paginated results.
module Amazonka.ServiceQuotas.ListAWSDefaultServiceQuotas
  ( -- * Creating a Request
    ListAWSDefaultServiceQuotas (..),
    newListAWSDefaultServiceQuotas,

    -- * Request Lenses
    listAWSDefaultServiceQuotas_maxResults,
    listAWSDefaultServiceQuotas_nextToken,
    listAWSDefaultServiceQuotas_serviceCode,

    -- * Destructuring the Response
    ListAWSDefaultServiceQuotasResponse (..),
    newListAWSDefaultServiceQuotasResponse,

    -- * Response Lenses
    listAWSDefaultServiceQuotasResponse_nextToken,
    listAWSDefaultServiceQuotasResponse_quotas,
    listAWSDefaultServiceQuotasResponse_httpStatus,
  )
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.ServiceQuotas.Types

-- | /See:/ 'newListAWSDefaultServiceQuotas' smart constructor.
data ListAWSDefaultServiceQuotas = ListAWSDefaultServiceQuotas'
  { -- | The maximum number of results to return with a single call. To retrieve
    -- the remaining results, if any, make another call with the token returned
    -- from this call.
    ListAWSDefaultServiceQuotas -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | The token for the next page of results.
    ListAWSDefaultServiceQuotas -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The service identifier.
    ListAWSDefaultServiceQuotas -> Text
serviceCode :: Prelude.Text
  }
  deriving (ListAWSDefaultServiceQuotas -> ListAWSDefaultServiceQuotas -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAWSDefaultServiceQuotas -> ListAWSDefaultServiceQuotas -> Bool
$c/= :: ListAWSDefaultServiceQuotas -> ListAWSDefaultServiceQuotas -> Bool
== :: ListAWSDefaultServiceQuotas -> ListAWSDefaultServiceQuotas -> Bool
$c== :: ListAWSDefaultServiceQuotas -> ListAWSDefaultServiceQuotas -> Bool
Prelude.Eq, ReadPrec [ListAWSDefaultServiceQuotas]
ReadPrec ListAWSDefaultServiceQuotas
Int -> ReadS ListAWSDefaultServiceQuotas
ReadS [ListAWSDefaultServiceQuotas]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAWSDefaultServiceQuotas]
$creadListPrec :: ReadPrec [ListAWSDefaultServiceQuotas]
readPrec :: ReadPrec ListAWSDefaultServiceQuotas
$creadPrec :: ReadPrec ListAWSDefaultServiceQuotas
readList :: ReadS [ListAWSDefaultServiceQuotas]
$creadList :: ReadS [ListAWSDefaultServiceQuotas]
readsPrec :: Int -> ReadS ListAWSDefaultServiceQuotas
$creadsPrec :: Int -> ReadS ListAWSDefaultServiceQuotas
Prelude.Read, Int -> ListAWSDefaultServiceQuotas -> ShowS
[ListAWSDefaultServiceQuotas] -> ShowS
ListAWSDefaultServiceQuotas -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAWSDefaultServiceQuotas] -> ShowS
$cshowList :: [ListAWSDefaultServiceQuotas] -> ShowS
show :: ListAWSDefaultServiceQuotas -> String
$cshow :: ListAWSDefaultServiceQuotas -> String
showsPrec :: Int -> ListAWSDefaultServiceQuotas -> ShowS
$cshowsPrec :: Int -> ListAWSDefaultServiceQuotas -> ShowS
Prelude.Show, forall x.
Rep ListAWSDefaultServiceQuotas x -> ListAWSDefaultServiceQuotas
forall x.
ListAWSDefaultServiceQuotas -> Rep ListAWSDefaultServiceQuotas x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListAWSDefaultServiceQuotas x -> ListAWSDefaultServiceQuotas
$cfrom :: forall x.
ListAWSDefaultServiceQuotas -> Rep ListAWSDefaultServiceQuotas x
Prelude.Generic)

-- |
-- Create a value of 'ListAWSDefaultServiceQuotas' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'maxResults', 'listAWSDefaultServiceQuotas_maxResults' - The maximum number of results to return with a single call. To retrieve
-- the remaining results, if any, make another call with the token returned
-- from this call.
--
-- 'nextToken', 'listAWSDefaultServiceQuotas_nextToken' - The token for the next page of results.
--
-- 'serviceCode', 'listAWSDefaultServiceQuotas_serviceCode' - The service identifier.
newListAWSDefaultServiceQuotas ::
  -- | 'serviceCode'
  Prelude.Text ->
  ListAWSDefaultServiceQuotas
newListAWSDefaultServiceQuotas :: Text -> ListAWSDefaultServiceQuotas
newListAWSDefaultServiceQuotas Text
pServiceCode_ =
  ListAWSDefaultServiceQuotas'
    { $sel:maxResults:ListAWSDefaultServiceQuotas' :: Maybe Natural
maxResults =
        forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListAWSDefaultServiceQuotas' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:serviceCode:ListAWSDefaultServiceQuotas' :: Text
serviceCode = Text
pServiceCode_
    }

-- | The maximum number of results to return with a single call. To retrieve
-- the remaining results, if any, make another call with the token returned
-- from this call.
listAWSDefaultServiceQuotas_maxResults :: Lens.Lens' ListAWSDefaultServiceQuotas (Prelude.Maybe Prelude.Natural)
listAWSDefaultServiceQuotas_maxResults :: Lens' ListAWSDefaultServiceQuotas (Maybe Natural)
listAWSDefaultServiceQuotas_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotas' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListAWSDefaultServiceQuotas
s@ListAWSDefaultServiceQuotas' {} Maybe Natural
a -> ListAWSDefaultServiceQuotas
s {$sel:maxResults:ListAWSDefaultServiceQuotas' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListAWSDefaultServiceQuotas)

-- | The token for the next page of results.
listAWSDefaultServiceQuotas_nextToken :: Lens.Lens' ListAWSDefaultServiceQuotas (Prelude.Maybe Prelude.Text)
listAWSDefaultServiceQuotas_nextToken :: Lens' ListAWSDefaultServiceQuotas (Maybe Text)
listAWSDefaultServiceQuotas_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotas' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAWSDefaultServiceQuotas
s@ListAWSDefaultServiceQuotas' {} Maybe Text
a -> ListAWSDefaultServiceQuotas
s {$sel:nextToken:ListAWSDefaultServiceQuotas' :: Maybe Text
nextToken = Maybe Text
a} :: ListAWSDefaultServiceQuotas)

-- | The service identifier.
listAWSDefaultServiceQuotas_serviceCode :: Lens.Lens' ListAWSDefaultServiceQuotas Prelude.Text
listAWSDefaultServiceQuotas_serviceCode :: Lens' ListAWSDefaultServiceQuotas Text
listAWSDefaultServiceQuotas_serviceCode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotas' {Text
serviceCode :: Text
$sel:serviceCode:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Text
serviceCode} -> Text
serviceCode) (\s :: ListAWSDefaultServiceQuotas
s@ListAWSDefaultServiceQuotas' {} Text
a -> ListAWSDefaultServiceQuotas
s {$sel:serviceCode:ListAWSDefaultServiceQuotas' :: Text
serviceCode = Text
a} :: ListAWSDefaultServiceQuotas)

instance Core.AWSPager ListAWSDefaultServiceQuotas where
  page :: ListAWSDefaultServiceQuotas
-> AWSResponse ListAWSDefaultServiceQuotas
-> Maybe ListAWSDefaultServiceQuotas
page ListAWSDefaultServiceQuotas
rq AWSResponse ListAWSDefaultServiceQuotas
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListAWSDefaultServiceQuotas
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAWSDefaultServiceQuotasResponse (Maybe Text)
listAWSDefaultServiceQuotasResponse_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 ListAWSDefaultServiceQuotas
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAWSDefaultServiceQuotasResponse (Maybe [ServiceQuota])
listAWSDefaultServiceQuotasResponse_quotas
            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
    | Bool
Prelude.otherwise =
        forall a. a -> Maybe a
Prelude.Just
          forall a b. (a -> b) -> a -> b
Prelude.$ ListAWSDefaultServiceQuotas
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListAWSDefaultServiceQuotas (Maybe Text)
listAWSDefaultServiceQuotas_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListAWSDefaultServiceQuotas
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAWSDefaultServiceQuotasResponse (Maybe Text)
listAWSDefaultServiceQuotasResponse_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 ListAWSDefaultServiceQuotas where
  type
    AWSResponse ListAWSDefaultServiceQuotas =
      ListAWSDefaultServiceQuotasResponse
  request :: (Service -> Service)
-> ListAWSDefaultServiceQuotas
-> Request ListAWSDefaultServiceQuotas
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 ListAWSDefaultServiceQuotas
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListAWSDefaultServiceQuotas)))
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
-> Maybe [ServiceQuota]
-> Int
-> ListAWSDefaultServiceQuotasResponse
ListAWSDefaultServiceQuotasResponse'
            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.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"Quotas" forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty)
            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))
      )

instance Prelude.Hashable ListAWSDefaultServiceQuotas where
  hashWithSalt :: Int -> ListAWSDefaultServiceQuotas -> Int
hashWithSalt Int
_salt ListAWSDefaultServiceQuotas' {Maybe Natural
Maybe Text
Text
serviceCode :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:serviceCode:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Text
$sel:nextToken:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Text
$sel:maxResults:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Natural
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxResults
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextToken
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
serviceCode

instance Prelude.NFData ListAWSDefaultServiceQuotas where
  rnf :: ListAWSDefaultServiceQuotas -> ()
rnf ListAWSDefaultServiceQuotas' {Maybe Natural
Maybe Text
Text
serviceCode :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:serviceCode:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Text
$sel:nextToken:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Text
$sel:maxResults:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Natural
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxResults
      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 Text
serviceCode

instance Data.ToHeaders ListAWSDefaultServiceQuotas where
  toHeaders :: ListAWSDefaultServiceQuotas -> 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
"ServiceQuotasV20190624.ListAWSDefaultServiceQuotas" ::
                          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 ListAWSDefaultServiceQuotas where
  toJSON :: ListAWSDefaultServiceQuotas -> Value
toJSON ListAWSDefaultServiceQuotas' {Maybe Natural
Maybe Text
Text
serviceCode :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:serviceCode:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Text
$sel:nextToken:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Text
$sel:maxResults:ListAWSDefaultServiceQuotas' :: ListAWSDefaultServiceQuotas -> Maybe Natural
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (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 Natural
maxResults,
            (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,
            forall a. a -> Maybe a
Prelude.Just (Key
"ServiceCode" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
serviceCode)
          ]
      )

instance Data.ToPath ListAWSDefaultServiceQuotas where
  toPath :: ListAWSDefaultServiceQuotas -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"

instance Data.ToQuery ListAWSDefaultServiceQuotas where
  toQuery :: ListAWSDefaultServiceQuotas -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newListAWSDefaultServiceQuotasResponse' smart constructor.
data ListAWSDefaultServiceQuotasResponse = ListAWSDefaultServiceQuotasResponse'
  { -- | The token to use to retrieve the next page of results. This value is
    -- null when there are no more results to return.
    ListAWSDefaultServiceQuotasResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | Information about the quotas.
    ListAWSDefaultServiceQuotasResponse -> Maybe [ServiceQuota]
quotas :: Prelude.Maybe [ServiceQuota],
    -- | The response's http status code.
    ListAWSDefaultServiceQuotasResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListAWSDefaultServiceQuotasResponse
-> ListAWSDefaultServiceQuotasResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAWSDefaultServiceQuotasResponse
-> ListAWSDefaultServiceQuotasResponse -> Bool
$c/= :: ListAWSDefaultServiceQuotasResponse
-> ListAWSDefaultServiceQuotasResponse -> Bool
== :: ListAWSDefaultServiceQuotasResponse
-> ListAWSDefaultServiceQuotasResponse -> Bool
$c== :: ListAWSDefaultServiceQuotasResponse
-> ListAWSDefaultServiceQuotasResponse -> Bool
Prelude.Eq, ReadPrec [ListAWSDefaultServiceQuotasResponse]
ReadPrec ListAWSDefaultServiceQuotasResponse
Int -> ReadS ListAWSDefaultServiceQuotasResponse
ReadS [ListAWSDefaultServiceQuotasResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAWSDefaultServiceQuotasResponse]
$creadListPrec :: ReadPrec [ListAWSDefaultServiceQuotasResponse]
readPrec :: ReadPrec ListAWSDefaultServiceQuotasResponse
$creadPrec :: ReadPrec ListAWSDefaultServiceQuotasResponse
readList :: ReadS [ListAWSDefaultServiceQuotasResponse]
$creadList :: ReadS [ListAWSDefaultServiceQuotasResponse]
readsPrec :: Int -> ReadS ListAWSDefaultServiceQuotasResponse
$creadsPrec :: Int -> ReadS ListAWSDefaultServiceQuotasResponse
Prelude.Read, Int -> ListAWSDefaultServiceQuotasResponse -> ShowS
[ListAWSDefaultServiceQuotasResponse] -> ShowS
ListAWSDefaultServiceQuotasResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAWSDefaultServiceQuotasResponse] -> ShowS
$cshowList :: [ListAWSDefaultServiceQuotasResponse] -> ShowS
show :: ListAWSDefaultServiceQuotasResponse -> String
$cshow :: ListAWSDefaultServiceQuotasResponse -> String
showsPrec :: Int -> ListAWSDefaultServiceQuotasResponse -> ShowS
$cshowsPrec :: Int -> ListAWSDefaultServiceQuotasResponse -> ShowS
Prelude.Show, forall x.
Rep ListAWSDefaultServiceQuotasResponse x
-> ListAWSDefaultServiceQuotasResponse
forall x.
ListAWSDefaultServiceQuotasResponse
-> Rep ListAWSDefaultServiceQuotasResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListAWSDefaultServiceQuotasResponse x
-> ListAWSDefaultServiceQuotasResponse
$cfrom :: forall x.
ListAWSDefaultServiceQuotasResponse
-> Rep ListAWSDefaultServiceQuotasResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListAWSDefaultServiceQuotasResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'nextToken', 'listAWSDefaultServiceQuotasResponse_nextToken' - The token to use to retrieve the next page of results. This value is
-- null when there are no more results to return.
--
-- 'quotas', 'listAWSDefaultServiceQuotasResponse_quotas' - Information about the quotas.
--
-- 'httpStatus', 'listAWSDefaultServiceQuotasResponse_httpStatus' - The response's http status code.
newListAWSDefaultServiceQuotasResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListAWSDefaultServiceQuotasResponse
newListAWSDefaultServiceQuotasResponse :: Int -> ListAWSDefaultServiceQuotasResponse
newListAWSDefaultServiceQuotasResponse Int
pHttpStatus_ =
  ListAWSDefaultServiceQuotasResponse'
    { $sel:nextToken:ListAWSDefaultServiceQuotasResponse' :: Maybe Text
nextToken =
        forall a. Maybe a
Prelude.Nothing,
      $sel:quotas:ListAWSDefaultServiceQuotasResponse' :: Maybe [ServiceQuota]
quotas = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListAWSDefaultServiceQuotasResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The token to use to retrieve the next page of results. This value is
-- null when there are no more results to return.
listAWSDefaultServiceQuotasResponse_nextToken :: Lens.Lens' ListAWSDefaultServiceQuotasResponse (Prelude.Maybe Prelude.Text)
listAWSDefaultServiceQuotasResponse_nextToken :: Lens' ListAWSDefaultServiceQuotasResponse (Maybe Text)
listAWSDefaultServiceQuotasResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotasResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAWSDefaultServiceQuotasResponse
s@ListAWSDefaultServiceQuotasResponse' {} Maybe Text
a -> ListAWSDefaultServiceQuotasResponse
s {$sel:nextToken:ListAWSDefaultServiceQuotasResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListAWSDefaultServiceQuotasResponse)

-- | Information about the quotas.
listAWSDefaultServiceQuotasResponse_quotas :: Lens.Lens' ListAWSDefaultServiceQuotasResponse (Prelude.Maybe [ServiceQuota])
listAWSDefaultServiceQuotasResponse_quotas :: Lens' ListAWSDefaultServiceQuotasResponse (Maybe [ServiceQuota])
listAWSDefaultServiceQuotasResponse_quotas = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotasResponse' {Maybe [ServiceQuota]
quotas :: Maybe [ServiceQuota]
$sel:quotas:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> Maybe [ServiceQuota]
quotas} -> Maybe [ServiceQuota]
quotas) (\s :: ListAWSDefaultServiceQuotasResponse
s@ListAWSDefaultServiceQuotasResponse' {} Maybe [ServiceQuota]
a -> ListAWSDefaultServiceQuotasResponse
s {$sel:quotas:ListAWSDefaultServiceQuotasResponse' :: Maybe [ServiceQuota]
quotas = Maybe [ServiceQuota]
a} :: ListAWSDefaultServiceQuotasResponse) 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 s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The response's http status code.
listAWSDefaultServiceQuotasResponse_httpStatus :: Lens.Lens' ListAWSDefaultServiceQuotasResponse Prelude.Int
listAWSDefaultServiceQuotasResponse_httpStatus :: Lens' ListAWSDefaultServiceQuotasResponse Int
listAWSDefaultServiceQuotasResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAWSDefaultServiceQuotasResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListAWSDefaultServiceQuotasResponse
s@ListAWSDefaultServiceQuotasResponse' {} Int
a -> ListAWSDefaultServiceQuotasResponse
s {$sel:httpStatus:ListAWSDefaultServiceQuotasResponse' :: Int
httpStatus = Int
a} :: ListAWSDefaultServiceQuotasResponse)

instance
  Prelude.NFData
    ListAWSDefaultServiceQuotasResponse
  where
  rnf :: ListAWSDefaultServiceQuotasResponse -> ()
rnf ListAWSDefaultServiceQuotasResponse' {Int
Maybe [ServiceQuota]
Maybe Text
httpStatus :: Int
quotas :: Maybe [ServiceQuota]
nextToken :: Maybe Text
$sel:httpStatus:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> Int
$sel:quotas:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> Maybe [ServiceQuota]
$sel:nextToken:ListAWSDefaultServiceQuotasResponse' :: ListAWSDefaultServiceQuotasResponse -> 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 Maybe [ServiceQuota]
quotas
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus