{-# 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.Route53.ListTrafficPolicyInstancesByHostedZone
-- 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)
--
-- Gets information about the traffic policy instances that you created in
-- a specified hosted zone.
--
-- After you submit a @CreateTrafficPolicyInstance@ or an
-- @UpdateTrafficPolicyInstance@ request, there\'s a brief delay while
-- Amazon Route 53 creates the resource record sets that are specified in
-- the traffic policy definition. For more information, see the @State@
-- response element.
--
-- Route 53 returns a maximum of 100 items in each response. If you have a
-- lot of traffic policy instances, you can use the @MaxItems@ parameter to
-- list them in groups of up to 100.
module Amazonka.Route53.ListTrafficPolicyInstancesByHostedZone
  ( -- * Creating a Request
    ListTrafficPolicyInstancesByHostedZone (..),
    newListTrafficPolicyInstancesByHostedZone,

    -- * Request Lenses
    listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceTypeMarker,
    listTrafficPolicyInstancesByHostedZone_maxItems,
    listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceNameMarker,
    listTrafficPolicyInstancesByHostedZone_hostedZoneId,

    -- * Destructuring the Response
    ListTrafficPolicyInstancesByHostedZoneResponse (..),
    newListTrafficPolicyInstancesByHostedZoneResponse,

    -- * Response Lenses
    listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceTypeMarker,
    listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceNameMarker,
    listTrafficPolicyInstancesByHostedZoneResponse_httpStatus,
    listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstances,
    listTrafficPolicyInstancesByHostedZoneResponse_isTruncated,
    listTrafficPolicyInstancesByHostedZoneResponse_maxItems,
  )
where

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

-- | A request for the traffic policy instances that you created in a
-- specified hosted zone.
--
-- /See:/ 'newListTrafficPolicyInstancesByHostedZone' smart constructor.
data ListTrafficPolicyInstancesByHostedZone = ListTrafficPolicyInstancesByHostedZone'
  { -- | If the value of @IsTruncated@ in the previous response is true, you have
    -- more traffic policy instances. To get more traffic policy instances,
    -- submit another @ListTrafficPolicyInstances@ request. For the value of
    -- @trafficpolicyinstancetype@, specify the value of
    -- @TrafficPolicyInstanceTypeMarker@ from the previous response, which is
    -- the type of the first traffic policy instance in the next group of
    -- traffic policy instances.
    --
    -- If the value of @IsTruncated@ in the previous response was @false@,
    -- there are no more traffic policy instances to get.
    ListTrafficPolicyInstancesByHostedZone -> Maybe RRType
trafficPolicyInstanceTypeMarker :: Prelude.Maybe RRType,
    -- | The maximum number of traffic policy instances to be included in the
    -- response body for this request. If you have more than @MaxItems@ traffic
    -- policy instances, the value of the @IsTruncated@ element in the response
    -- is @true@, and the values of @HostedZoneIdMarker@,
    -- @TrafficPolicyInstanceNameMarker@, and @TrafficPolicyInstanceTypeMarker@
    -- represent the first traffic policy instance that Amazon Route 53 will
    -- return if you submit another request.
    ListTrafficPolicyInstancesByHostedZone -> Maybe Text
maxItems :: Prelude.Maybe Prelude.Text,
    -- | If the value of @IsTruncated@ in the previous response is true, you have
    -- more traffic policy instances. To get more traffic policy instances,
    -- submit another @ListTrafficPolicyInstances@ request. For the value of
    -- @trafficpolicyinstancename@, specify the value of
    -- @TrafficPolicyInstanceNameMarker@ from the previous response, which is
    -- the name of the first traffic policy instance in the next group of
    -- traffic policy instances.
    --
    -- If the value of @IsTruncated@ in the previous response was @false@,
    -- there are no more traffic policy instances to get.
    ListTrafficPolicyInstancesByHostedZone -> Maybe Text
trafficPolicyInstanceNameMarker :: Prelude.Maybe Prelude.Text,
    -- | The ID of the hosted zone that you want to list traffic policy instances
    -- for.
    ListTrafficPolicyInstancesByHostedZone -> ResourceId
hostedZoneId :: ResourceId
  }
  deriving (ListTrafficPolicyInstancesByHostedZone
-> ListTrafficPolicyInstancesByHostedZone -> Bool
(ListTrafficPolicyInstancesByHostedZone
 -> ListTrafficPolicyInstancesByHostedZone -> Bool)
-> (ListTrafficPolicyInstancesByHostedZone
    -> ListTrafficPolicyInstancesByHostedZone -> Bool)
-> Eq ListTrafficPolicyInstancesByHostedZone
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListTrafficPolicyInstancesByHostedZone
-> ListTrafficPolicyInstancesByHostedZone -> Bool
$c/= :: ListTrafficPolicyInstancesByHostedZone
-> ListTrafficPolicyInstancesByHostedZone -> Bool
== :: ListTrafficPolicyInstancesByHostedZone
-> ListTrafficPolicyInstancesByHostedZone -> Bool
$c== :: ListTrafficPolicyInstancesByHostedZone
-> ListTrafficPolicyInstancesByHostedZone -> Bool
Prelude.Eq, ReadPrec [ListTrafficPolicyInstancesByHostedZone]
ReadPrec ListTrafficPolicyInstancesByHostedZone
Int -> ReadS ListTrafficPolicyInstancesByHostedZone
ReadS [ListTrafficPolicyInstancesByHostedZone]
(Int -> ReadS ListTrafficPolicyInstancesByHostedZone)
-> ReadS [ListTrafficPolicyInstancesByHostedZone]
-> ReadPrec ListTrafficPolicyInstancesByHostedZone
-> ReadPrec [ListTrafficPolicyInstancesByHostedZone]
-> Read ListTrafficPolicyInstancesByHostedZone
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListTrafficPolicyInstancesByHostedZone]
$creadListPrec :: ReadPrec [ListTrafficPolicyInstancesByHostedZone]
readPrec :: ReadPrec ListTrafficPolicyInstancesByHostedZone
$creadPrec :: ReadPrec ListTrafficPolicyInstancesByHostedZone
readList :: ReadS [ListTrafficPolicyInstancesByHostedZone]
$creadList :: ReadS [ListTrafficPolicyInstancesByHostedZone]
readsPrec :: Int -> ReadS ListTrafficPolicyInstancesByHostedZone
$creadsPrec :: Int -> ReadS ListTrafficPolicyInstancesByHostedZone
Prelude.Read, Int -> ListTrafficPolicyInstancesByHostedZone -> ShowS
[ListTrafficPolicyInstancesByHostedZone] -> ShowS
ListTrafficPolicyInstancesByHostedZone -> String
(Int -> ListTrafficPolicyInstancesByHostedZone -> ShowS)
-> (ListTrafficPolicyInstancesByHostedZone -> String)
-> ([ListTrafficPolicyInstancesByHostedZone] -> ShowS)
-> Show ListTrafficPolicyInstancesByHostedZone
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListTrafficPolicyInstancesByHostedZone] -> ShowS
$cshowList :: [ListTrafficPolicyInstancesByHostedZone] -> ShowS
show :: ListTrafficPolicyInstancesByHostedZone -> String
$cshow :: ListTrafficPolicyInstancesByHostedZone -> String
showsPrec :: Int -> ListTrafficPolicyInstancesByHostedZone -> ShowS
$cshowsPrec :: Int -> ListTrafficPolicyInstancesByHostedZone -> ShowS
Prelude.Show, (forall x.
 ListTrafficPolicyInstancesByHostedZone
 -> Rep ListTrafficPolicyInstancesByHostedZone x)
-> (forall x.
    Rep ListTrafficPolicyInstancesByHostedZone x
    -> ListTrafficPolicyInstancesByHostedZone)
-> Generic ListTrafficPolicyInstancesByHostedZone
forall x.
Rep ListTrafficPolicyInstancesByHostedZone x
-> ListTrafficPolicyInstancesByHostedZone
forall x.
ListTrafficPolicyInstancesByHostedZone
-> Rep ListTrafficPolicyInstancesByHostedZone x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListTrafficPolicyInstancesByHostedZone x
-> ListTrafficPolicyInstancesByHostedZone
$cfrom :: forall x.
ListTrafficPolicyInstancesByHostedZone
-> Rep ListTrafficPolicyInstancesByHostedZone x
Prelude.Generic)

-- |
-- Create a value of 'ListTrafficPolicyInstancesByHostedZone' 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:
--
-- 'trafficPolicyInstanceTypeMarker', 'listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceTypeMarker' - If the value of @IsTruncated@ in the previous response is true, you have
-- more traffic policy instances. To get more traffic policy instances,
-- submit another @ListTrafficPolicyInstances@ request. For the value of
-- @trafficpolicyinstancetype@, specify the value of
-- @TrafficPolicyInstanceTypeMarker@ from the previous response, which is
-- the type of the first traffic policy instance in the next group of
-- traffic policy instances.
--
-- If the value of @IsTruncated@ in the previous response was @false@,
-- there are no more traffic policy instances to get.
--
-- 'maxItems', 'listTrafficPolicyInstancesByHostedZone_maxItems' - The maximum number of traffic policy instances to be included in the
-- response body for this request. If you have more than @MaxItems@ traffic
-- policy instances, the value of the @IsTruncated@ element in the response
-- is @true@, and the values of @HostedZoneIdMarker@,
-- @TrafficPolicyInstanceNameMarker@, and @TrafficPolicyInstanceTypeMarker@
-- represent the first traffic policy instance that Amazon Route 53 will
-- return if you submit another request.
--
-- 'trafficPolicyInstanceNameMarker', 'listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceNameMarker' - If the value of @IsTruncated@ in the previous response is true, you have
-- more traffic policy instances. To get more traffic policy instances,
-- submit another @ListTrafficPolicyInstances@ request. For the value of
-- @trafficpolicyinstancename@, specify the value of
-- @TrafficPolicyInstanceNameMarker@ from the previous response, which is
-- the name of the first traffic policy instance in the next group of
-- traffic policy instances.
--
-- If the value of @IsTruncated@ in the previous response was @false@,
-- there are no more traffic policy instances to get.
--
-- 'hostedZoneId', 'listTrafficPolicyInstancesByHostedZone_hostedZoneId' - The ID of the hosted zone that you want to list traffic policy instances
-- for.
newListTrafficPolicyInstancesByHostedZone ::
  -- | 'hostedZoneId'
  ResourceId ->
  ListTrafficPolicyInstancesByHostedZone
