{-# 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.WAFV2.ListRegexPatternSets
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Retrieves an array of RegexPatternSetSummary objects for the regex
-- pattern sets that you manage.
module Amazonka.WAFV2.ListRegexPatternSets
  ( -- * Creating a Request
    ListRegexPatternSets (..),
    newListRegexPatternSets,

    -- * Request Lenses
    listRegexPatternSets_limit,
    listRegexPatternSets_nextMarker,
    listRegexPatternSets_scope,

    -- * Destructuring the Response
    ListRegexPatternSetsResponse (..),
    newListRegexPatternSetsResponse,

    -- * Response Lenses
    listRegexPatternSetsResponse_nextMarker,
    listRegexPatternSetsResponse_regexPatternSets,
    listRegexPatternSetsResponse_httpStatus,
  )
where

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

-- | /See:/ 'newListRegexPatternSets' smart constructor.
data ListRegexPatternSets = ListRegexPatternSets'
  { -- | The maximum number of objects that you want WAF to return for this
    -- request. If more objects are available, in the response, WAF provides a
    -- @NextMarker@ value that you can use in a subsequent call to get the next
    -- batch of objects.
    ListRegexPatternSets -> Maybe Natural
limit :: Prelude.Maybe Prelude.Natural,
    -- | When you request a list of objects with a @Limit@ setting, if the number
    -- of objects that are still available for retrieval exceeds the limit, WAF
    -- returns a @NextMarker@ value in the response. To retrieve the next batch
    -- of objects, provide the marker from the prior call in your next request.
    ListRegexPatternSets -> Maybe Text
nextMarker :: Prelude.Maybe Prelude.Text,
    -- | Specifies whether this is for an Amazon CloudFront distribution or for a
    -- regional application. A regional application can be an Application Load
    -- Balancer (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API,
    -- or an Amazon Cognito user pool.
    --
    -- To work with CloudFront, you must also specify the Region US East (N.
    -- Virginia) as follows:
    --
    -- -   CLI - Specify the Region when you use the CloudFront scope:
    --     @--scope=CLOUDFRONT --region=us-east-1@.
    --
    -- -   API and SDKs - For all calls, use the Region endpoint us-east-1.
    ListRegexPatternSets -> Scope
scope :: Scope
  }
  deriving (ListRegexPatternSets -> ListRegexPatternSets -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListRegexPatternSets -> ListRegexPatternSets -> Bool
$c/= :: ListRegexPatternSets -> ListRegexPatternSets -> Bool
== :: ListRegexPatternSets -> ListRegexPatternSets -> Bool
$c== :: ListRegexPatternSets -> ListRegexPatternSets -> Bool
Prelude.Eq, ReadPrec [ListRegexPatternSets]
ReadPrec ListRegexPatternSets
Int -> ReadS ListRegexPatternSets
ReadS [ListRegexPatternSets]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListRegexPatternSets]
$creadListPrec :: ReadPrec [ListRegexPatternSets]
readPrec :: ReadPrec ListRegexPatternSets
$creadPrec :: ReadPrec ListRegexPatternSets
readList :: ReadS [ListRegexPatternSets]
$creadList :: ReadS [ListRegexPatternSets]
readsPrec :: Int -> ReadS ListRegexPatternSets
$creadsPrec :: Int -> ReadS ListRegexPatternSets
Prelude.Read, Int -> ListRegexPatternSets -> ShowS
[ListRegexPatternSets] -> ShowS
ListRegexPatternSets -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListRegexPatternSets] -> ShowS
$cshowList :: [ListRegexPatternSets] -> ShowS
show :: ListRegexPatternSets -> String
$cshow :: ListRegexPatternSets -> String
showsPrec :: Int -> ListRegexPatternSets -> ShowS
$cshowsPrec :: Int -> ListRegexPatternSets -> ShowS
Prelude.Show, forall x. Rep ListRegexPatternSets x -> ListRegexPatternSets
forall x. ListRegexPatternSets -> Rep ListRegexPatternSets x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListRegexPatternSets x -> ListRegexPatternSets
$cfrom :: forall x. ListRegexPatternSets -> Rep ListRegexPatternSets x
Prelude.Generic)

-- |
-- Create a value of 'ListRegexPatternSets' 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:
--
-- 'limit', 'listRegexPatternSets_limit' - The maximum number of objects that you want WAF to return for this
-- request. If more objects are available, in the response, WAF provides a
-- @NextMarker@ value that you can use in a subsequent call to get the next
-- batch of objects.
--
-- 'nextMarker', 'listRegexPatternSets_nextMarker' - When you request a list of objects with a @Limit@ setting, if the number
-- of objects that are still available for retrieval exceeds the limit, WAF
-- returns a @NextMarker@ value in the response. To retrieve the next batch
-- of objects, provide the marker from the prior call in your next request.
--
-- 'scope', 'listRegexPatternSets_scope' - Specifies whether this is for an Amazon CloudFront distribution or for a
-- regional application. A regional application can be an Application Load
-- Balancer (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API,
-- or an Amazon Cognito user pool.
--
-- To work with CloudFront, you must also specify the Region US East (N.
-- Virginia) as follows:
--
-- -   CLI - Specify the Region when you use the CloudFront scope:
--     @--scope=CLOUDFRONT --region=us-east-1@.
--
-- -   API and SDKs - For all calls, use the Region endpoint us-east-1.
newListRegexPatternSets ::
  -- | 'scope'
  Scope ->
  ListRegexPatternSets
newListRegexPatternSets :: Scope -> ListRegexPatternSets
newListRegexPatternSets Scope
pScope_ =
  ListRegexPatternSets'
    { $sel:limit:ListRegexPatternSets' :: Maybe Natural
limit = forall a. Maybe a
Prelude.Nothing,
      $sel:nextMarker:ListRegexPatternSets' :: Maybe Text
nextMarker = forall a. Maybe a
Prelude.Nothing,
      $sel:scope:ListRegexPatternSets' :: Scope
scope = Scope
pScope_
    }

-- | The maximum number of objects that you want WAF to return for this
-- request. If more objects are available, in the response, WAF provides a
-- @NextMarker@ value that you can use in a subsequent call to get the next
-- batch of objects.
listRegexPatternSets_limit :: Lens.Lens' ListRegexPatternSets (Prelude.Maybe Prelude.Natural)
listRegexPatternSets_limit :: Lens' ListRegexPatternSets (Maybe Natural)
listRegexPatternSets_limit = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRegexPatternSets' {Maybe Natural
limit :: Maybe Natural
$sel:limit:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Natural
limit} -> Maybe Natural
limit) (\s :: ListRegexPatternSets
s@ListRegexPatternSets' {} Maybe Natural
a -> ListRegexPatternSets
s {$sel:limit:ListRegexPatternSets' :: Maybe Natural
limit = Maybe Natural
a} :: ListRegexPatternSets)

-- | When you request a list of objects with a @Limit@ setting, if the number
-- of objects that are still available for retrieval exceeds the limit, WAF
-- returns a @NextMarker@ value in the response. To retrieve the next batch
-- of objects, provide the marker from the prior call in your next request.
listRegexPatternSets_nextMarker :: Lens.Lens' ListRegexPatternSets (Prelude.Maybe Prelude.Text)
listRegexPatternSets_nextMarker :: Lens' ListRegexPatternSets (Maybe Text)
listRegexPatternSets_nextMarker = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRegexPatternSets' {Maybe Text
nextMarker :: Maybe Text
$sel:nextMarker:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Text
nextMarker} -> Maybe Text
nextMarker) (\s :: ListRegexPatternSets
s@ListRegexPatternSets' {} Maybe Text
a -> ListRegexPatternSets
s {$sel:nextMarker:ListRegexPatternSets' :: Maybe Text
nextMarker = Maybe Text
a} :: ListRegexPatternSets)

-- | Specifies whether this is for an Amazon CloudFront distribution or for a
-- regional application. A regional application can be an Application Load
-- Balancer (ALB), an Amazon API Gateway REST API, an AppSync GraphQL API,
-- or an Amazon Cognito user pool.
--
-- To work with CloudFront, you must also specify the Region US East (N.
-- Virginia) as follows:
--
-- -   CLI - Specify the Region when you use the CloudFront scope:
--     @--scope=CLOUDFRONT --region=us-east-1@.
--
-- -   API and SDKs - For all calls, use the Region endpoint us-east-1.
listRegexPatternSets_scope :: Lens.Lens' ListRegexPatternSets Scope
listRegexPatternSets_scope :: Lens' ListRegexPatternSets Scope
listRegexPatternSets_scope = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRegexPatternSets' {Scope
scope :: Scope
$sel:scope:ListRegexPatternSets' :: ListRegexPatternSets -> Scope
scope} -> Scope
scope) (\s :: ListRegexPatternSets
s@ListRegexPatternSets' {} Scope
a -> ListRegexPatternSets
s {$sel:scope:ListRegexPatternSets' :: Scope
scope = Scope
a} :: ListRegexPatternSets)

instance Core.AWSRequest ListRegexPatternSets where
  type
    AWSResponse ListRegexPatternSets =
      ListRegexPatternSetsResponse
  request :: (Service -> Service)
