{-# 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.ServiceCatalogAppRegistry.ListAttributeGroupsForApplication
-- 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 the details of all attribute groups associated with a specific
-- application. The results display in pages.
--
-- This operation returns paginated results.
module Amazonka.ServiceCatalogAppRegistry.ListAttributeGroupsForApplication
  ( -- * Creating a Request
    ListAttributeGroupsForApplication (..),
    newListAttributeGroupsForApplication,

    -- * Request Lenses
    listAttributeGroupsForApplication_maxResults,
    listAttributeGroupsForApplication_nextToken,
    listAttributeGroupsForApplication_application,

    -- * Destructuring the Response
    ListAttributeGroupsForApplicationResponse (..),
    newListAttributeGroupsForApplicationResponse,

    -- * Response Lenses
    listAttributeGroupsForApplicationResponse_attributeGroupsDetails,
    listAttributeGroupsForApplicationResponse_nextToken,
    listAttributeGroupsForApplicationResponse_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.ServiceCatalogAppRegistry.Types

-- | /See:/ 'newListAttributeGroupsForApplication' smart constructor.
data ListAttributeGroupsForApplication = ListAttributeGroupsForApplication'
  { -- | The upper bound of the number of results to return. The value cannot
    -- exceed 25. If you omit this parameter, it defaults to 25. This value is
    -- optional.
    ListAttributeGroupsForApplication -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural,
    -- | This token retrieves the next page of results after a previous API call.
    ListAttributeGroupsForApplication -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The name or ID of the application.
    ListAttributeGroupsForApplication -> Text
application :: Prelude.Text
  }
  deriving (ListAttributeGroupsForApplication
-> ListAttributeGroupsForApplication -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAttributeGroupsForApplication
-> ListAttributeGroupsForApplication -> Bool
$c/= :: ListAttributeGroupsForApplication
-> ListAttributeGroupsForApplication -> Bool
== :: ListAttributeGroupsForApplication
-> ListAttributeGroupsForApplication -> Bool
$c== :: ListAttributeGroupsForApplication
-> ListAttributeGroupsForApplication -> Bool
Prelude.Eq, ReadPrec [ListAttributeGroupsForApplication]
ReadPrec ListAttributeGroupsForApplication
Int -> ReadS ListAttributeGroupsForApplication
ReadS [ListAttributeGroupsForApplication]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAttributeGroupsForApplication]
$creadListPrec :: ReadPrec [ListAttributeGroupsForApplication]
readPrec :: ReadPrec ListAttributeGroupsForApplication
$creadPrec :: ReadPrec ListAttributeGroupsForApplication
readList :: ReadS [ListAttributeGroupsForApplication]
$creadList :: ReadS [ListAttributeGroupsForApplication]
readsPrec :: Int -> ReadS ListAttributeGroupsForApplication
$creadsPrec :: Int -> ReadS ListAttributeGroupsForApplication
Prelude.Read, Int -> ListAttributeGroupsForApplication -> ShowS
[ListAttributeGroupsForApplication] -> ShowS
ListAttributeGroupsForApplication -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAttributeGroupsForApplication] -> ShowS
$cshowList :: [ListAttributeGroupsForApplication] -> ShowS
show :: ListAttributeGroupsForApplication -> String
$cshow :: ListAttributeGroupsForApplication -> String
showsPrec :: Int -> ListAttributeGroupsForApplication -> ShowS
$cshowsPrec :: Int -> ListAttributeGroupsForApplication -> ShowS
Prelude.Show, forall x.
Rep ListAttributeGroupsForApplication x
-> ListAttributeGroupsForApplication
forall x.
ListAttributeGroupsForApplication
-> Rep ListAttributeGroupsForApplication x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListAttributeGroupsForApplication x
-> ListAttributeGroupsForApplication
$cfrom :: forall x.
ListAttributeGroupsForApplication
-> Rep ListAttributeGroupsForApplication x
Prelude.Generic)

-- |
-- Create a value of 'ListAttributeGroupsForApplication' 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', 'listAttributeGroupsForApplication_maxResults' - The upper bound of the number of results to return. The value cannot
-- exceed 25. If you omit this parameter, it defaults to 25. This value is
-- optional.
--
-- 'nextToken', 'listAttributeGroupsForApplication_nextToken' - This token retrieves the next page of results after a previous API call.
--
-- 'application', 'listAttributeGroupsForApplication_application' - The name or ID of the application.
newListAttributeGroupsForApplication ::
  -- | 'application'
  Prelude.Text ->
  ListAttributeGroupsForApplication
newListAttributeGroupsForApplication :: Text -> ListAttributeGroupsForApplication
newListAttributeGroupsForApplication Text
pApplication_ =
  ListAttributeGroupsForApplication'
    { $sel:maxResults:ListAttributeGroupsForApplication' :: Maybe Natural
maxResults =
        forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:ListAttributeGroupsForApplication' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
      $sel:application:ListAttributeGroupsForApplication' :: Text
application = Text
pApplication_
    }

-- | The upper bound of the number of results to return. The value cannot
-- exceed 25. If you omit this parameter, it defaults to 25. This value is
-- optional.
listAttributeGroupsForApplication_maxResults :: Lens.Lens' ListAttributeGroupsForApplication (Prelude.Maybe Prelude.Natural)
listAttributeGroupsForApplication_maxResults :: Lens' ListAttributeGroupsForApplication (Maybe Natural)
listAttributeGroupsForApplication_maxResults = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAttributeGroupsForApplication' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListAttributeGroupsForApplication
s@ListAttributeGroupsForApplication' {} Maybe Natural
a -> ListAttributeGroupsForApplication
s {$sel:maxResults:ListAttributeGroupsForApplication' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListAttributeGroupsForApplication)

-- | This token retrieves the next page of results after a previous API call.
listAttributeGroupsForApplication_nextToken :: Lens.Lens' ListAttributeGroupsForApplication (Prelude.Maybe Prelude.Text)
listAttributeGroupsForApplication_nextToken :: Lens' ListAttributeGroupsForApplication (Maybe Text)
listAttributeGroupsForApplication_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAttributeGroupsForApplication' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAttributeGroupsForApplication
s@ListAttributeGroupsForApplication' {} Maybe Text
a -> ListAttributeGroupsForApplication
s {$sel:nextToken:ListAttributeGroupsForApplication' :: Maybe Text
nextToken = Maybe Text
a} :: ListAttributeGroupsForApplication)

-- | The name or ID of the application.
listAttributeGroupsForApplication_application :: Lens.Lens' ListAttributeGroupsForApplication Prelude.Text
listAttributeGroupsForApplication_application :: Lens' ListAttributeGroupsForApplication Text
listAttributeGroupsForApplication_application = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAttributeGroupsForApplication' {Text
application :: Text
$sel:application:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Text
application} -> Text
application) (\s :: ListAttributeGroupsForApplication
s@ListAttributeGroupsForApplication' {} Text
a -> ListAttributeGroupsForApplication
s {$sel:application:ListAttributeGroupsForApplication' :: Text
application = Text
a} :: ListAttributeGroupsForApplication)

instance
  Core.AWSPager
    ListAttributeGroupsForApplication
  where
  page :: ListAttributeGroupsForApplication
-> AWSResponse ListAttributeGroupsForApplication
-> Maybe ListAttributeGroupsForApplication
page ListAttributeGroupsForApplication
rq AWSResponse ListAttributeGroupsForApplication
rs
    | forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse ListAttributeGroupsForApplication
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAttributeGroupsForApplicationResponse (Maybe Text)
listAttributeGroupsForApplicationResponse_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 ListAttributeGroupsForApplication
rs
            forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens'
  ListAttributeGroupsForApplicationResponse
  (Maybe [AttributeGroupDetails])
listAttributeGroupsForApplicationResponse_attributeGroupsDetails
            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.$ ListAttributeGroupsForApplication
rq
          forall a b. a -> (a -> b) -> b
Prelude.& Lens' ListAttributeGroupsForApplication (Maybe Text)
listAttributeGroupsForApplication_nextToken
          forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse ListAttributeGroupsForApplication
rs
          forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? Lens' ListAttributeGroupsForApplicationResponse (Maybe Text)
listAttributeGroupsForApplicationResponse_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
    ListAttributeGroupsForApplication
  where
  type
    AWSResponse ListAttributeGroupsForApplication =
      ListAttributeGroupsForApplicationResponse
  request :: (Service -> Service)
-> ListAttributeGroupsForApplication
-> Request ListAttributeGroupsForApplication
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 ListAttributeGroupsForApplication
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse ListAttributeGroupsForApplication)))
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 [AttributeGroupDetails]
-> Maybe Text -> Int -> ListAttributeGroupsForApplicationResponse
ListAttributeGroupsForApplicationResponse'
            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
"attributeGroupsDetails"
                            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
    ListAttributeGroupsForApplication
  where
  hashWithSalt :: Int -> ListAttributeGroupsForApplication -> Int
hashWithSalt
    Int
_salt
    ListAttributeGroupsForApplication' {Maybe Natural
Maybe Text
Text
application :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:application:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Text
$sel:nextToken:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Text
$sel:maxResults:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Natural
..} =
      Int
_salt
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxResults
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
nextToken
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
application

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

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

instance
  Data.ToPath
    ListAttributeGroupsForApplication
  where
  toPath :: ListAttributeGroupsForApplication -> ByteString
toPath ListAttributeGroupsForApplication' {Maybe Natural
Maybe Text
Text
application :: Text
nextToken :: Maybe Text
maxResults :: Maybe Natural
$sel:application:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Text
$sel:nextToken:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Text
$sel:maxResults:ListAttributeGroupsForApplication' :: ListAttributeGroupsForApplication -> Maybe Natural
..} =
    forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/applications/",
        forall a. ToByteString a => a -> ByteString
Data.toBS Text
application,
        ByteString
"/attribute-group-details"
      ]

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

-- | /See:/ 'newListAttributeGroupsForApplicationResponse' smart constructor.
data ListAttributeGroupsForApplicationResponse = ListAttributeGroupsForApplicationResponse'
  { -- | The details related to a specific attribute group.
    ListAttributeGroupsForApplicationResponse
-> Maybe [AttributeGroupDetails]
attributeGroupsDetails :: Prelude.Maybe [AttributeGroupDetails],
    -- | The token to use to get the next page of results after a previous API
    -- call.
    ListAttributeGroupsForApplicationResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    ListAttributeGroupsForApplicationResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (ListAttributeGroupsForApplicationResponse
-> ListAttributeGroupsForApplicationResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListAttributeGroupsForApplicationResponse
-> ListAttributeGroupsForApplicationResponse -> Bool
$c/= :: ListAttributeGroupsForApplicationResponse
-> ListAttributeGroupsForApplicationResponse -> Bool
== :: ListAttributeGroupsForApplicationResponse
-> ListAttributeGroupsForApplicationResponse -> Bool
$c== :: ListAttributeGroupsForApplicationResponse
-> ListAttributeGroupsForApplicationResponse -> Bool
Prelude.Eq, ReadPrec [ListAttributeGroupsForApplicationResponse]
ReadPrec ListAttributeGroupsForApplicationResponse
Int -> ReadS ListAttributeGroupsForApplicationResponse
ReadS [ListAttributeGroupsForApplicationResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListAttributeGroupsForApplicationResponse]
$creadListPrec :: ReadPrec [ListAttributeGroupsForApplicationResponse]
readPrec :: ReadPrec ListAttributeGroupsForApplicationResponse
$creadPrec :: ReadPrec ListAttributeGroupsForApplicationResponse
readList :: ReadS [ListAttributeGroupsForApplicationResponse]
$creadList :: ReadS [ListAttributeGroupsForApplicationResponse]
readsPrec :: Int -> ReadS ListAttributeGroupsForApplicationResponse
$creadsPrec :: Int -> ReadS ListAttributeGroupsForApplicationResponse
Prelude.Read, Int -> ListAttributeGroupsForApplicationResponse -> ShowS
[ListAttributeGroupsForApplicationResponse] -> ShowS
ListAttributeGroupsForApplicationResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListAttributeGroupsForApplicationResponse] -> ShowS
$cshowList :: [ListAttributeGroupsForApplicationResponse] -> ShowS
show :: ListAttributeGroupsForApplicationResponse -> String
$cshow :: ListAttributeGroupsForApplicationResponse -> String
showsPrec :: Int -> ListAttributeGroupsForApplicationResponse -> ShowS
$cshowsPrec :: Int -> ListAttributeGroupsForApplicationResponse -> ShowS
Prelude.Show, forall x.
Rep ListAttributeGroupsForApplicationResponse x
-> ListAttributeGroupsForApplicationResponse
forall x.
ListAttributeGroupsForApplicationResponse
-> Rep ListAttributeGroupsForApplicationResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ListAttributeGroupsForApplicationResponse x
-> ListAttributeGroupsForApplicationResponse
$cfrom :: forall x.
ListAttributeGroupsForApplicationResponse
-> Rep ListAttributeGroupsForApplicationResponse x
Prelude.Generic)