newListTrafficPolicyInstancesByHostedZone :: ResourceId -> ListTrafficPolicyInstancesByHostedZone
newListTrafficPolicyInstancesByHostedZone
  ResourceId
pHostedZoneId_ =
    ListTrafficPolicyInstancesByHostedZone' :: Maybe RRType
-> Maybe Text
-> Maybe Text
-> ResourceId
-> ListTrafficPolicyInstancesByHostedZone
ListTrafficPolicyInstancesByHostedZone'
      { $sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZone' :: Maybe RRType
trafficPolicyInstanceTypeMarker =
          Maybe RRType
forall a. Maybe a
Prelude.Nothing,
        $sel:maxItems:ListTrafficPolicyInstancesByHostedZone' :: Maybe Text
maxItems = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZone' :: Maybe Text
trafficPolicyInstanceNameMarker =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:hostedZoneId:ListTrafficPolicyInstancesByHostedZone' :: ResourceId
hostedZoneId = ResourceId
pHostedZoneId_
      }

-- | If the value of @IsTruncated@ in the previous response is true, you have
-- more traffic policy instances. To get more traffic policy instances,
-- submit another @ListTrafficPolicyInstances@ request. For the value of
-- @trafficpolicyinstancetype@, specify the value of
-- @TrafficPolicyInstanceTypeMarker@ from the previous response, which is
-- the type of the first traffic policy instance in the next group of
-- traffic policy instances.
--
-- If the value of @IsTruncated@ in the previous response was @false@,
-- there are no more traffic policy instances to get.
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceTypeMarker :: Lens.Lens' ListTrafficPolicyInstancesByHostedZone (Prelude.Maybe RRType)
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceTypeMarker :: (Maybe RRType -> f (Maybe RRType))
-> ListTrafficPolicyInstancesByHostedZone
-> f ListTrafficPolicyInstancesByHostedZone
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceTypeMarker = (ListTrafficPolicyInstancesByHostedZone -> Maybe RRType)
-> (ListTrafficPolicyInstancesByHostedZone
    -> Maybe RRType -> ListTrafficPolicyInstancesByHostedZone)
-> Lens
     ListTrafficPolicyInstancesByHostedZone
     ListTrafficPolicyInstancesByHostedZone
     (Maybe RRType)
     (Maybe RRType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZone' {Maybe RRType
trafficPolicyInstanceTypeMarker :: Maybe RRType
$sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe RRType
trafficPolicyInstanceTypeMarker} -> Maybe RRType
trafficPolicyInstanceTypeMarker) (\s :: ListTrafficPolicyInstancesByHostedZone
s@ListTrafficPolicyInstancesByHostedZone' {} Maybe RRType
a -> ListTrafficPolicyInstancesByHostedZone
s {$sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZone' :: Maybe RRType
trafficPolicyInstanceTypeMarker = Maybe RRType
a} :: ListTrafficPolicyInstancesByHostedZone)

-- | The maximum number of traffic policy instances to be included in the
-- response body for this request. If you have more than @MaxItems@ traffic
-- policy instances, the value of the @IsTruncated@ element in the response
-- is @true@, and the values of @HostedZoneIdMarker@,
-- @TrafficPolicyInstanceNameMarker@, and @TrafficPolicyInstanceTypeMarker@
-- represent the first traffic policy instance that Amazon Route 53 will
-- return if you submit another request.
listTrafficPolicyInstancesByHostedZone_maxItems :: Lens.Lens' ListTrafficPolicyInstancesByHostedZone (Prelude.Maybe Prelude.Text)
listTrafficPolicyInstancesByHostedZone_maxItems :: (Maybe Text -> f (Maybe Text))
-> ListTrafficPolicyInstancesByHostedZone
-> f ListTrafficPolicyInstancesByHostedZone
listTrafficPolicyInstancesByHostedZone_maxItems = (ListTrafficPolicyInstancesByHostedZone -> Maybe Text)
-> (ListTrafficPolicyInstancesByHostedZone
    -> Maybe Text -> ListTrafficPolicyInstancesByHostedZone)
-> Lens
     ListTrafficPolicyInstancesByHostedZone
     ListTrafficPolicyInstancesByHostedZone
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZone' {Maybe Text
maxItems :: Maybe Text
$sel:maxItems:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe Text
maxItems} -> Maybe Text
maxItems) (\s :: ListTrafficPolicyInstancesByHostedZone
s@ListTrafficPolicyInstancesByHostedZone' {} Maybe Text
a -> ListTrafficPolicyInstancesByHostedZone
s {$sel:maxItems:ListTrafficPolicyInstancesByHostedZone' :: Maybe Text
maxItems = Maybe Text
a} :: ListTrafficPolicyInstancesByHostedZone)

