{-# 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.MigrationHubReFactorSpaces.ListEnvironmentVpcs
-- 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 all Amazon Web Services Migration Hub Refactor Spaces service
-- virtual private clouds (VPCs) that are part of the environment.
--
-- This operation returns paginated results.
module Amazonka.MigrationHubReFactorSpaces.ListEnvironmentVpcs
  ( -- * Creating a Request
    ListEnvironmentVpcs (..),
    newListEnvironmentVpcs,

    -- * Request Lenses
    listEnvironmentVpcs_maxResults,
    listEnvironmentVpcs_nextToken,
    listEnvironmentVpcs_environmentIdentifier,

    -- * Destructuring the Response
    ListEnvironmentVpcsResponse (..),
    newListEnvironmentVpcsResponse,

    -- * Response Lenses
    listEnvironmentVpcsResponse_environmentVpcList,
    listEnvironmentVpcsResponse_nextToken,
    listEnvironmentVpcsResponse_httpStatus,
  )
where

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

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

-- |
-- Create a value of 'ListEnvironmentVpcs' 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', 'listEnvironmentVpcs_maxResults' - The maximum number of results to return with a single call. To retrieve
-- the remaining results, make another call with the returned @nextToken@
-- value.
--
-- 'nextToken', 'listEnvironmentVpcs_nextToken' - The token for the next page of results.
--
-- 'environmentIdentifier', 'listEnvironmentVpcs_environmentIdentifier' - The ID of the environment.
newListEnvironmentVpcs ::
  -- | 'environmentIdentifier'
  Prelude.Text ->
  ListEnvironmentVpcs
newListEnvironmentVpcs :: Text -> ListEnvironmentVpcs
newListEnvironmentVpcs Text
pEnvironmentIdentifier_ =
  ListEnvironmentVpcs'
    { $sel:maxResults:ListEnvironmentVpcs' :: Maybe Natural
maxResults = forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListEnvironmentVpcs' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:environmentIdentifier:ListEnvironmentVpcs' :: Text
environmentIdentifier = Text
pEnvironmentIdentifier_
    }

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

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

-- | The ID of the environment.
listEnvironmentVpcs_environmentIdentifier :: Lens.Lens' ListEnvironmentVpcs Prelude.Text
listEnvironmentVpcs_environmentIdentifier :: Lens' ListEnvironmentVpcs Text
listEnvironmentVpcs_environmentIdentifier = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListEnvironmentVpcs' {Text
environmentIdentifier :: Text
$sel:environmentIdentifier:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Text
environmentIdentifier} -> Text
environmentIdentifier) (\s :: ListEnvironmentVpcs
s@ListEnvironmentVpcs' {} Text
a -> ListEnvironmentVpcs
s {$sel:environmentIdentifier:ListEnvironmentVpcs' :: Text
environmentIdentifier = Text
a} :: ListEnvironmentVpcs)

instance Core.AWSPager ListEnvironmentVpcs where
  page :: ListEnvironmentVpcs
-> AWSResponse ListEnvironmentVpcs -> Maybe ListEnvironmentVpcs
page ListEnvironmentVpcs
rq AWSResponse ListEnvironmentVpcs
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListEnvironmentVpcs
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListEnvironmentVpcsResponse (Maybe Text)
listEnvironmentVpcsResponse_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 ListEnvironmentVpcs
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListEnvironmentVpcsResponse (Maybe [EnvironmentVpc])
listEnvironmentVpcsResponse_environmentVpcList
            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.$ ListEnvironmentVpcs
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListEnvironmentVpcs (Maybe Text)
listEnvironmentVpcs_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListEnvironmentVpcs
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListEnvironmentVpcsResponse (Maybe Text)
listEnvironmentVpcsResponse_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 ListEnvironmentVpcs where
  type
    AWSResponse ListEnvironmentVpcs =
      ListEnvironmentVpcsResponse
  request :: (Service -> Service)
-> ListEnvironmentVpcs -> Request ListEnvironmentVpcs
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 ListEnvironmentVpcs
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListEnvironmentVpcs)))
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 [EnvironmentVpc]
-> Maybe Text -> Int -> ListEnvironmentVpcsResponse
ListEnvironmentVpcsResponse'
            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
"EnvironmentVpcList"
                            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 ListEnvironmentVpcs where
  hashWithSalt :: Int -> ListEnvironmentVpcs -> Int
hashWithSalt Int
_salt ListEnvironmentVpcs' {Maybe Natural
Maybe Text
Text
environmentIdentifier :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:environmentIdentifier:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Text
$sel:nextToken:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Text
$sel:maxResults:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> 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
environmentIdentifier

instance Prelude.NFData ListEnvironmentVpcs where
  rnf :: ListEnvironmentVpcs -> ()
rnf ListEnvironmentVpcs' {Maybe Natural
Maybe Text
Text
environmentIdentifier :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:environmentIdentifier:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Text
$sel:nextToken:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Text
$sel:maxResults:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> 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
environmentIdentifier

instance Data.ToHeaders ListEnvironmentVpcs where
  toHeaders :: ListEnvironmentVpcs -> 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 ListEnvironmentVpcs where
  toPath :: ListEnvironmentVpcs -> ByteString
toPath ListEnvironmentVpcs' {Maybe Natural
Maybe Text
Text
environmentIdentifier :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:environmentIdentifier:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Text
$sel:nextToken:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Text
$sel:maxResults:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Natural
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/environments/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
environmentIdentifier,
        ByteString
"/vpcs"
      ]

instance Data.ToQuery ListEnvironmentVpcs where
  toQuery :: ListEnvironmentVpcs -> QueryString
toQuery ListEnvironmentVpcs' {Maybe Natural
Maybe Text
Text
environmentIdentifier :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:environmentIdentifier:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Text
$sel:nextToken:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Text
$sel:maxResults:ListEnvironmentVpcs' :: ListEnvironmentVpcs -> Maybe Natural
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ 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:/ 'newListEnvironmentVpcsResponse' smart constructor.
data ListEnvironmentVpcsResponse = ListEnvironmentVpcsResponse'
  { -- | The list of @EnvironmentVpc@ objects.
    ListEnvironmentVpcsResponse -> Maybe [EnvironmentVpc]
environmentVpcList :: Prelude.Maybe [EnvironmentVpc],
    -- | The token for the next page of results.
    ListEnvironmentVpcsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListEnvironmentVpcsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListEnvironmentVpcsResponse -> ListEnvironmentVpcsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListEnvironmentVpcsResponse -> ListEnvironmentVpcsResponse -> Bool
$c/= :: ListEnvironmentVpcsResponse -> ListEnvironmentVpcsResponse -> Bool
== :: ListEnvironmentVpcsResponse -> ListEnvironmentVpcsResponse -> Bool
$c== :: ListEnvironmentVpcsResponse -> ListEnvironmentVpcsResponse -> Bool
Prelude.Eq, ReadPrec [ListEnvironmentVpcsResponse]
ReadPrec ListEnvironmentVpcsResponse
Int -> ReadS ListEnvironmentVpcsResponse
ReadS [ListEnvironmentVpcsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListEnvironmentVpcsResponse]
$creadListPrec :: ReadPrec [ListEnvironmentVpcsResponse]
readPrec :: ReadPrec ListEnvironmentVpcsResponse
$creadPrec :: ReadPrec ListEnvironmentVpcsResponse
readList :: ReadS [ListEnvironmentVpcsResponse]
$creadList :: ReadS [ListEnvironmentVpcsResponse]
readsPrec :: Int -> ReadS ListEnvironmentVpcsResponse
$creadsPrec :: Int -> ReadS ListEnvironmentVpcsResponse
Prelude.Read, Int -> ListEnvironmentVpcsResponse -> ShowS
[ListEnvironmentVpcsResponse] -> ShowS
ListEnvironmentVpcsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListEnvironmentVpcsResponse] -> ShowS
$cshowList :: [ListEnvironmentVpcsResponse] -> ShowS
show :: ListEnvironmentVpcsResponse -> String
$cshow :: ListEnvironmentVpcsResponse -> String
showsPrec :: Int -> ListEnvironmentVpcsResponse -> ShowS
$cshowsPrec :: Int -> ListEnvironmentVpcsResponse -> ShowS
Prelude.Show, forall x.
Rep ListEnvironmentVpcsResponse x -> ListEnvironmentVpcsResponse
forall x.
ListEnvironmentVpcsResponse -> Rep ListEnvironmentVpcsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListEnvironmentVpcsResponse x -> ListEnvironmentVpcsResponse
$cfrom :: forall x.
ListEnvironmentVpcsResponse -> Rep ListEnvironmentVpcsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListEnvironmentVpcsResponse' 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:
--
-- 'environmentVpcList', 'listEnvironmentVpcsResponse_environmentVpcList' - The list of @EnvironmentVpc@ objects.
--
-- 'nextToken', 'listEnvironmentVpcsResponse_nextToken' - The token for the next page of results.
--
-- 'httpStatus', 'listEnvironmentVpcsResponse_httpStatus' - The response's http status code.
newListEnvironmentVpcsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListEnvironmentVpcsResponse
newListEnvironmentVpcsResponse :: Int -> ListEnvironmentVpcsResponse
newListEnvironmentVpcsResponse Int
pHttpStatus_ =
  ListEnvironmentVpcsResponse'
    { $sel:environmentVpcList:ListEnvironmentVpcsResponse' :: Maybe [EnvironmentVpc]
environmentVpcList =
        forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListEnvironmentVpcsResponse' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListEnvironmentVpcsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The list of @EnvironmentVpc@ objects.
listEnvironmentVpcsResponse_environmentVpcList :: Lens.Lens' ListEnvironmentVpcsResponse (Prelude.Maybe [EnvironmentVpc])
listEnvironmentVpcsResponse_environmentVpcList :: Lens' ListEnvironmentVpcsResponse (Maybe [EnvironmentVpc])
listEnvironmentVpcsResponse_environmentVpcList = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListEnvironmentVpcsResponse' {Maybe [EnvironmentVpc]
environmentVpcList :: Maybe [EnvironmentVpc]
$sel:environmentVpcList:ListEnvironmentVpcsResponse' :: ListEnvironmentVpcsResponse -> Maybe [EnvironmentVpc]
environmentVpcList} -> Maybe [EnvironmentVpc]
environmentVpcList) (\s :: ListEnvironmentVpcsResponse
s@ListEnvironmentVpcsResponse' {} Maybe [EnvironmentVpc]
a -> ListEnvironmentVpcsResponse
s {$sel:environmentVpcList:ListEnvironmentVpcsResponse' :: Maybe [EnvironmentVpc]
environmentVpcList = Maybe [EnvironmentVpc]
a} :: ListEnvironmentVpcsResponse) 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 token for the next page of results.
listEnvironmentVpcsResponse_nextToken :: Lens.Lens' ListEnvironmentVpcsResponse (Prelude.Maybe Prelude.Text)
listEnvironmentVpcsResponse_nextToken :: Lens' ListEnvironmentVpcsResponse (Maybe Text)
listEnvironmentVpcsResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListEnvironmentVpcsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListEnvironmentVpcsResponse' :: ListEnvironmentVpcsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListEnvironmentVpcsResponse
s@ListEnvironmentVpcsResponse' {} Maybe Text
a -> ListEnvironmentVpcsResponse
s {$sel:nextToken:ListEnvironmentVpcsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListEnvironmentVpcsResponse)

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

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