-- |
-- Create a value of 'ListAttributeGroupsForApplicationResponse' 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:
--
-- 'attributeGroupsDetails', 'listAttributeGroupsForApplicationResponse_attributeGroupsDetails' - The details related to a specific attribute group.
--
-- 'nextToken', 'listAttributeGroupsForApplicationResponse_nextToken' - The token to use to get the next page of results after a previous API
-- call.
--
-- 'httpStatus', 'listAttributeGroupsForApplicationResponse_httpStatus' - The response's http status code.
newListAttributeGroupsForApplicationResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  ListAttributeGroupsForApplicationResponse
newListAttributeGroupsForApplicationResponse :: Int -> ListAttributeGroupsForApplicationResponse
newListAttributeGroupsForApplicationResponse
  Int
pHttpStatus_ =
    ListAttributeGroupsForApplicationResponse'
      { $sel:attributeGroupsDetails:ListAttributeGroupsForApplicationResponse' :: Maybe [AttributeGroupDetails]
attributeGroupsDetails =
          forall a. Maybe a
Prelude.Nothing,
        $sel:nextToken:ListAttributeGroupsForApplicationResponse' :: Maybe Text
nextToken = forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:ListAttributeGroupsForApplicationResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | The details related to a specific attribute group.
listAttributeGroupsForApplicationResponse_attributeGroupsDetails :: Lens.Lens' ListAttributeGroupsForApplicationResponse (Prelude.Maybe [AttributeGroupDetails])
listAttributeGroupsForApplicationResponse_attributeGroupsDetails :: Lens'
  ListAttributeGroupsForApplicationResponse
  (Maybe [AttributeGroupDetails])
listAttributeGroupsForApplicationResponse_attributeGroupsDetails = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAttributeGroupsForApplicationResponse' {Maybe [AttributeGroupDetails]
attributeGroupsDetails :: Maybe [AttributeGroupDetails]
$sel:attributeGroupsDetails:ListAttributeGroupsForApplicationResponse' :: ListAttributeGroupsForApplicationResponse
-> Maybe [AttributeGroupDetails]
attributeGroupsDetails} -> Maybe [AttributeGroupDetails]
attributeGroupsDetails) (\s :: ListAttributeGroupsForApplicationResponse
s@ListAttributeGroupsForApplicationResponse' {} Maybe [AttributeGroupDetails]
a -> ListAttributeGroupsForApplicationResponse
s {$sel:attributeGroupsDetails:ListAttributeGroupsForApplicationResponse' :: Maybe [AttributeGroupDetails]
attributeGroupsDetails = Maybe [AttributeGroupDetails]
a} :: ListAttributeGroupsForApplicationResponse) 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 page of results after a previous API
-- call.
listAttributeGroupsForApplicationResponse_nextToken :: Lens.Lens' ListAttributeGroupsForApplicationResponse (Prelude.Maybe Prelude.Text)
listAttributeGroupsForApplicationResponse_nextToken :: Lens' ListAttributeGroupsForApplicationResponse (Maybe Text)
listAttributeGroupsForApplicationResponse_nextToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListAttributeGroupsForApplicationResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListAttributeGroupsForApplicationResponse' :: ListAttributeGroupsForApplicationResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListAttributeGroupsForApplicationResponse
s@ListAttributeGroupsForApplicationResponse' {} Maybe Text
a -> ListAttributeGroupsForApplicationResponse
s {$sel:nextToken:ListAttributeGroupsForApplicationResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListAttributeGroupsForApplicationResponse)

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

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