-- | If the value of @IsTruncated@ in the previous response is true, you have
-- more traffic policy instances. To get more traffic policy instances,
-- submit another @ListTrafficPolicyInstances@ request. For the value of
-- @trafficpolicyinstancename@, specify the value of
-- @TrafficPolicyInstanceNameMarker@ from the previous response, which is
-- the name of the first traffic policy instance in the next group of
-- traffic policy instances.
--
-- If the value of @IsTruncated@ in the previous response was @false@,
-- there are no more traffic policy instances to get.
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceNameMarker :: Lens.Lens' ListTrafficPolicyInstancesByHostedZone (Prelude.Maybe Prelude.Text)
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceNameMarker :: (Maybe Text -> f (Maybe Text))
-> ListTrafficPolicyInstancesByHostedZone
-> f ListTrafficPolicyInstancesByHostedZone
listTrafficPolicyInstancesByHostedZone_trafficPolicyInstanceNameMarker = (ListTrafficPolicyInstancesByHostedZone -> Maybe Text)
-> (ListTrafficPolicyInstancesByHostedZone
    -> Maybe Text -> ListTrafficPolicyInstancesByHostedZone)
-> Lens
     ListTrafficPolicyInstancesByHostedZone
     ListTrafficPolicyInstancesByHostedZone
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZone' {Maybe Text
trafficPolicyInstanceNameMarker :: Maybe Text
$sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe Text
trafficPolicyInstanceNameMarker} -> Maybe Text
trafficPolicyInstanceNameMarker) (\s :: ListTrafficPolicyInstancesByHostedZone
s@ListTrafficPolicyInstancesByHostedZone' {} Maybe Text
a -> ListTrafficPolicyInstancesByHostedZone
s {$sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZone' :: Maybe Text
trafficPolicyInstanceNameMarker = Maybe Text
a} :: ListTrafficPolicyInstancesByHostedZone)

-- | The ID of the hosted zone that you want to list traffic policy instances
-- for.
listTrafficPolicyInstancesByHostedZone_hostedZoneId :: Lens.Lens' ListTrafficPolicyInstancesByHostedZone ResourceId
listTrafficPolicyInstancesByHostedZone_hostedZoneId :: (ResourceId -> f ResourceId)
-> ListTrafficPolicyInstancesByHostedZone
-> f ListTrafficPolicyInstancesByHostedZone
listTrafficPolicyInstancesByHostedZone_hostedZoneId = (ListTrafficPolicyInstancesByHostedZone -> ResourceId)
-> (ListTrafficPolicyInstancesByHostedZone
    -> ResourceId -> ListTrafficPolicyInstancesByHostedZone)
-> Lens
     ListTrafficPolicyInstancesByHostedZone
     ListTrafficPolicyInstancesByHostedZone
     ResourceId
     ResourceId
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZone' {ResourceId
hostedZoneId :: ResourceId
$sel:hostedZoneId:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> ResourceId
hostedZoneId} -> ResourceId
hostedZoneId) (\s :: ListTrafficPolicyInstancesByHostedZone
s@ListTrafficPolicyInstancesByHostedZone' {} ResourceId
a -> ListTrafficPolicyInstancesByHostedZone
s {$sel:hostedZoneId:ListTrafficPolicyInstancesByHostedZone' :: ResourceId
hostedZoneId = ResourceId
a} :: ListTrafficPolicyInstancesByHostedZone)

instance
  Core.AWSRequest
    ListTrafficPolicyInstancesByHostedZone
  where
  type
    AWSResponse
      ListTrafficPolicyInstancesByHostedZone =
      ListTrafficPolicyInstancesByHostedZoneResponse
  request :: ListTrafficPolicyInstancesByHostedZone
-> Request ListTrafficPolicyInstancesByHostedZone
request = Service
-> ListTrafficPolicyInstancesByHostedZone
-> Request ListTrafficPolicyInstancesByHostedZone
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
  response :: Logger
-> Service
-> Proxy ListTrafficPolicyInstancesByHostedZone
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse ListTrafficPolicyInstancesByHostedZone)))
response =
    (Int
 -> ResponseHeaders
 -> [Node]
 -> Either
      String (AWSResponse ListTrafficPolicyInstancesByHostedZone))
-> Logger
-> Service
-> Proxy ListTrafficPolicyInstancesByHostedZone
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse
           (AWSResponse ListTrafficPolicyInstancesByHostedZone)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXML
      ( \Int
s ResponseHeaders
h [Node]
x ->
          Maybe RRType
-> Maybe Text
-> Int
-> [TrafficPolicyInstance]
-> Bool
-> Text
-> ListTrafficPolicyInstancesByHostedZoneResponse
ListTrafficPolicyInstancesByHostedZoneResponse'
            (Maybe RRType
 -> Maybe Text
 -> Int
 -> [TrafficPolicyInstance]
 -> Bool
 -> Text
 -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String (Maybe RRType)
-> Either
     String
     (Maybe Text
      -> Int
      -> [TrafficPolicyInstance]
      -> Bool
      -> Text
      -> ListTrafficPolicyInstancesByHostedZoneResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe RRType)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TrafficPolicyInstanceTypeMarker")
              Either
  String
  (Maybe Text
   -> Int
   -> [TrafficPolicyInstance]
   -> Bool
   -> Text
   -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Int
      -> [TrafficPolicyInstance]
      -> Bool
      -> Text
      -> ListTrafficPolicyInstancesByHostedZoneResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TrafficPolicyInstanceNameMarker")
              Either
  String
  (Int
   -> [TrafficPolicyInstance]
   -> Bool
   -> Text
   -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String Int
-> Either
     String
     ([TrafficPolicyInstance]
      -> Bool -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
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))
              Either
  String
  ([TrafficPolicyInstance]
   -> Bool -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String [TrafficPolicyInstance]
-> Either
     String
     (Bool -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TrafficPolicyInstances"
                              Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                              Either String [Node]
-> ([Node] -> Either String [TrafficPolicyInstance])
-> Either String [TrafficPolicyInstance]
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= Text -> [Node] -> Either String [TrafficPolicyInstance]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"TrafficPolicyInstance"
                          )
              Either
  String
  (Bool -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String Bool
-> Either
     String (Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Bool
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"IsTruncated")
              Either
  String (Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Either String Text
-> Either String ListTrafficPolicyInstancesByHostedZoneResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String Text
forall a. FromXML a => [Node] -> Text -> Either String a
Core..@ Text
"MaxItems")
      )

instance
  Prelude.Hashable
    ListTrafficPolicyInstancesByHostedZone

instance
  Prelude.NFData
    ListTrafficPolicyInstancesByHostedZone

instance
  Core.ToHeaders
    ListTrafficPolicyInstancesByHostedZone
  where
  toHeaders :: ListTrafficPolicyInstancesByHostedZone -> ResponseHeaders
toHeaders = ResponseHeaders
-> ListTrafficPolicyInstancesByHostedZone -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const ResponseHeaders
forall a. Monoid a => a
Prelude.mempty

instance
  Core.ToPath
    ListTrafficPolicyInstancesByHostedZone
  where
  toPath :: ListTrafficPolicyInstancesByHostedZone -> ByteString
toPath =
    ByteString -> ListTrafficPolicyInstancesByHostedZone -> ByteString
forall a b. a -> b -> a
Prelude.const
      ByteString
"/2013-04-01/trafficpolicyinstances/hostedzone"

instance
  Core.ToQuery
    ListTrafficPolicyInstancesByHostedZone
  where
  toQuery :: ListTrafficPolicyInstancesByHostedZone -> QueryString
toQuery ListTrafficPolicyInstancesByHostedZone' {Maybe Text
Maybe RRType
ResourceId
hostedZoneId :: ResourceId
trafficPolicyInstanceNameMarker :: Maybe Text
maxItems :: Maybe Text
trafficPolicyInstanceTypeMarker :: Maybe RRType
$sel:hostedZoneId:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> ResourceId
$sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe Text
$sel:maxItems:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe Text
$sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZone' :: ListTrafficPolicyInstancesByHostedZone -> Maybe RRType
..} =
    [QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"trafficpolicyinstancetype"
          ByteString -> Maybe RRType -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe RRType
trafficPolicyInstanceTypeMarker,
        ByteString
"maxitems" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
maxItems,
        ByteString
"trafficpolicyinstancename"
          ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
trafficPolicyInstanceNameMarker,
        ByteString
"id" ByteString -> ResourceId -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ResourceId
hostedZoneId
      ]

-- | A complex type that contains the response information for the request.
--
-- /See:/ 'newListTrafficPolicyInstancesByHostedZoneResponse' smart constructor.
data ListTrafficPolicyInstancesByHostedZoneResponse = ListTrafficPolicyInstancesByHostedZoneResponse'
  { -- | If @IsTruncated@ is true, @TrafficPolicyInstanceTypeMarker@ is the DNS
    -- type of the resource record sets that are associated with the first
    -- traffic policy instance in the next group of traffic policy instances.
    ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe RRType
trafficPolicyInstanceTypeMarker :: Prelude.Maybe RRType,
    -- | If @IsTruncated@ is @true@, @TrafficPolicyInstanceNameMarker@ is the
    -- name of the first traffic policy instance in the next group of traffic
    -- policy instances.
    ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe Text
trafficPolicyInstanceNameMarker :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListTrafficPolicyInstancesByHostedZoneResponse -> Int
httpStatus :: Prelude.Int,
    -- | A list that contains one @TrafficPolicyInstance@ element for each
    -- traffic policy instance that matches the elements in the request.
    ListTrafficPolicyInstancesByHostedZoneResponse
-> [TrafficPolicyInstance]
trafficPolicyInstances :: [TrafficPolicyInstance],
    -- | A flag that indicates whether there are more traffic policy instances to
    -- be listed. If the response was truncated, you can get the next group of
    -- traffic policy instances by submitting another
    -- @ListTrafficPolicyInstancesByHostedZone@ request and specifying the
    -- values of @HostedZoneIdMarker@, @TrafficPolicyInstanceNameMarker@, and
    -- @TrafficPolicyInstanceTypeMarker@ in the corresponding request
    -- parameters.
    ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
isTruncated :: Prelude.Bool,
    -- | The value that you specified for the @MaxItems@ parameter in the
    -- @ListTrafficPolicyInstancesByHostedZone@ request that produced the
    -- current response.
    ListTrafficPolicyInstancesByHostedZoneResponse -> Text
maxItems :: Prelude.Text
  }
  deriving (ListTrafficPolicyInstancesByHostedZoneResponse
-> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
(ListTrafficPolicyInstancesByHostedZoneResponse
 -> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool)
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool)
-> Eq ListTrafficPolicyInstancesByHostedZoneResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListTrafficPolicyInstancesByHostedZoneResponse
-> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
$c/= :: ListTrafficPolicyInstancesByHostedZoneResponse
-> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
== :: ListTrafficPolicyInstancesByHostedZoneResponse
-> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
$c== :: ListTrafficPolicyInstancesByHostedZoneResponse
-> ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
Prelude.Eq, ReadPrec [ListTrafficPolicyInstancesByHostedZoneResponse]
ReadPrec ListTrafficPolicyInstancesByHostedZoneResponse
Int -> ReadS ListTrafficPolicyInstancesByHostedZoneResponse
ReadS [ListTrafficPolicyInstancesByHostedZoneResponse]
(Int -> ReadS ListTrafficPolicyInstancesByHostedZoneResponse)
-> ReadS [ListTrafficPolicyInstancesByHostedZoneResponse]
-> ReadPrec ListTrafficPolicyInstancesByHostedZoneResponse
-> ReadPrec [ListTrafficPolicyInstancesByHostedZoneResponse]
-> Read ListTrafficPolicyInstancesByHostedZoneResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListTrafficPolicyInstancesByHostedZoneResponse]
$creadListPrec :: ReadPrec [ListTrafficPolicyInstancesByHostedZoneResponse]
readPrec :: ReadPrec ListTrafficPolicyInstancesByHostedZoneResponse
$creadPrec :: ReadPrec ListTrafficPolicyInstancesByHostedZoneResponse
readList :: ReadS [ListTrafficPolicyInstancesByHostedZoneResponse]
$creadList :: ReadS [ListTrafficPolicyInstancesByHostedZoneResponse]
readsPrec :: Int -> ReadS ListTrafficPolicyInstancesByHostedZoneResponse
$creadsPrec :: Int -> ReadS ListTrafficPolicyInstancesByHostedZoneResponse
Prelude.Read, Int -> ListTrafficPolicyInstancesByHostedZoneResponse -> ShowS
[ListTrafficPolicyInstancesByHostedZoneResponse] -> ShowS
ListTrafficPolicyInstancesByHostedZoneResponse -> String
(Int -> ListTrafficPolicyInstancesByHostedZoneResponse -> ShowS)
-> (ListTrafficPolicyInstancesByHostedZoneResponse -> String)
-> ([ListTrafficPolicyInstancesByHostedZoneResponse] -> ShowS)
-> Show ListTrafficPolicyInstancesByHostedZoneResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListTrafficPolicyInstancesByHostedZoneResponse] -> ShowS
$cshowList :: [ListTrafficPolicyInstancesByHostedZoneResponse] -> ShowS
show :: ListTrafficPolicyInstancesByHostedZoneResponse -> String
$cshow :: ListTrafficPolicyInstancesByHostedZoneResponse -> String
showsPrec :: Int -> ListTrafficPolicyInstancesByHostedZoneResponse -> ShowS
$cshowsPrec :: Int -> ListTrafficPolicyInstancesByHostedZoneResponse -> ShowS
Prelude.Show, (forall x.
 ListTrafficPolicyInstancesByHostedZoneResponse
 -> Rep ListTrafficPolicyInstancesByHostedZoneResponse x)
-> (forall x.
    Rep ListTrafficPolicyInstancesByHostedZoneResponse x
    -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Generic ListTrafficPolicyInstancesByHostedZoneResponse
forall x.
Rep ListTrafficPolicyInstancesByHostedZoneResponse x
-> ListTrafficPolicyInstancesByHostedZoneResponse
forall x.
ListTrafficPolicyInstancesByHostedZoneResponse
-> Rep ListTrafficPolicyInstancesByHostedZoneResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListTrafficPolicyInstancesByHostedZoneResponse x
-> ListTrafficPolicyInstancesByHostedZoneResponse
$cfrom :: forall x.
ListTrafficPolicyInstancesByHostedZoneResponse
-> Rep ListTrafficPolicyInstancesByHostedZoneResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListTrafficPolicyInstancesByHostedZoneResponse' 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:
--
-- 'trafficPolicyInstanceTypeMarker', 'listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceTypeMarker' - If @IsTruncated@ is true, @TrafficPolicyInstanceTypeMarker@ is the DNS
-- type of the resource record sets that are associated with the first
-- traffic policy instance in the next group of traffic policy instances.
--
-- 'trafficPolicyInstanceNameMarker', 'listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceNameMarker' - If @IsTruncated@ is @true@, @TrafficPolicyInstanceNameMarker@ is the
-- name of the first traffic policy instance in the next group of traffic
-- policy instances.
--
-- 'httpStatus', 'listTrafficPolicyInstancesByHostedZoneResponse_httpStatus' - The response's http status code.
--
-- 'trafficPolicyInstances', 'listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstances' - A list that contains one @TrafficPolicyInstance@ element for each
-- traffic policy instance that matches the elements in the request.
--
-- 'isTruncated', 'listTrafficPolicyInstancesByHostedZoneResponse_isTruncated' - A flag that indicates whether there are more traffic policy instances to
-- be listed. If the response was truncated, you can get the next group of
-- traffic policy instances by submitting another
-- @ListTrafficPolicyInstancesByHostedZone@ request and specifying the
-- values of @HostedZoneIdMarker@, @TrafficPolicyInstanceNameMarker@, and
-- @TrafficPolicyInstanceTypeMarker@ in the corresponding request
-- parameters.
--
-- 'maxItems', 'listTrafficPolicyInstancesByHostedZoneResponse_maxItems' - The value that you specified for the @MaxItems@ parameter in the
-- @ListTrafficPolicyInstancesByHostedZone@ request that produced the
-- current response.
newListTrafficPolicyInstancesByHostedZoneResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  -- | 'isTruncated'
  Prelude.Bool ->
  -- | 'maxItems'
  Prelude.Text ->
  ListTrafficPolicyInstancesByHostedZoneResponse
newListTrafficPolicyInstancesByHostedZoneResponse :: Int
-> Bool -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse
newListTrafficPolicyInstancesByHostedZoneResponse
  Int
pHttpStatus_
  Bool
pIsTruncated_
  Text
pMaxItems_ =
    ListTrafficPolicyInstancesByHostedZoneResponse' :: Maybe RRType
-> Maybe Text
-> Int
-> [TrafficPolicyInstance]
-> Bool
-> Text
-> ListTrafficPolicyInstancesByHostedZoneResponse
ListTrafficPolicyInstancesByHostedZoneResponse'
      { $sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: Maybe RRType
trafficPolicyInstanceTypeMarker =
          Maybe RRType
forall a. Maybe a
Prelude.Nothing,
        $sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: Maybe Text
trafficPolicyInstanceNameMarker =
          Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:ListTrafficPolicyInstancesByHostedZoneResponse' :: Int
httpStatus = Int
pHttpStatus_,
        $sel:trafficPolicyInstances:ListTrafficPolicyInstancesByHostedZoneResponse' :: [TrafficPolicyInstance]
trafficPolicyInstances =
          [TrafficPolicyInstance]
forall a. Monoid a => a
Prelude.mempty,
        $sel:isTruncated:ListTrafficPolicyInstancesByHostedZoneResponse' :: Bool
isTruncated = Bool
pIsTruncated_,
        $sel:maxItems:ListTrafficPolicyInstancesByHostedZoneResponse' :: Text
maxItems = Text
pMaxItems_
      }

-- | If @IsTruncated@ is true, @TrafficPolicyInstanceTypeMarker@ is the DNS
-- type of the resource record sets that are associated with the first
-- traffic policy instance in the next group of traffic policy instances.
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceTypeMarker :: Lens.Lens' ListTrafficPolicyInstancesByHostedZoneResponse (Prelude.Maybe RRType)
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceTypeMarker :: (Maybe RRType -> f (Maybe RRType))
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceTypeMarker = (ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe RRType)
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> Maybe RRType -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Lens
     ListTrafficPolicyInstancesByHostedZoneResponse
     ListTrafficPolicyInstancesByHostedZoneResponse
     (Maybe RRType)
     (Maybe RRType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZoneResponse' {Maybe RRType
trafficPolicyInstanceTypeMarker :: Maybe RRType
$sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe RRType
trafficPolicyInstanceTypeMarker} -> Maybe RRType
trafficPolicyInstanceTypeMarker) (\s :: ListTrafficPolicyInstancesByHostedZoneResponse
s@ListTrafficPolicyInstancesByHostedZoneResponse' {} Maybe RRType
a -> ListTrafficPolicyInstancesByHostedZoneResponse
s {$sel:trafficPolicyInstanceTypeMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: Maybe RRType
trafficPolicyInstanceTypeMarker = Maybe RRType
a} :: ListTrafficPolicyInstancesByHostedZoneResponse)

-- | If @IsTruncated@ is @true@, @TrafficPolicyInstanceNameMarker@ is the
-- name of the first traffic policy instance in the next group of traffic
-- policy instances.
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceNameMarker :: Lens.Lens' ListTrafficPolicyInstancesByHostedZoneResponse (Prelude.Maybe Prelude.Text)
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceNameMarker :: (Maybe Text -> f (Maybe Text))
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstanceNameMarker = (ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe Text)
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> Maybe Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Lens
     ListTrafficPolicyInstancesByHostedZoneResponse
     ListTrafficPolicyInstancesByHostedZoneResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZoneResponse' {Maybe Text
trafficPolicyInstanceNameMarker :: Maybe Text
$sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: ListTrafficPolicyInstancesByHostedZoneResponse -> Maybe Text
trafficPolicyInstanceNameMarker} -> Maybe Text
trafficPolicyInstanceNameMarker) (\s :: ListTrafficPolicyInstancesByHostedZoneResponse
s@ListTrafficPolicyInstancesByHostedZoneResponse' {} Maybe Text
a -> ListTrafficPolicyInstancesByHostedZoneResponse
s {$sel:trafficPolicyInstanceNameMarker:ListTrafficPolicyInstancesByHostedZoneResponse' :: Maybe Text
trafficPolicyInstanceNameMarker = Maybe Text
a} :: ListTrafficPolicyInstancesByHostedZoneResponse)

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

-- | A list that contains one @TrafficPolicyInstance@ element for each
-- traffic policy instance that matches the elements in the request.
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstances :: Lens.Lens' ListTrafficPolicyInstancesByHostedZoneResponse [TrafficPolicyInstance]
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstances :: ([TrafficPolicyInstance] -> f [TrafficPolicyInstance])
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
listTrafficPolicyInstancesByHostedZoneResponse_trafficPolicyInstances = (ListTrafficPolicyInstancesByHostedZoneResponse
 -> [TrafficPolicyInstance])
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> [TrafficPolicyInstance]
    -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Lens
     ListTrafficPolicyInstancesByHostedZoneResponse
     ListTrafficPolicyInstancesByHostedZoneResponse
     [TrafficPolicyInstance]
     [TrafficPolicyInstance]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZoneResponse' {[TrafficPolicyInstance]
trafficPolicyInstances :: [TrafficPolicyInstance]
$sel:trafficPolicyInstances:ListTrafficPolicyInstancesByHostedZoneResponse' :: ListTrafficPolicyInstancesByHostedZoneResponse
-> [TrafficPolicyInstance]
trafficPolicyInstances} -> [TrafficPolicyInstance]
trafficPolicyInstances) (\s :: ListTrafficPolicyInstancesByHostedZoneResponse
s@ListTrafficPolicyInstancesByHostedZoneResponse' {} [TrafficPolicyInstance]
a -> ListTrafficPolicyInstancesByHostedZoneResponse
s {$sel:trafficPolicyInstances:ListTrafficPolicyInstancesByHostedZoneResponse' :: [TrafficPolicyInstance]
trafficPolicyInstances = [TrafficPolicyInstance]
a} :: ListTrafficPolicyInstancesByHostedZoneResponse) (([TrafficPolicyInstance] -> f [TrafficPolicyInstance])
 -> ListTrafficPolicyInstancesByHostedZoneResponse
 -> f ListTrafficPolicyInstancesByHostedZoneResponse)
-> (([TrafficPolicyInstance] -> f [TrafficPolicyInstance])
    -> [TrafficPolicyInstance] -> f [TrafficPolicyInstance])
-> ([TrafficPolicyInstance] -> f [TrafficPolicyInstance])
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([TrafficPolicyInstance] -> f [TrafficPolicyInstance])
-> [TrafficPolicyInstance] -> f [TrafficPolicyInstance]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A flag that indicates whether there are more traffic policy instances to
-- be listed. If the response was truncated, you can get the next group of
-- traffic policy instances by submitting another
-- @ListTrafficPolicyInstancesByHostedZone@ request and specifying the
-- values of @HostedZoneIdMarker@, @TrafficPolicyInstanceNameMarker@, and
-- @TrafficPolicyInstanceTypeMarker@ in the corresponding request
-- parameters.
listTrafficPolicyInstancesByHostedZoneResponse_isTruncated :: Lens.Lens' ListTrafficPolicyInstancesByHostedZoneResponse Prelude.Bool
listTrafficPolicyInstancesByHostedZoneResponse_isTruncated :: (Bool -> f Bool)
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
listTrafficPolicyInstancesByHostedZoneResponse_isTruncated = (ListTrafficPolicyInstancesByHostedZoneResponse -> Bool)
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> Bool -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Lens
     ListTrafficPolicyInstancesByHostedZoneResponse
     ListTrafficPolicyInstancesByHostedZoneResponse
     Bool
     Bool
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZoneResponse' {Bool
isTruncated :: Bool
$sel:isTruncated:ListTrafficPolicyInstancesByHostedZoneResponse' :: ListTrafficPolicyInstancesByHostedZoneResponse -> Bool
isTruncated} -> Bool
isTruncated) (\s :: ListTrafficPolicyInstancesByHostedZoneResponse
s@ListTrafficPolicyInstancesByHostedZoneResponse' {} Bool
a -> ListTrafficPolicyInstancesByHostedZoneResponse
s {$sel:isTruncated:ListTrafficPolicyInstancesByHostedZoneResponse' :: Bool
isTruncated = Bool
a} :: ListTrafficPolicyInstancesByHostedZoneResponse)

-- | The value that you specified for the @MaxItems@ parameter in the
-- @ListTrafficPolicyInstancesByHostedZone@ request that produced the
-- current response.
listTrafficPolicyInstancesByHostedZoneResponse_maxItems :: Lens.Lens' ListTrafficPolicyInstancesByHostedZoneResponse Prelude.Text
listTrafficPolicyInstancesByHostedZoneResponse_maxItems :: (Text -> f Text)
-> ListTrafficPolicyInstancesByHostedZoneResponse
-> f ListTrafficPolicyInstancesByHostedZoneResponse
listTrafficPolicyInstancesByHostedZoneResponse_maxItems = (ListTrafficPolicyInstancesByHostedZoneResponse -> Text)
-> (ListTrafficPolicyInstancesByHostedZoneResponse
    -> Text -> ListTrafficPolicyInstancesByHostedZoneResponse)
-> Lens
     ListTrafficPolicyInstancesByHostedZoneResponse
     ListTrafficPolicyInstancesByHostedZoneResponse
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListTrafficPolicyInstancesByHostedZoneResponse' {Text
maxItems :: Text
$sel:maxItems:ListTrafficPolicyInstancesByHostedZoneResponse' :: ListTrafficPolicyInstancesByHostedZoneResponse -> Text
maxItems} -> Text
maxItems) (\s :: ListTrafficPolicyInstancesByHostedZoneResponse
s@ListTrafficPolicyInstancesByHostedZoneResponse' {} Text
a -> ListTrafficPolicyInstancesByHostedZoneResponse
s {$sel:maxItems:ListTrafficPolicyInstancesByHostedZoneResponse' :: Text
maxItems = Text
a} :: ListTrafficPolicyInstancesByHostedZoneResponse)

instance
  Prelude.NFData
    ListTrafficPolicyInstancesByHostedZoneResponse