-> ListRegexPatternSets -> Request ListRegexPatternSets
request Service -> Service
overrides =
    forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListRegexPatternSets
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListRegexPatternSets)))
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 [RegexPatternSetSummary]
-> Int
-> ListRegexPatternSetsResponse
ListRegexPatternSetsResponse'
            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
"NextMarker")
            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
"RegexPatternSets"
                            forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable ListRegexPatternSets where
  hashWithSalt :: Int -> ListRegexPatternSets -> Int
hashWithSalt Int
_salt ListRegexPatternSets' {Maybe Natural
Maybe Text
Scope
scope :: Scope
nextMarker :: Maybe Text
limit :: Maybe Natural
$sel:scope:ListRegexPatternSets' :: ListRegexPatternSets -> Scope
$sel:nextMarker:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Text
$sel:limit:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Natural
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
limit
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextMarker
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Scope
scope

instance Prelude.NFData ListRegexPatternSets where
  rnf :: ListRegexPatternSets -> ()
rnf ListRegexPatternSets' {Maybe Natural
Maybe Text
Scope
scope :: Scope
nextMarker :: Maybe Text
limit :: Maybe Natural
$sel:scope:ListRegexPatternSets' :: ListRegexPatternSets -> Scope
$sel:nextMarker:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Text
$sel:limit:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Natural
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
limit
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextMarker
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Scope
scope

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

instance Data.ToJSON ListRegexPatternSets where
  toJSON :: ListRegexPatternSets -> Value
toJSON ListRegexPatternSets' {Maybe Natural
Maybe Text
Scope
scope :: Scope
nextMarker :: Maybe Text
limit :: Maybe Natural
$sel:scope:ListRegexPatternSets' :: ListRegexPatternSets -> Scope
$sel:nextMarker:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Text
$sel:limit:ListRegexPatternSets' :: ListRegexPatternSets -> Maybe Natural
..} =
    [Pair] -> Value
Data.object
      ( forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Key
"Limit" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
limit,
            (Key
"NextMarker" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
nextMarker,
            forall a. a -> Maybe a
Prelude.Just (Key
"Scope" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Scope
scope)
          ]
      )

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

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

-- | /See:/ 'newListRegexPatternSetsResponse' smart constructor.
data ListRegexPatternSetsResponse = ListRegexPatternSetsResponse'
  { -- | When you request a list of objects with a @Limit@ setting, if the number
    -- of objects that are still available for retrieval exceeds the limit, WAF
    -- returns a @NextMarker@ value in the response. To retrieve the next batch
    -- of objects, provide the marker from the prior call in your next request.
    ListRegexPatternSetsResponse -> Maybe Text
nextMarker :: Prelude.Maybe Prelude.Text,
    ListRegexPatternSetsResponse -> Maybe [RegexPatternSetSummary]
regexPatternSets :: Prelude.Maybe [RegexPatternSetSummary],
    -- | The response's http status code.
    ListRegexPatternSetsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListRegexPatternSetsResponse
-> ListRegexPatternSetsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListRegexPatternSetsResponse
-> ListRegexPatternSetsResponse -> Bool
$c/= :: ListRegexPatternSetsResponse
-> ListRegexPatternSetsResponse -> Bool
== :: ListRegexPatternSetsResponse
-> ListRegexPatternSetsResponse -> Bool
$c== :: ListRegexPatternSetsResponse
-> ListRegexPatternSetsResponse -> Bool
Prelude.Eq, ReadPrec [ListRegexPatternSetsResponse]
ReadPrec ListRegexPatternSetsResponse
Int -> ReadS ListRegexPatternSetsResponse
ReadS [ListRegexPatternSetsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListRegexPatternSetsResponse]
$creadListPrec :: ReadPrec [ListRegexPatternSetsResponse]
readPrec :: ReadPrec ListRegexPatternSetsResponse
$creadPrec :: ReadPrec ListRegexPatternSetsResponse
readList :: ReadS [ListRegexPatternSetsResponse]
$creadList :: ReadS [ListRegexPatternSetsResponse]
readsPrec :: Int -> ReadS ListRegexPatternSetsResponse
$creadsPrec :: Int -> ReadS ListRegexPatternSetsResponse
Prelude.Read, Int -> ListRegexPatternSetsResponse -> ShowS
[ListRegexPatternSetsResponse] -> ShowS
ListRegexPatternSetsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListRegexPatternSetsResponse] -> ShowS
$cshowList :: [ListRegexPatternSetsResponse] -> ShowS
show :: ListRegexPatternSetsResponse -> String
$cshow :: ListRegexPatternSetsResponse -> String
showsPrec :: Int -> ListRegexPatternSetsResponse -> ShowS
$cshowsPrec :: Int -> ListRegexPatternSetsResponse -> ShowS
Prelude.Show, forall x.
Rep ListRegexPatternSetsResponse x -> ListRegexPatternSetsResponse
forall x.
ListRegexPatternSetsResponse -> Rep ListRegexPatternSetsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListRegexPatternSetsResponse x -> ListRegexPatternSetsResponse
$cfrom :: forall x.
ListRegexPatternSetsResponse -> Rep ListRegexPatternSetsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListRegexPatternSetsResponse' 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:
--
-- 'nextMarker', 'listRegexPatternSetsResponse_nextMarker' - When you request a list of objects with a @Limit@ setting, if the number
-- of objects that are still available for retrieval exceeds the limit, WAF
-- returns a @NextMarker@ value in the response. To retrieve the next batch
-- of objects, provide the marker from the prior call in your next request.
--
-- 'regexPatternSets', 'listRegexPatternSetsResponse_regexPatternSets' -
--
-- 'httpStatus', 'listRegexPatternSetsResponse_httpStatus' - The response's http status code.
newListRegexPatternSetsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListRegexPatternSetsResponse
newListRegexPatternSetsResponse :: Int -> ListRegexPatternSetsResponse
newListRegexPatternSetsResponse Int
pHttpStatus_ =
  ListRegexPatternSetsResponse'
    { $sel:nextMarker:ListRegexPatternSetsResponse' :: Maybe Text
nextMarker =
        forall a. Maybe a
Prelude.Nothing,
      $sel:regexPatternSets:ListRegexPatternSetsResponse' :: Maybe [RegexPatternSetSummary]
regexPatternSets = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListRegexPatternSetsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | When you request a list of objects with a @Limit@ setting, if the number
-- of objects that are still available for retrieval exceeds the limit, WAF
-- returns a @NextMarker@ value in the response. To retrieve the next batch
-- of objects, provide the marker from the prior call in your next request.
listRegexPatternSetsResponse_nextMarker :: Lens.Lens' ListRegexPatternSetsResponse (Prelude.Maybe Prelude.Text)
listRegexPatternSetsResponse_nextMarker :: Lens' ListRegexPatternSetsResponse (Maybe Text)
listRegexPatternSetsResponse_nextMarker = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRegexPatternSetsResponse' {Maybe Text
nextMarker :: Maybe Text
$sel:nextMarker:ListRegexPatternSetsResponse' :: ListRegexPatternSetsResponse -> Maybe Text
nextMarker} -> Maybe Text
nextMarker) (\s :: ListRegexPatternSetsResponse
s@ListRegexPatternSetsResponse' {} Maybe Text
a -> ListRegexPatternSetsResponse
s {$sel:nextMarker:ListRegexPatternSetsResponse' :: Maybe Text
nextMarker = Maybe Text
a} :: ListRegexPatternSetsResponse)

listRegexPatternSetsResponse_regexPatternSets :: Lens.Lens' ListRegexPatternSetsResponse (Prelude.Maybe [RegexPatternSetSummary])
listRegexPatternSetsResponse_regexPatternSets :: Lens' ListRegexPatternSetsResponse (Maybe [RegexPatternSetSummary])
listRegexPatternSetsResponse_regexPatternSets = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListRegexPatternSetsResponse' {Maybe [RegexPatternSetSummary]
regexPatternSets :: Maybe [RegexPatternSetSummary]
$sel:regexPatternSets:ListRegexPatternSetsResponse' :: ListRegexPatternSetsResponse -> Maybe [RegexPatternSetSummary]
regexPatternSets} -> Maybe [RegexPatternSetSummary]
regexPatternSets) (\s :: ListRegexPatternSetsResponse
s@ListRegexPatternSetsResponse' {} Maybe [RegexPatternSetSummary]
a -> ListRegexPatternSetsResponse
s {$sel:regexPatternSets:ListRegexPatternSetsResponse' :: Maybe [RegexPatternSetSummary]
regexPatternSets = Maybe [RegexPatternSetSummary]
a} :: ListRegexPatternSetsResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

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

instance Prelude.NFData ListRegexPatternSetsResponse where
  rnf :: ListRegexPatternSetsResponse -> ()
rnf ListRegexPatternSetsResponse' {Int
Maybe [RegexPatternSetSummary]
Maybe Text
httpStatus :: Int
regexPatternSets :: Maybe [RegexPatternSetSummary]
nextMarker :: Maybe Text
$sel:httpStatus:ListRegexPatternSetsResponse' :: ListRegexPatternSetsResponse -> Int
$sel:regexPatternSets:ListRegexPatternSetsResponse' :: ListRegexPatternSetsResponse -> Maybe [RegexPatternSetSummary]
$sel:nextMarker:ListRegexPatternSetsResponse' :: ListRegexPatternSetsResponse -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextMarker
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [RegexPatternSetSummary]
regexPatternSets
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus