{-# 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.IoT.ListV2LoggingLevels
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Lists logging levels.
--
-- Requires permission to access the
-- <https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsiot.html#awsiot-actions-as-permissions ListV2LoggingLevels>
-- action.
--
-- This operation returns paginated results.
module Amazonka.IoT.ListV2LoggingLevels
  ( -- * Creating a Request
    ListV2LoggingLevels (..),
    newListV2LoggingLevels,

    -- * Request Lenses
    listV2LoggingLevels_maxResults,
    listV2LoggingLevels_nextToken,
    listV2LoggingLevels_targetType,

    -- * Destructuring the Response
    ListV2LoggingLevelsResponse (..),
    newListV2LoggingLevelsResponse,

    -- * Response Lenses
    listV2LoggingLevelsResponse_logTargetConfigurations,
    listV2LoggingLevelsResponse_nextToken,
    listV2LoggingLevelsResponse_httpStatus,
  )
where

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

-- | /See:/ 'newListV2LoggingLevels' smart constructor.
data ListV2LoggingLevels = ListV2LoggingLevels'
  { -- | The maximum number of results to return at one time.
    ListV2LoggingLevels -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | To retrieve the next set of results, the @nextToken@ value from a
    -- previous response; otherwise __null__ to receive the first set of
    -- results.
    ListV2LoggingLevels -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The type of resource for which you are configuring logging. Must be
    -- @THING_Group@.
    ListV2LoggingLevels -> Maybe LogTargetType
targetType :: Prelude.Maybe LogTargetType
  }
  deriving (ListV2LoggingLevels -> ListV2LoggingLevels -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListV2LoggingLevels -> ListV2LoggingLevels -> Bool
$c/= :: ListV2LoggingLevels -> ListV2LoggingLevels -> Bool
== :: ListV2LoggingLevels -> ListV2LoggingLevels -> Bool
$c== :: ListV2LoggingLevels -> ListV2LoggingLevels -> Bool
Prelude.Eq, ReadPrec [ListV2LoggingLevels]
ReadPrec ListV2LoggingLevels
Int -> ReadS ListV2LoggingLevels
ReadS [ListV2LoggingLevels]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListV2LoggingLevels]
$creadListPrec :: ReadPrec [ListV2LoggingLevels]
readPrec :: ReadPrec ListV2LoggingLevels
$creadPrec :: ReadPrec ListV2LoggingLevels
readList :: ReadS [ListV2LoggingLevels]
$creadList :: ReadS [ListV2LoggingLevels]
readsPrec :: Int -> ReadS ListV2LoggingLevels
$creadsPrec :: Int -> ReadS ListV2LoggingLevels
Prelude.Read, Int -> ListV2LoggingLevels -> ShowS
[ListV2LoggingLevels] -> ShowS
ListV2LoggingLevels -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListV2LoggingLevels] -> ShowS
$cshowList :: [ListV2LoggingLevels] -> ShowS
show :: ListV2LoggingLevels -> String
$cshow :: ListV2LoggingLevels -> String
showsPrec :: Int -> ListV2LoggingLevels -> ShowS
$cshowsPrec :: Int -> ListV2LoggingLevels -> ShowS
Prelude.Show, forall x. Rep ListV2LoggingLevels x -> ListV2LoggingLevels
forall x. ListV2LoggingLevels -> Rep ListV2LoggingLevels x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListV2LoggingLevels x -> ListV2LoggingLevels
$cfrom :: forall x. ListV2LoggingLevels -> Rep ListV2LoggingLevels x
Prelude.Generic)

-- |
-- Create a value of 'ListV2LoggingLevels' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'maxResults', 'listV2LoggingLevels_maxResults' - The maximum number of results to return at one time.
--
-- 'nextToken', 'listV2LoggingLevels_nextToken' - To retrieve the next set of results, the @nextToken@ value from a
-- previous response; otherwise __null__ to receive the first set of
-- results.
--
-- 'targetType', 'listV2LoggingLevels_targetType' - The type of resource for which you are configuring logging. Must be
-- @THING_Group@.
newListV2LoggingLevels ::
  ListV2LoggingLevels
newListV2LoggingLevels :: ListV2LoggingLevels
newListV2LoggingLevels =
  ListV2LoggingLevels'
    { $sel:maxResults:ListV2LoggingLevels' :: Maybe Natural
maxResults = forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListV2LoggingLevels' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:targetType:ListV2LoggingLevels' :: Maybe LogTargetType
targetType = forall a. Maybe a
Prelude.Nothing
    }

-- | The maximum number of results to return at one time.
listV2LoggingLevels_maxResults :: Lens.Lens' ListV2LoggingLevels (Prelude.Maybe Prelude.Natural)
listV2LoggingLevels_maxResults :: Lens' ListV2LoggingLevels (Maybe Natural)
listV2LoggingLevels_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListV2LoggingLevels' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListV2LoggingLevels
s@ListV2LoggingLevels' {} Maybe Natural
a -> ListV2LoggingLevels
s {$sel:maxResults:ListV2LoggingLevels' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListV2LoggingLevels)

-- | To retrieve the next set of results, the @nextToken@ value from a
-- previous response; otherwise __null__ to receive the first set of
-- results.
listV2LoggingLevels_nextToken :: Lens.Lens' ListV2LoggingLevels (Prelude.Maybe Prelude.Text)
listV2LoggingLevels_nextToken :: Lens' ListV2LoggingLevels (Maybe Text)
listV2LoggingLevels_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListV2LoggingLevels' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListV2LoggingLevels
s@ListV2LoggingLevels' {} Maybe Text
a -> ListV2LoggingLevels
s {$sel:nextToken:ListV2LoggingLevels' :: Maybe Text
nextToken = Maybe Text
a} :: ListV2LoggingLevels)

-- | The type of resource for which you are configuring logging. Must be
-- @THING_Group@.
listV2LoggingLevels_targetType :: Lens.Lens' ListV2LoggingLevels (Prelude.Maybe LogTargetType)
listV2LoggingLevels_targetType :: Lens' ListV2LoggingLevels (Maybe LogTargetType)
listV2LoggingLevels_targetType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListV2LoggingLevels' {Maybe LogTargetType
targetType :: Maybe LogTargetType
$sel:targetType:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe LogTargetType
targetType} -> Maybe LogTargetType
targetType) (\s :: ListV2LoggingLevels
s@ListV2LoggingLevels' {} Maybe LogTargetType
a -> ListV2LoggingLevels
s {$sel:targetType:ListV2LoggingLevels' :: Maybe LogTargetType
targetType = Maybe LogTargetType
a} :: ListV2LoggingLevels)

instance Core.AWSPager ListV2LoggingLevels where
  page :: ListV2LoggingLevels
-> AWSResponse ListV2LoggingLevels -> Maybe ListV2LoggingLevels
page ListV2LoggingLevels
rq AWSResponse ListV2LoggingLevels
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListV2LoggingLevels
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListV2LoggingLevelsResponse (Maybe Text)
listV2LoggingLevelsResponse_nextToken
            forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
        forall a. Maybe a
Prelude.Nothing
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListV2LoggingLevels
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListV2LoggingLevelsResponse (Maybe [LogTargetConfiguration])
listV2LoggingLevelsResponse_logTargetConfigurations
            forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
        forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
        forall a. a -> Maybe a
Prelude.Just
          forall a b. (a -> b) -> a -> b
Prelude.$ ListV2LoggingLevels
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListV2LoggingLevels (Maybe Text)
listV2LoggingLevels_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListV2LoggingLevels
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListV2LoggingLevelsResponse (Maybe Text)
listV2LoggingLevelsResponse_nextToken
          forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just

instance Core.AWSRequest ListV2LoggingLevels where
  type
    AWSResponse ListV2LoggingLevels =
      ListV2LoggingLevelsResponse
  request :: (Service -> Service)
-> ListV2LoggingLevels -> Request ListV2LoggingLevels
request Service -> Service
overrides =
    forall a. ToRequest a => Service -> a -> Request a
Request.get (Service -> Service
overrides Service
defaultService)
  response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy ListV2LoggingLevels
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse ListV2LoggingLevels)))
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 [LogTargetConfiguration]
-> Maybe Text -> Int -> ListV2LoggingLevelsResponse
ListV2LoggingLevelsResponse'
            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
"logTargetConfigurations"
                            forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"nextToken")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable ListV2LoggingLevels where
  hashWithSalt :: Int -> ListV2LoggingLevels -> Int
hashWithSalt Int
_salt ListV2LoggingLevels' {Maybe Natural
Maybe Text
Maybe LogTargetType
targetType :: Maybe LogTargetType
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:targetType:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe LogTargetType
$sel:nextToken:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Text
$sel:maxResults:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Natural
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxResults
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextToken
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe LogTargetType
targetType

instance Prelude.NFData ListV2LoggingLevels where
  rnf :: ListV2LoggingLevels -> ()
rnf ListV2LoggingLevels' {Maybe Natural
Maybe Text
Maybe LogTargetType
targetType :: Maybe LogTargetType
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:targetType:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe LogTargetType
$sel:nextToken:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Text
$sel:maxResults:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Natural
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxResults
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe LogTargetType
targetType

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

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

instance Data.ToQuery ListV2LoggingLevels where
  toQuery :: ListV2LoggingLevels -> QueryString
toQuery ListV2LoggingLevels' {Maybe Natural
Maybe Text
Maybe LogTargetType
targetType :: Maybe LogTargetType
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:targetType:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe LogTargetType
$sel:nextToken:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Text
$sel:maxResults:ListV2LoggingLevels' :: ListV2LoggingLevels -> Maybe Natural
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"maxResults" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Natural
maxResults,
        ByteString
"nextToken" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Text
nextToken,
        ByteString
"targetType" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe LogTargetType
targetType
      ]

-- | /See:/ 'newListV2LoggingLevelsResponse' smart constructor.
data ListV2LoggingLevelsResponse = ListV2LoggingLevelsResponse'
  { -- | The logging configuration for a target.
    ListV2LoggingLevelsResponse -> Maybe [LogTargetConfiguration]
logTargetConfigurations :: Prelude.Maybe [LogTargetConfiguration],
    -- | The token to use to get the next set of results, or __null__ if there
    -- are no additional results.
    ListV2LoggingLevelsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListV2LoggingLevelsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListV2LoggingLevelsResponse -> ListV2LoggingLevelsResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListV2LoggingLevelsResponse -> ListV2LoggingLevelsResponse -> Bool
$c/= :: ListV2LoggingLevelsResponse -> ListV2LoggingLevelsResponse -> Bool
== :: ListV2LoggingLevelsResponse -> ListV2LoggingLevelsResponse -> Bool
$c== :: ListV2LoggingLevelsResponse -> ListV2LoggingLevelsResponse -> Bool
Prelude.Eq, ReadPrec [ListV2LoggingLevelsResponse]
ReadPrec ListV2LoggingLevelsResponse
Int -> ReadS ListV2LoggingLevelsResponse
ReadS [ListV2LoggingLevelsResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListV2LoggingLevelsResponse]
$creadListPrec :: ReadPrec [ListV2LoggingLevelsResponse]
readPrec :: ReadPrec ListV2LoggingLevelsResponse
$creadPrec :: ReadPrec ListV2LoggingLevelsResponse
readList :: ReadS [ListV2LoggingLevelsResponse]
$creadList :: ReadS [ListV2LoggingLevelsResponse]
readsPrec :: Int -> ReadS ListV2LoggingLevelsResponse
$creadsPrec :: Int -> ReadS ListV2LoggingLevelsResponse
Prelude.Read, Int -> ListV2LoggingLevelsResponse -> ShowS
[ListV2LoggingLevelsResponse] -> ShowS
ListV2LoggingLevelsResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListV2LoggingLevelsResponse] -> ShowS
$cshowList :: [ListV2LoggingLevelsResponse] -> ShowS
show :: ListV2LoggingLevelsResponse -> String
$cshow :: ListV2LoggingLevelsResponse -> String
showsPrec :: Int -> ListV2LoggingLevelsResponse -> ShowS
$cshowsPrec :: Int -> ListV2LoggingLevelsResponse -> ShowS
Prelude.Show, forall x.
Rep ListV2LoggingLevelsResponse x -> ListV2LoggingLevelsResponse
forall x.
ListV2LoggingLevelsResponse -> Rep ListV2LoggingLevelsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListV2LoggingLevelsResponse x -> ListV2LoggingLevelsResponse
$cfrom :: forall x.
ListV2LoggingLevelsResponse -> Rep ListV2LoggingLevelsResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListV2LoggingLevelsResponse' 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:
--
-- 'logTargetConfigurations', 'listV2LoggingLevelsResponse_logTargetConfigurations' - The logging configuration for a target.
--
-- 'nextToken', 'listV2LoggingLevelsResponse_nextToken' - The token to use to get the next set of results, or __null__ if there
-- are no additional results.
--
-- 'httpStatus', 'listV2LoggingLevelsResponse_httpStatus' - The response's http status code.
newListV2LoggingLevelsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListV2LoggingLevelsResponse
newListV2LoggingLevelsResponse :: Int -> ListV2LoggingLevelsResponse
newListV2LoggingLevelsResponse Int
pHttpStatus_ =
  ListV2LoggingLevelsResponse'
    { $sel:logTargetConfigurations:ListV2LoggingLevelsResponse' :: Maybe [LogTargetConfiguration]
logTargetConfigurations =
        forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListV2LoggingLevelsResponse' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:ListV2LoggingLevelsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The logging configuration for a target.
listV2LoggingLevelsResponse_logTargetConfigurations :: Lens.Lens' ListV2LoggingLevelsResponse (Prelude.Maybe [LogTargetConfiguration])
listV2LoggingLevelsResponse_logTargetConfigurations :: Lens' ListV2LoggingLevelsResponse (Maybe [LogTargetConfiguration])
listV2LoggingLevelsResponse_logTargetConfigurations = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListV2LoggingLevelsResponse' {Maybe [LogTargetConfiguration]
logTargetConfigurations :: Maybe [LogTargetConfiguration]
$sel:logTargetConfigurations:ListV2LoggingLevelsResponse' :: ListV2LoggingLevelsResponse -> Maybe [LogTargetConfiguration]
logTargetConfigurations} -> Maybe [LogTargetConfiguration]
logTargetConfigurations) (\s :: ListV2LoggingLevelsResponse
s@ListV2LoggingLevelsResponse' {} Maybe [LogTargetConfiguration]
a -> ListV2LoggingLevelsResponse
s {$sel:logTargetConfigurations:ListV2LoggingLevelsResponse' :: Maybe [LogTargetConfiguration]
logTargetConfigurations = Maybe [LogTargetConfiguration]
a} :: ListV2LoggingLevelsResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The token to use to get the next set of results, or __null__ if there
-- are no additional results.
listV2LoggingLevelsResponse_nextToken :: Lens.Lens' ListV2LoggingLevelsResponse (Prelude.Maybe Prelude.Text)
listV2LoggingLevelsResponse_nextToken :: Lens' ListV2LoggingLevelsResponse (Maybe Text)
listV2LoggingLevelsResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListV2LoggingLevelsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListV2LoggingLevelsResponse' :: ListV2LoggingLevelsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListV2LoggingLevelsResponse
s@ListV2LoggingLevelsResponse' {} Maybe Text
a -> ListV2LoggingLevelsResponse
s {$sel:nextToken:ListV2LoggingLevelsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListV2LoggingLevelsResponse)

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

instance Prelude.NFData ListV2LoggingLevelsResponse where
  rnf :: ListV2LoggingLevelsResponse -> ()
rnf ListV2LoggingLevelsResponse' {Int
Maybe [LogTargetConfiguration]
Maybe Text
httpStatus :: Int
nextToken :: Maybe Text
logTargetConfigurations :: Maybe [LogTargetConfiguration]
$sel:httpStatus:ListV2LoggingLevelsResponse' :: ListV2LoggingLevelsResponse -> Int
$sel:nextToken:ListV2LoggingLevelsResponse' :: ListV2LoggingLevelsResponse -> Maybe Text
$sel:logTargetConfigurations:ListV2LoggingLevelsResponse' :: ListV2LoggingLevelsResponse -> Maybe [LogTargetConfiguration]
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe [LogTargetConfiguration]
logTargetConfigurations
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
nextToken
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus