{-# 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.EKS.ListClusters
-- 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 Amazon EKS clusters in your Amazon Web Services account in the
-- specified Region.
--
-- This operation returns paginated results.
module Amazonka.EKS.ListClusters
  ( -- * Creating a Request
    ListClusters (..),
    newListClusters,

    -- * Request Lenses
    listClusters_include,
    listClusters_maxResults,
    listClusters_nextToken,

    -- * Destructuring the Response
    ListClustersResponse (..),
    newListClustersResponse,

    -- * Response Lenses
    listClustersResponse_clusters,
    listClustersResponse_nextToken,
    listClustersResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.EKS.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newListClusters' smart constructor.
data ListClusters = ListClusters'
  { -- | Indicates whether external clusters are included in the returned list.
    -- Use \'@all@\' to return connected clusters, or blank to return only
    -- Amazon EKS clusters. \'@all@\' must be in lowercase otherwise an error
    -- occurs.
    ListClusters -> Maybe [Text]
include :: Prelude.Maybe [Prelude.Text],
    -- | The maximum number of cluster results returned by @ListClusters@ in
    -- paginated output. When you use this parameter, @ListClusters@ returns
    -- only @maxResults@ results in a single page along with a @nextToken@
    -- response element. You can see the remaining results of the initial
    -- request by sending another @ListClusters@ request with the returned
    -- @nextToken@ value. This value can be between 1 and 100. If you don\'t
    -- use this parameter, @ListClusters@ returns up to 100 results and a
    -- @nextToken@ value if applicable.
    ListClusters -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | The @nextToken@ value returned from a previous paginated @ListClusters@
    -- request where @maxResults@ was used and the results exceeded the value
    -- of that parameter. Pagination continues from the end of the previous
    -- results that returned the @nextToken@ value.
    --
    -- This token should be treated as an opaque identifier that is used only
    -- to retrieve the next items in a list and not for other programmatic
    -- purposes.
    ListClusters -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text
  }
  deriving (ListClusters -> ListClusters -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListClusters -> ListClusters -> Bool
$c/= :: ListClusters -> ListClusters -> Bool
== :: ListClusters -> ListClusters -> Bool
$c== :: ListClusters -> ListClusters -> Bool
Prelude.Eq, ReadPrec [ListClusters]
ReadPrec ListClusters
Int -> ReadS ListClusters
ReadS [ListClusters]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListClusters]
$creadListPrec :: ReadPrec [ListClusters]
readPrec :: ReadPrec ListClusters
$creadPrec :: ReadPrec ListClusters
readList :: ReadS [ListClusters]
$creadList :: ReadS [ListClusters]
readsPrec :: Int -> ReadS ListClusters
$creadsPrec :: Int -> ReadS ListClusters
Prelude.Read, Int -> ListClusters -> ShowS
[ListClusters] -> ShowS
ListClusters -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListClusters] -> ShowS
$cshowList :: [ListClusters] -> ShowS
show :: ListClusters -> String
$cshow :: ListClusters -> String
showsPrec :: Int -> ListClusters -> ShowS
$cshowsPrec :: Int -> ListClusters -> ShowS
Prelude.Show, forall x. Rep ListClusters x -> ListClusters
forall x. ListClusters -> Rep ListClusters x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListClusters x -> ListClusters
$cfrom :: forall x. ListClusters -> Rep ListClusters x
Prelude.Generic)

-- |
-- Create a value of 'ListClusters' 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:
--
-- 'include', 'listClusters_include' - Indicates whether external clusters are included in the returned list.
-- Use \'@all@\' to return connected clusters, or blank to return only
-- Amazon EKS clusters. \'@all@\' must be in lowercase otherwise an error
-- occurs.
--
-- 'maxResults', 'listClusters_maxResults' - The maximum number of cluster results returned by @ListClusters@ in
-- paginated output. When you use this parameter, @ListClusters@ returns
-- only @maxResults@ results in a single page along with a @nextToken@
-- response element. You can see the remaining results of the initial
-- request by sending another @ListClusters@ request with the returned
-- @nextToken@ value. This value can be between 1 and 100. If you don\'t
-- use this parameter, @ListClusters@ returns up to 100 results and a
-- @nextToken@ value if applicable.
--
-- 'nextToken', 'listClusters_nextToken' - The @nextToken@ value returned from a previous paginated @ListClusters@
-- request where @maxResults@ was used and the results exceeded the value
-- of that parameter. Pagination continues from the end of the previous
-- results that returned the @nextToken@ value.
--
-- This token should be treated as an opaque identifier that is used only
-- to retrieve the next items in a list and not for other programmatic
-- purposes.
newListClusters ::
  ListClusters
newListClusters :: ListClusters
newListClusters =
  ListClusters'
    { $sel:include:ListClusters' :: Maybe [Text]
include = forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:ListClusters' :: Maybe Natural
maxResults = forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListClusters' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing
    }

-- | Indicates whether external clusters are included in the returned list.
-- Use \'@all@\' to return connected clusters, or blank to return only
-- Amazon EKS clusters. \'@all@\' must be in lowercase otherwise an error
-- occurs.
listClusters_include :: Lens.Lens' ListClusters (Prelude.Maybe [Prelude.Text])
listClusters_include :: Lens' ListClusters (Maybe [Text])
listClusters_include = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListClusters' {Maybe [Text]
include :: Maybe [Text]
$sel:include:ListClusters' :: ListClusters -> Maybe [Text]
include} -> Maybe [Text]
include) (\s :: ListClusters
s@ListClusters' {} Maybe [Text]
a -> ListClusters
s {$sel:include:ListClusters' :: Maybe [Text]
include = Maybe [Text]
a} :: ListClusters) 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 maximum number of cluster results returned by @ListClusters@ in
-- paginated output. When you use this parameter, @ListClusters@ returns
-- only @maxResults@ results in a single page along with a @nextToken@
-- response element. You can see the remaining results of the initial
-- request by sending another @ListClusters@ request with the returned
-- @nextToken@ value. This value can be between 1 and 100. If you don\'t
-- use this parameter, @ListClusters@ returns up to 100 results and a
-- @nextToken@ value if applicable.
listClusters_maxResults :: Lens.Lens' ListClusters (Prelude.Maybe Prelude.Natural)
listClusters_maxResults :: Lens' ListClusters (Maybe Natural)
listClusters_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListClusters' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListClusters' :: ListClusters -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListClusters
s@ListClusters' {} Maybe Natural
a -> ListClusters
s {$sel:maxResults:ListClusters' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListClusters)

-- | The @nextToken@ value returned from a previous paginated @ListClusters@
-- request where @maxResults@ was used and the results exceeded the value
-- of that parameter. Pagination continues from the end of the previous
-- results that returned the @nextToken@ value.
--
-- This token should be treated as an opaque identifier that is used only
-- to retrieve the next items in a list and not for other programmatic
-- purposes.
listClusters_nextToken :: Lens.Lens' ListClusters (Prelude.Maybe Prelude.Text)
listClusters_nextToken :: Lens' ListClusters (Maybe Text)
listClusters_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListClusters' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListClusters' :: ListClusters -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListClusters
s@ListClusters' {} Maybe Text
a -> ListClusters
s {$sel:nextToken:ListClusters' :: Maybe Text
nextToken = Maybe Text
a} :: ListClusters)

instance Core.AWSPager ListClusters where
  page :: ListClusters -> AWSResponse ListClusters -> Maybe ListClusters
page ListClusters
rq AWSResponse ListClusters
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListClusters
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListClustersResponse (Maybe Text)
listClustersResponse_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 ListClusters
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListClustersResponse (Maybe [Text])
listClustersResponse_clusters
            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.$ ListClusters
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListClusters (Maybe Text)
listClusters_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListClusters
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListClustersResponse (Maybe Text)
listClustersResponse_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 ListClusters where
  type AWSResponse ListClusters = ListClustersResponse
  request :: (Service -> Service) -> ListClusters -> Request ListClusters
request Service -> Service
overrides =
    forall a. ToRequest a => Service -> a -> Request a
Request.get (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListClusters
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListClusters)))
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 Text -> Int -> ListClustersResponse
ListClustersResponse'
            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
"clusters" 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.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"nextToken")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

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

instance Prelude.NFData ListClusters where
  rnf :: ListClusters -> ()
rnf ListClusters' {Maybe Natural
Maybe [Text]
Maybe Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
include :: Maybe [Text]
$sel:nextToken:ListClusters' :: ListClusters -> Maybe Text
$sel:maxResults:ListClusters' :: ListClusters -> Maybe Natural
$sel:include:ListClusters' :: ListClusters -> Maybe [Text]
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
include
      seq :: forall a b. a -> b -> b
`Prelude.seq` 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

instance Data.ToHeaders ListClusters where
  toHeaders :: ListClusters -> ResponseHeaders
toHeaders =
    forall a b. a -> b -> a
Prelude.const
      ( forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

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

instance Data.ToQuery ListClusters where
  toQuery :: ListClusters -> QueryString
toQuery ListClusters' {Maybe Natural
Maybe [Text]
Maybe Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
include :: Maybe [Text]
$sel:nextToken:ListClusters' :: ListClusters -> Maybe Text
$sel:maxResults:ListClusters' :: ListClusters -> Maybe Natural
$sel:include:ListClusters' :: ListClusters -> Maybe [Text]
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"include"
          forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: forall a. ToQuery a => a -> QueryString
Data.toQuery
            (forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Data.toQueryList ByteString
"member" forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
include),
        ByteString
"maxResults" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Natural
maxResults,
        ByteString
"nextToken" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Text
nextToken
      ]

-- | /See:/ 'newListClustersResponse' smart constructor.
data ListClustersResponse = ListClustersResponse'
  { -- | A list of all of the clusters for your account in the specified Region.
    ListClustersResponse -> Maybe [Text]
clusters :: Prelude.Maybe [Prelude.Text],
    -- | The @nextToken@ value to include in a future @ListClusters@ request.
    -- When the results of a @ListClusters@ request exceed @maxResults@, you
    -- can use this value to retrieve the next page of results. This value is
    -- @null@ when there are no more results to return.
    ListClustersResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListClustersResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListClustersResponse -> ListClustersResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListClustersResponse -> ListClustersResponse -> Bool
$c/= :: ListClustersResponse -> ListClustersResponse -> Bool
== :: ListClustersResponse -> ListClustersResponse -> Bool
$c== :: ListClustersResponse -> ListClustersResponse -> Bool
Prelude.Eq, ReadPrec [ListClustersResponse]
ReadPrec ListClustersResponse
Int -> ReadS ListClustersResponse
ReadS [ListClustersResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListClustersResponse]
$creadListPrec :: ReadPrec [ListClustersResponse]
readPrec :: ReadPrec ListClustersResponse
$creadPrec :: ReadPrec ListClustersResponse
readList :: ReadS [ListClustersResponse]
$creadList :: ReadS [ListClustersResponse]
readsPrec :: Int -> ReadS ListClustersResponse
$creadsPrec :: Int -> ReadS ListClustersResponse
Prelude.Read, Int -> ListClustersResponse -> ShowS
[ListClustersResponse] -> ShowS
ListClustersResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListClustersResponse] -> ShowS
$cshowList :: [ListClustersResponse] -> ShowS
show :: ListClustersResponse -> String
$cshow :: ListClustersResponse -> String
showsPrec :: Int -> ListClustersResponse -> ShowS
$cshowsPrec :: Int -> ListClustersResponse -> ShowS
Prelude.Show, forall x. Rep ListClustersResponse x -> ListClustersResponse
forall x. ListClustersResponse -> Rep ListClustersResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListClustersResponse x -> ListClustersResponse
$cfrom :: forall x. ListClustersResponse -> Rep ListClustersResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListClustersResponse' 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:
--
-- 'clusters', 'listClustersResponse_clusters' - A list of all of the clusters for your account in the specified Region.
--
-- 'nextToken', 'listClustersResponse_nextToken' - The @nextToken@ value to include in a future @ListClusters@ request.
-- When the results of a @ListClusters@ request exceed @maxResults@, you
-- can use this value to retrieve the next page of results. This value is
-- @null@ when there are no more results to return.
--
-- 'httpStatus', 'listClustersResponse_httpStatus' - The response's http status code.
newListClustersResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListClustersResponse
newListClustersResponse :: Int -> ListClustersResponse
newListClustersResponse Int
pHttpStatus_ =
  ListClustersResponse'
    { $sel:clusters:ListClustersResponse' :: Maybe [Text]
clusters = forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListClustersResponse' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListClustersResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A list of all of the clusters for your account in the specified Region.
listClustersResponse_clusters :: Lens.Lens' ListClustersResponse (Prelude.Maybe [Prelude.Text])
listClustersResponse_clusters :: Lens' ListClustersResponse (Maybe [Text])
listClustersResponse_clusters = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListClustersResponse' {Maybe [Text]
clusters :: Maybe [Text]
$sel:clusters:ListClustersResponse' :: ListClustersResponse -> Maybe [Text]
clusters} -> Maybe [Text]
clusters) (\s :: ListClustersResponse
s@ListClustersResponse' {} Maybe [Text]
a -> ListClustersResponse
s {$sel:clusters:ListClustersResponse' :: Maybe [Text]
clusters = Maybe [Text]
a} :: ListClustersResponse) 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 @nextToken@ value to include in a future @ListClusters@ request.
-- When the results of a @ListClusters@ request exceed @maxResults@, you
-- can use this value to retrieve the next page of results. This value is
-- @null@ when there are no more results to return.
listClustersResponse_nextToken :: Lens.Lens' ListClustersResponse (Prelude.Maybe Prelude.Text)
listClustersResponse_nextToken :: Lens' ListClustersResponse (Maybe Text)
listClustersResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListClustersResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListClustersResponse' :: ListClustersResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListClustersResponse
s@ListClustersResponse' {} Maybe Text
a -> ListClustersResponse
s {$sel:nextToken:ListClustersResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListClustersResponse)

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

instance Prelude.NFData ListClustersResponse where
  rnf :: ListClustersResponse -> ()
rnf ListClustersResponse' {Int
Maybe [Text]
Maybe Text
httpStatus :: Int
nextToken :: Maybe Text
clusters :: Maybe [Text]
$sel:httpStatus:ListClustersResponse' :: ListClustersResponse -> Int
$sel:nextToken:ListClustersResponse' :: ListClustersResponse -> Maybe Text
$sel:clusters:ListClustersResponse' :: ListClustersResponse -> Maybe [Text]
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
clusters
      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 Int
httpStatus