{-# 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.Lightsail.GetStaticIps
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Returns information about all static IPs in the user\'s account.
--
-- This operation returns paginated results.
module Amazonka.Lightsail.GetStaticIps
  ( -- * Creating a Request
    GetStaticIps (..),
    newGetStaticIps,

    -- * Request Lenses
    getStaticIps_pageToken,

    -- * Destructuring the Response
    GetStaticIpsResponse (..),
    newGetStaticIpsResponse,

    -- * Response Lenses
    getStaticIpsResponse_nextPageToken,
    getStaticIpsResponse_staticIps,
    getStaticIpsResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Lightsail.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newGetStaticIps' smart constructor.
data GetStaticIps = GetStaticIps'
  { -- | The token to advance to the next page of results from your request.
    --
    -- To get a page token, perform an initial @GetStaticIps@ request. If your
    -- results are paginated, the response will return a next page token that
    -- you can specify as the page token in a subsequent request.
    GetStaticIps -> Maybe Text
pageToken :: Prelude.Maybe Prelude.Text
  }
  deriving (GetStaticIps -> GetStaticIps -> Bool
(GetStaticIps -> GetStaticIps -> Bool)
-> (GetStaticIps -> GetStaticIps -> Bool) -> Eq GetStaticIps
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetStaticIps -> GetStaticIps -> Bool
$c/= :: GetStaticIps -> GetStaticIps -> Bool
== :: GetStaticIps -> GetStaticIps -> Bool
$c== :: GetStaticIps -> GetStaticIps -> Bool
Prelude.Eq, ReadPrec [GetStaticIps]
ReadPrec GetStaticIps
Int -> ReadS GetStaticIps
ReadS [GetStaticIps]
(Int -> ReadS GetStaticIps)
-> ReadS [GetStaticIps]
-> ReadPrec GetStaticIps
-> ReadPrec [GetStaticIps]
-> Read GetStaticIps
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetStaticIps]
$creadListPrec :: ReadPrec [GetStaticIps]
readPrec :: ReadPrec GetStaticIps
$creadPrec :: ReadPrec GetStaticIps
readList :: ReadS [GetStaticIps]
$creadList :: ReadS [GetStaticIps]
readsPrec :: Int -> ReadS GetStaticIps
$creadsPrec :: Int -> ReadS GetStaticIps
Prelude.Read, Int -> GetStaticIps -> ShowS
[GetStaticIps] -> ShowS
GetStaticIps -> String
(Int -> GetStaticIps -> ShowS)
-> (GetStaticIps -> String)
-> ([GetStaticIps] -> ShowS)
-> Show GetStaticIps
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetStaticIps] -> ShowS
$cshowList :: [GetStaticIps] -> ShowS
show :: GetStaticIps -> String
$cshow :: GetStaticIps -> String
showsPrec :: Int -> GetStaticIps -> ShowS
$cshowsPrec :: Int -> GetStaticIps -> ShowS
Prelude.Show, (forall x. GetStaticIps -> Rep GetStaticIps x)
-> (forall x. Rep GetStaticIps x -> GetStaticIps)
-> Generic GetStaticIps
forall x. Rep GetStaticIps x -> GetStaticIps
forall x. GetStaticIps -> Rep GetStaticIps x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetStaticIps x -> GetStaticIps
$cfrom :: forall x. GetStaticIps -> Rep GetStaticIps x
Prelude.Generic)

-- |
-- Create a value of 'GetStaticIps' 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:
--
-- 'pageToken', 'getStaticIps_pageToken' - The token to advance to the next page of results from your request.
--
-- To get a page token, perform an initial @GetStaticIps@ request. If your
-- results are paginated, the response will return a next page token that
-- you can specify as the page token in a subsequent request.
newGetStaticIps ::
  GetStaticIps
newGetStaticIps :: GetStaticIps
newGetStaticIps =
  GetStaticIps' :: Maybe Text -> GetStaticIps
GetStaticIps' {$sel:pageToken:GetStaticIps' :: Maybe Text
pageToken = Maybe Text
forall a. Maybe a
Prelude.Nothing}

-- | The token to advance to the next page of results from your request.
--
-- To get a page token, perform an initial @GetStaticIps@ request. If your
-- results are paginated, the response will return a next page token that
-- you can specify as the page token in a subsequent request.
getStaticIps_pageToken :: Lens.Lens' GetStaticIps (Prelude.Maybe Prelude.Text)
getStaticIps_pageToken :: (Maybe Text -> f (Maybe Text)) -> GetStaticIps -> f GetStaticIps
getStaticIps_pageToken = (GetStaticIps -> Maybe Text)
-> (GetStaticIps -> Maybe Text -> GetStaticIps)
-> Lens GetStaticIps GetStaticIps (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetStaticIps' {Maybe Text
pageToken :: Maybe Text
$sel:pageToken:GetStaticIps' :: GetStaticIps -> Maybe Text
pageToken} -> Maybe Text
pageToken) (\s :: GetStaticIps
s@GetStaticIps' {} Maybe Text
a -> GetStaticIps
s {$sel:pageToken:GetStaticIps' :: Maybe Text
pageToken = Maybe Text
a} :: GetStaticIps)

instance Core.AWSPager GetStaticIps where
  page :: GetStaticIps -> AWSResponse GetStaticIps -> Maybe GetStaticIps
page GetStaticIps
rq AWSResponse GetStaticIps
rs
    | Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse GetStaticIps
GetStaticIpsResponse
rs
            GetStaticIpsResponse
-> Getting (First Text) GetStaticIpsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> GetStaticIpsResponse -> Const (First Text) GetStaticIpsResponse
Lens' GetStaticIpsResponse (Maybe Text)
getStaticIpsResponse_nextPageToken
              ((Maybe Text -> Const (First Text) (Maybe Text))
 -> GetStaticIpsResponse -> Const (First Text) GetStaticIpsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) GetStaticIpsResponse 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 GetStaticIps
forall a. Maybe a
Prelude.Nothing
    | Maybe [StaticIp] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse GetStaticIps
GetStaticIpsResponse
rs
            GetStaticIpsResponse
-> Getting (First [StaticIp]) GetStaticIpsResponse [StaticIp]
-> Maybe [StaticIp]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [StaticIp] -> Const (First [StaticIp]) (Maybe [StaticIp]))
-> GetStaticIpsResponse
-> Const (First [StaticIp]) GetStaticIpsResponse
Lens' GetStaticIpsResponse (Maybe [StaticIp])
getStaticIpsResponse_staticIps ((Maybe [StaticIp] -> Const (First [StaticIp]) (Maybe [StaticIp]))
 -> GetStaticIpsResponse
 -> Const (First [StaticIp]) GetStaticIpsResponse)
-> (([StaticIp] -> Const (First [StaticIp]) [StaticIp])
    -> Maybe [StaticIp] -> Const (First [StaticIp]) (Maybe [StaticIp]))
-> Getting (First [StaticIp]) GetStaticIpsResponse [StaticIp]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([StaticIp] -> Const (First [StaticIp]) [StaticIp])
-> Maybe [StaticIp] -> Const (First [StaticIp]) (Maybe [StaticIp])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe GetStaticIps
forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
      GetStaticIps -> Maybe GetStaticIps
forall a. a -> Maybe a
Prelude.Just (GetStaticIps -> Maybe GetStaticIps)
-> GetStaticIps -> Maybe GetStaticIps
forall a b. (a -> b) -> a -> b
Prelude.$
        GetStaticIps
rq
          GetStaticIps -> (GetStaticIps -> GetStaticIps) -> GetStaticIps
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> GetStaticIps -> Identity GetStaticIps
Lens GetStaticIps GetStaticIps (Maybe Text) (Maybe Text)
getStaticIps_pageToken
          ((Maybe Text -> Identity (Maybe Text))
 -> GetStaticIps -> Identity GetStaticIps)
-> Maybe Text -> GetStaticIps -> GetStaticIps
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse GetStaticIps
GetStaticIpsResponse
rs
          GetStaticIpsResponse
-> Getting (First Text) GetStaticIpsResponse Text -> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> GetStaticIpsResponse -> Const (First Text) GetStaticIpsResponse
Lens' GetStaticIpsResponse (Maybe Text)
getStaticIpsResponse_nextPageToken
            ((Maybe Text -> Const (First Text) (Maybe Text))
 -> GetStaticIpsResponse -> Const (First Text) GetStaticIpsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) GetStaticIpsResponse 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 GetStaticIps where
  type AWSResponse GetStaticIps = GetStaticIpsResponse
  request :: GetStaticIps -> Request GetStaticIps
request = Service -> GetStaticIps -> Request GetStaticIps
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy GetStaticIps
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetStaticIps)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse GetStaticIps))
-> Logger
-> Service
-> Proxy GetStaticIps
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse GetStaticIps)))
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 [StaticIp] -> Int -> GetStaticIpsResponse
GetStaticIpsResponse'
            (Maybe Text -> Maybe [StaticIp] -> Int -> GetStaticIpsResponse)
-> Either String (Maybe Text)
-> Either String (Maybe [StaticIp] -> Int -> GetStaticIpsResponse)
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
"nextPageToken")
            Either String (Maybe [StaticIp] -> Int -> GetStaticIpsResponse)
-> Either String (Maybe [StaticIp])
-> Either String (Int -> GetStaticIpsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (Maybe [StaticIp]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"staticIps" Either String (Maybe (Maybe [StaticIp]))
-> Maybe [StaticIp] -> Either String (Maybe [StaticIp])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [StaticIp]
forall a. Monoid a => a
Prelude.mempty)
            Either String (Int -> GetStaticIpsResponse)
-> Either String Int -> Either String GetStaticIpsResponse
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 GetStaticIps

instance Prelude.NFData GetStaticIps

instance Core.ToHeaders GetStaticIps where
  toHeaders :: GetStaticIps -> ResponseHeaders
toHeaders =
    ResponseHeaders -> GetStaticIps -> 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
"Lightsail_20161128.GetStaticIps" ::
                          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 GetStaticIps where
  toJSON :: GetStaticIps -> Value
toJSON GetStaticIps' {Maybe Text
pageToken :: Maybe Text
$sel:pageToken:GetStaticIps' :: GetStaticIps -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [(Text
"pageToken" 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
pageToken]
      )

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

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

-- | /See:/ 'newGetStaticIpsResponse' smart constructor.
data GetStaticIpsResponse = GetStaticIpsResponse'
  { -- | The token to advance to the next page of results from your request.
    --
    -- A next page token is not returned if there are no more results to
    -- display.
    --
    -- To get the next page of results, perform another @GetStaticIps@ request
    -- and specify the next page token using the @pageToken@ parameter.
    GetStaticIpsResponse -> Maybe Text
nextPageToken :: Prelude.Maybe Prelude.Text,
    -- | An array of key-value pairs containing information about your get static
    -- IPs request.
    GetStaticIpsResponse -> Maybe [StaticIp]
staticIps :: Prelude.Maybe [StaticIp],
    -- | The response's http status code.
    GetStaticIpsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (GetStaticIpsResponse -> GetStaticIpsResponse -> Bool
(GetStaticIpsResponse -> GetStaticIpsResponse -> Bool)
-> (GetStaticIpsResponse -> GetStaticIpsResponse -> Bool)
-> Eq GetStaticIpsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetStaticIpsResponse -> GetStaticIpsResponse -> Bool
$c/= :: GetStaticIpsResponse -> GetStaticIpsResponse -> Bool
== :: GetStaticIpsResponse -> GetStaticIpsResponse -> Bool
$c== :: GetStaticIpsResponse -> GetStaticIpsResponse -> Bool
Prelude.Eq, ReadPrec [GetStaticIpsResponse]
ReadPrec GetStaticIpsResponse
Int -> ReadS GetStaticIpsResponse
ReadS [GetStaticIpsResponse]
(Int -> ReadS GetStaticIpsResponse)
-> ReadS [GetStaticIpsResponse]
-> ReadPrec GetStaticIpsResponse
-> ReadPrec [GetStaticIpsResponse]
-> Read GetStaticIpsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetStaticIpsResponse]
$creadListPrec :: ReadPrec [GetStaticIpsResponse]
readPrec :: ReadPrec GetStaticIpsResponse
$creadPrec :: ReadPrec GetStaticIpsResponse
readList :: ReadS [GetStaticIpsResponse]
$creadList :: ReadS [GetStaticIpsResponse]
readsPrec :: Int -> ReadS GetStaticIpsResponse
$creadsPrec :: Int -> ReadS GetStaticIpsResponse
Prelude.Read, Int -> GetStaticIpsResponse -> ShowS
[GetStaticIpsResponse] -> ShowS
GetStaticIpsResponse -> String
(Int -> GetStaticIpsResponse -> ShowS)
-> (GetStaticIpsResponse -> String)
-> ([GetStaticIpsResponse] -> ShowS)
-> Show GetStaticIpsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetStaticIpsResponse] -> ShowS
$cshowList :: [GetStaticIpsResponse] -> ShowS
show :: GetStaticIpsResponse -> String
$cshow :: GetStaticIpsResponse -> String
showsPrec :: Int -> GetStaticIpsResponse -> ShowS
$cshowsPrec :: Int -> GetStaticIpsResponse -> ShowS
Prelude.Show, (forall x. GetStaticIpsResponse -> Rep GetStaticIpsResponse x)
-> (forall x. Rep GetStaticIpsResponse x -> GetStaticIpsResponse)
-> Generic GetStaticIpsResponse
forall x. Rep GetStaticIpsResponse x -> GetStaticIpsResponse
forall x. GetStaticIpsResponse -> Rep GetStaticIpsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetStaticIpsResponse x -> GetStaticIpsResponse
$cfrom :: forall x. GetStaticIpsResponse -> Rep GetStaticIpsResponse x
Prelude.Generic)

-- |
-- Create a value of 'GetStaticIpsResponse' 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:
--
-- 'nextPageToken', 'getStaticIpsResponse_nextPageToken' - The token to advance to the next page of results from your request.
--
-- A next page token is not returned if there are no more results to
-- display.
--
-- To get the next page of results, perform another @GetStaticIps@ request
-- and specify the next page token using the @pageToken@ parameter.
--
-- 'staticIps', 'getStaticIpsResponse_staticIps' - An array of key-value pairs containing information about your get static
-- IPs request.
--
-- 'httpStatus', 'getStaticIpsResponse_httpStatus' - The response's http status code.
newGetStaticIpsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  GetStaticIpsResponse
newGetStaticIpsResponse :: Int -> GetStaticIpsResponse
newGetStaticIpsResponse Int
pHttpStatus_ =
  GetStaticIpsResponse' :: Maybe Text -> Maybe [StaticIp] -> Int -> GetStaticIpsResponse
GetStaticIpsResponse'
    { $sel:nextPageToken:GetStaticIpsResponse' :: Maybe Text
nextPageToken =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:staticIps:GetStaticIpsResponse' :: Maybe [StaticIp]
staticIps = Maybe [StaticIp]
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:GetStaticIpsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The token to advance to the next page of results from your request.
--
-- A next page token is not returned if there are no more results to
-- display.
--
-- To get the next page of results, perform another @GetStaticIps@ request
-- and specify the next page token using the @pageToken@ parameter.
getStaticIpsResponse_nextPageToken :: Lens.Lens' GetStaticIpsResponse (Prelude.Maybe Prelude.Text)
getStaticIpsResponse_nextPageToken :: (Maybe Text -> f (Maybe Text))
-> GetStaticIpsResponse -> f GetStaticIpsResponse
getStaticIpsResponse_nextPageToken = (GetStaticIpsResponse -> Maybe Text)
-> (GetStaticIpsResponse -> Maybe Text -> GetStaticIpsResponse)
-> Lens' GetStaticIpsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetStaticIpsResponse' {Maybe Text
nextPageToken :: Maybe Text
$sel:nextPageToken:GetStaticIpsResponse' :: GetStaticIpsResponse -> Maybe Text
nextPageToken} -> Maybe Text
nextPageToken) (\s :: GetStaticIpsResponse
s@GetStaticIpsResponse' {} Maybe Text
a -> GetStaticIpsResponse
s {$sel:nextPageToken:GetStaticIpsResponse' :: Maybe Text
nextPageToken = Maybe Text
a} :: GetStaticIpsResponse)

-- | An array of key-value pairs containing information about your get static
-- IPs request.
getStaticIpsResponse_staticIps :: Lens.Lens' GetStaticIpsResponse (Prelude.Maybe [StaticIp])
getStaticIpsResponse_staticIps :: (Maybe [StaticIp] -> f (Maybe [StaticIp]))
-> GetStaticIpsResponse -> f GetStaticIpsResponse
getStaticIpsResponse_staticIps = (GetStaticIpsResponse -> Maybe [StaticIp])
-> (GetStaticIpsResponse
    -> Maybe [StaticIp] -> GetStaticIpsResponse)
-> Lens' GetStaticIpsResponse (Maybe [StaticIp])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetStaticIpsResponse' {Maybe [StaticIp]
staticIps :: Maybe [StaticIp]
$sel:staticIps:GetStaticIpsResponse' :: GetStaticIpsResponse -> Maybe [StaticIp]
staticIps} -> Maybe [StaticIp]
staticIps) (\s :: GetStaticIpsResponse
s@GetStaticIpsResponse' {} Maybe [StaticIp]
a -> GetStaticIpsResponse
s {$sel:staticIps:GetStaticIpsResponse' :: Maybe [StaticIp]
staticIps = Maybe [StaticIp]
a} :: GetStaticIpsResponse) ((Maybe [StaticIp] -> f (Maybe [StaticIp]))
 -> GetStaticIpsResponse -> f GetStaticIpsResponse)
-> ((Maybe [StaticIp] -> f (Maybe [StaticIp]))
    -> Maybe [StaticIp] -> f (Maybe [StaticIp]))
-> (Maybe [StaticIp] -> f (Maybe [StaticIp]))
-> GetStaticIpsResponse
-> f GetStaticIpsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [StaticIp] [StaticIp] [StaticIp] [StaticIp]
-> Iso
     (Maybe [StaticIp])
     (Maybe [StaticIp])
     (Maybe [StaticIp])
     (Maybe [StaticIp])
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 [StaticIp] [StaticIp] [StaticIp] [StaticIp]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance Prelude.NFData GetStaticIpsResponse