{-# 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.SecurityHub.DescribeStandards
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Returns a list of the available standards in Security Hub.
--
-- For each standard, the results include the standard ARN, the name, and a
-- description.
--
-- This operation returns paginated results.
module Amazonka.SecurityHub.DescribeStandards
  ( -- * Creating a Request
    DescribeStandards (..),
    newDescribeStandards,

    -- * Request Lenses
    describeStandards_nextToken,
    describeStandards_maxResults,

    -- * Destructuring the Response
    DescribeStandardsResponse (..),
    newDescribeStandardsResponse,

    -- * Response Lenses
    describeStandardsResponse_standards,
    describeStandardsResponse_nextToken,
    describeStandardsResponse_httpStatus,
  )
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.SecurityHub.Types

-- | /See:/ 'newDescribeStandards' smart constructor.
data DescribeStandards = DescribeStandards'
  { -- | The token that is required for pagination. On your first call to the
    -- @DescribeStandards@ operation, set the value of this parameter to
    -- @NULL@.
    --
    -- For subsequent calls to the operation, to continue listing data, set the
    -- value of this parameter to the value returned from the previous
    -- response.
    DescribeStandards -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of standards to return.
    DescribeStandards -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
  }
  deriving (DescribeStandards -> DescribeStandards -> Bool
(DescribeStandards -> DescribeStandards -> Bool)
-> (DescribeStandards -> DescribeStandards -> Bool)
-> Eq DescribeStandards
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeStandards -> DescribeStandards -> Bool
$c/= :: DescribeStandards -> DescribeStandards -> Bool
== :: DescribeStandards -> DescribeStandards -> Bool
$c== :: DescribeStandards -> DescribeStandards -> Bool
Prelude.Eq, ReadPrec [DescribeStandards]
ReadPrec DescribeStandards
Int -> ReadS DescribeStandards
ReadS [DescribeStandards]
(Int -> ReadS DescribeStandards)
-> ReadS [DescribeStandards]
-> ReadPrec DescribeStandards
-> ReadPrec [DescribeStandards]
-> Read DescribeStandards
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeStandards]
$creadListPrec :: ReadPrec [DescribeStandards]
readPrec :: ReadPrec DescribeStandards
$creadPrec :: ReadPrec DescribeStandards
readList :: ReadS [DescribeStandards]
$creadList :: ReadS [DescribeStandards]
readsPrec :: Int -> ReadS DescribeStandards
$creadsPrec :: Int -> ReadS DescribeStandards
Prelude.Read, Int -> DescribeStandards -> ShowS
[DescribeStandards] -> ShowS
DescribeStandards -> String
(Int -> DescribeStandards -> ShowS)
-> (DescribeStandards -> String)
-> ([DescribeStandards] -> ShowS)
-> Show DescribeStandards
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeStandards] -> ShowS
$cshowList :: [DescribeStandards] -> ShowS
show :: DescribeStandards -> String
$cshow :: DescribeStandards -> String
showsPrec :: Int -> DescribeStandards -> ShowS
$cshowsPrec :: Int -> DescribeStandards -> ShowS
Prelude.Show, (forall x. DescribeStandards -> Rep DescribeStandards x)
-> (forall x. Rep DescribeStandards x -> DescribeStandards)
-> Generic DescribeStandards
forall x. Rep DescribeStandards x -> DescribeStandards
forall x. DescribeStandards -> Rep DescribeStandards x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribeStandards x -> DescribeStandards
$cfrom :: forall x. DescribeStandards -> Rep DescribeStandards x
Prelude.Generic)

-- |
-- Create a value of 'DescribeStandards' 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:
--
-- 'nextToken', 'describeStandards_nextToken' - The token that is required for pagination. On your first call to the
-- @DescribeStandards@ operation, set the value of this parameter to
-- @NULL@.
--
-- For subsequent calls to the operation, to continue listing data, set the
-- value of this parameter to the value returned from the previous
-- response.
--
-- 'maxResults', 'describeStandards_maxResults' - The maximum number of standards to return.
newDescribeStandards ::
  DescribeStandards
newDescribeStandards :: DescribeStandards
newDescribeStandards =
  DescribeStandards' :: Maybe Text -> Maybe Natural -> DescribeStandards
DescribeStandards'
    { $sel:nextToken:DescribeStandards' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:maxResults:DescribeStandards' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
    }

-- | The token that is required for pagination. On your first call to the
-- @DescribeStandards@ operation, set the value of this parameter to
-- @NULL@.
--
-- For subsequent calls to the operation, to continue listing data, set the
-- value of this parameter to the value returned from the previous
-- response.
describeStandards_nextToken :: Lens.Lens' DescribeStandards (Prelude.Maybe Prelude.Text)
describeStandards_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeStandards -> f DescribeStandards
describeStandards_nextToken = (DescribeStandards -> Maybe Text)
-> (DescribeStandards -> Maybe Text -> DescribeStandards)
-> Lens
     DescribeStandards DescribeStandards (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeStandards' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeStandards' :: DescribeStandards -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeStandards
s@DescribeStandards' {} Maybe Text
a -> DescribeStandards
s {$sel:nextToken:DescribeStandards' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeStandards)

-- | The maximum number of standards to return.
describeStandards_maxResults :: Lens.Lens' DescribeStandards (Prelude.Maybe Prelude.Natural)
describeStandards_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> DescribeStandards -> f DescribeStandards
describeStandards_maxResults = (DescribeStandards -> Maybe Natural)
-> (DescribeStandards -> Maybe Natural -> DescribeStandards)
-> Lens
     DescribeStandards DescribeStandards (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeStandards' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:DescribeStandards' :: DescribeStandards -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: DescribeStandards
s@DescribeStandards' {} Maybe Natural
a -> DescribeStandards
s {$sel:maxResults:DescribeStandards' :: Maybe Natural
maxResults = Maybe Natural
a} :: DescribeStandards)

instance Core.AWSPager DescribeStandards where
  page :: DescribeStandards
-> AWSResponse DescribeStandards -> Maybe DescribeStandards
page DescribeStandards
rq AWSResponse DescribeStandards
rs
    | Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse DescribeStandards
DescribeStandardsResponse
rs
            DescribeStandardsResponse
-> Getting (First Text) DescribeStandardsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeStandardsResponse
-> Const (First Text) DescribeStandardsResponse
Lens' DescribeStandardsResponse (Maybe Text)
describeStandardsResponse_nextToken
              ((Maybe Text -> Const (First Text) (Maybe Text))
 -> DescribeStandardsResponse
 -> Const (First Text) DescribeStandardsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeStandardsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe DescribeStandards
forall a. Maybe a
Prelude.Nothing
    | Maybe [Standard] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
        ( AWSResponse DescribeStandards
DescribeStandardsResponse
rs
            DescribeStandardsResponse
-> Getting (First [Standard]) DescribeStandardsResponse [Standard]
-> Maybe [Standard]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [Standard] -> Const (First [Standard]) (Maybe [Standard]))
-> DescribeStandardsResponse
-> Const (First [Standard]) DescribeStandardsResponse
Lens' DescribeStandardsResponse (Maybe [Standard])
describeStandardsResponse_standards
              ((Maybe [Standard] -> Const (First [Standard]) (Maybe [Standard]))
 -> DescribeStandardsResponse
 -> Const (First [Standard]) DescribeStandardsResponse)
-> (([Standard] -> Const (First [Standard]) [Standard])
    -> Maybe [Standard] -> Const (First [Standard]) (Maybe [Standard]))
-> Getting (First [Standard]) DescribeStandardsResponse [Standard]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([Standard] -> Const (First [Standard]) [Standard])
-> Maybe [Standard] -> Const (First [Standard]) (Maybe [Standard])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
        ) =
      Maybe DescribeStandards
forall a. Maybe a
Prelude.Nothing
    | Bool
Prelude.otherwise =
      DescribeStandards -> Maybe DescribeStandards
forall a. a -> Maybe a
Prelude.Just (DescribeStandards -> Maybe DescribeStandards)
-> DescribeStandards -> Maybe DescribeStandards
forall a b. (a -> b) -> a -> b
Prelude.$
        DescribeStandards
rq
          DescribeStandards
-> (DescribeStandards -> DescribeStandards) -> DescribeStandards
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> DescribeStandards -> Identity DescribeStandards
Lens DescribeStandards DescribeStandards (Maybe Text) (Maybe Text)
describeStandards_nextToken
          ((Maybe Text -> Identity (Maybe Text))
 -> DescribeStandards -> Identity DescribeStandards)
-> Maybe Text -> DescribeStandards -> DescribeStandards
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse DescribeStandards
DescribeStandardsResponse
rs
          DescribeStandardsResponse
-> Getting (First Text) DescribeStandardsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeStandardsResponse
-> Const (First Text) DescribeStandardsResponse
Lens' DescribeStandardsResponse (Maybe Text)
describeStandardsResponse_nextToken
            ((Maybe Text -> Const (First Text) (Maybe Text))
 -> DescribeStandardsResponse
 -> Const (First Text) DescribeStandardsResponse)
-> ((Text -> Const (First Text) Text)
    -> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeStandardsResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just

instance Core.AWSRequest DescribeStandards where
  type
    AWSResponse DescribeStandards =
      DescribeStandardsResponse
  request :: DescribeStandards -> Request DescribeStandards
request = Service -> DescribeStandards -> Request DescribeStandards
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
  response :: Logger
-> Service
-> Proxy DescribeStandards
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse DescribeStandards)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse DescribeStandards))
-> Logger
-> Service
-> Proxy DescribeStandards
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse DescribeStandards)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe [Standard] -> Maybe Text -> Int -> DescribeStandardsResponse
DescribeStandardsResponse'
            (Maybe [Standard]
 -> Maybe Text -> Int -> DescribeStandardsResponse)
-> Either String (Maybe [Standard])
-> Either String (Maybe Text -> Int -> DescribeStandardsResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe (Maybe [Standard]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Standards" Either String (Maybe (Maybe [Standard]))
-> Maybe [Standard] -> Either String (Maybe [Standard])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [Standard]
forall a. Monoid a => a
Prelude.mempty)
            Either String (Maybe Text -> Int -> DescribeStandardsResponse)
-> Either String (Maybe Text)
-> Either String (Int -> DescribeStandardsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"NextToken")
            Either String (Int -> DescribeStandardsResponse)
-> Either String Int -> Either String DescribeStandardsResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable DescribeStandards

instance Prelude.NFData DescribeStandards

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

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

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

-- | /See:/ 'newDescribeStandardsResponse' smart constructor.
data DescribeStandardsResponse = DescribeStandardsResponse'
  { -- | A list of available standards.
    DescribeStandardsResponse -> Maybe [Standard]
standards :: Prelude.Maybe [Standard],
    -- | The pagination token to use to request the next page of results.
    DescribeStandardsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    DescribeStandardsResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (DescribeStandardsResponse -> DescribeStandardsResponse -> Bool
(DescribeStandardsResponse -> DescribeStandardsResponse -> Bool)
-> (DescribeStandardsResponse -> DescribeStandardsResponse -> Bool)
-> Eq DescribeStandardsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeStandardsResponse -> DescribeStandardsResponse -> Bool
$c/= :: DescribeStandardsResponse -> DescribeStandardsResponse -> Bool
== :: DescribeStandardsResponse -> DescribeStandardsResponse -> Bool
$c== :: DescribeStandardsResponse -> DescribeStandardsResponse -> Bool
Prelude.Eq, ReadPrec [DescribeStandardsResponse]
ReadPrec DescribeStandardsResponse
Int -> ReadS DescribeStandardsResponse
ReadS [DescribeStandardsResponse]
(Int -> ReadS DescribeStandardsResponse)
-> ReadS [DescribeStandardsResponse]
-> ReadPrec DescribeStandardsResponse
-> ReadPrec [DescribeStandardsResponse]
-> Read DescribeStandardsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeStandardsResponse]
$creadListPrec :: ReadPrec [DescribeStandardsResponse]
readPrec :: ReadPrec DescribeStandardsResponse
$creadPrec :: ReadPrec DescribeStandardsResponse
readList :: ReadS [DescribeStandardsResponse]
$creadList :: ReadS [DescribeStandardsResponse]
readsPrec :: Int -> ReadS DescribeStandardsResponse
$creadsPrec :: Int -> ReadS DescribeStandardsResponse
Prelude.Read, Int -> DescribeStandardsResponse -> ShowS
[DescribeStandardsResponse] -> ShowS
DescribeStandardsResponse -> String
(Int -> DescribeStandardsResponse -> ShowS)
-> (DescribeStandardsResponse -> String)
-> ([DescribeStandardsResponse] -> ShowS)
-> Show DescribeStandardsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeStandardsResponse] -> ShowS
$cshowList :: [DescribeStandardsResponse] -> ShowS
show :: DescribeStandardsResponse -> String
$cshow :: DescribeStandardsResponse -> String
showsPrec :: Int -> DescribeStandardsResponse -> ShowS
$cshowsPrec :: Int -> DescribeStandardsResponse -> ShowS
Prelude.Show, (forall x.
 DescribeStandardsResponse -> Rep DescribeStandardsResponse x)
-> (forall x.
    Rep DescribeStandardsResponse x -> DescribeStandardsResponse)
-> Generic DescribeStandardsResponse
forall x.
Rep DescribeStandardsResponse x -> DescribeStandardsResponse
forall x.
DescribeStandardsResponse -> Rep DescribeStandardsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeStandardsResponse x -> DescribeStandardsResponse
$cfrom :: forall x.
DescribeStandardsResponse -> Rep DescribeStandardsResponse x
Prelude.Generic)

-- |
-- Create a value of 'DescribeStandardsResponse' 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:
--
-- 'standards', 'describeStandardsResponse_standards' - A list of available standards.
--
-- 'nextToken', 'describeStandardsResponse_nextToken' - The pagination token to use to request the next page of results.
--
-- 'httpStatus', 'describeStandardsResponse_httpStatus' - The response's http status code.
newDescribeStandardsResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  DescribeStandardsResponse
newDescribeStandardsResponse :: Int -> DescribeStandardsResponse
newDescribeStandardsResponse Int
pHttpStatus_ =
  DescribeStandardsResponse' :: Maybe [Standard] -> Maybe Text -> Int -> DescribeStandardsResponse
DescribeStandardsResponse'
    { $sel:standards:DescribeStandardsResponse' :: Maybe [Standard]
standards =
        Maybe [Standard]
forall a. Maybe a
Prelude.Nothing,
      $sel:nextToken:DescribeStandardsResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:DescribeStandardsResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | A list of available standards.
describeStandardsResponse_standards :: Lens.Lens' DescribeStandardsResponse (Prelude.Maybe [Standard])
describeStandardsResponse_standards :: (Maybe [Standard] -> f (Maybe [Standard]))
-> DescribeStandardsResponse -> f DescribeStandardsResponse
describeStandardsResponse_standards = (DescribeStandardsResponse -> Maybe [Standard])
-> (DescribeStandardsResponse
    -> Maybe [Standard] -> DescribeStandardsResponse)
-> Lens' DescribeStandardsResponse (Maybe [Standard])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeStandardsResponse' {Maybe [Standard]
standards :: Maybe [Standard]
$sel:standards:DescribeStandardsResponse' :: DescribeStandardsResponse -> Maybe [Standard]
standards} -> Maybe [Standard]
standards) (\s :: DescribeStandardsResponse
s@DescribeStandardsResponse' {} Maybe [Standard]
a -> DescribeStandardsResponse
s {$sel:standards:DescribeStandardsResponse' :: Maybe [Standard]
standards = Maybe [Standard]
a} :: DescribeStandardsResponse) ((Maybe [Standard] -> f (Maybe [Standard]))
 -> DescribeStandardsResponse -> f DescribeStandardsResponse)
-> ((Maybe [Standard] -> f (Maybe [Standard]))
    -> Maybe [Standard] -> f (Maybe [Standard]))
-> (Maybe [Standard] -> f (Maybe [Standard]))
-> DescribeStandardsResponse
-> f DescribeStandardsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Standard] [Standard] [Standard] [Standard]
-> Iso
     (Maybe [Standard])
     (Maybe [Standard])
     (Maybe [Standard])
     (Maybe [Standard])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Standard] [Standard] [Standard] [Standard]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The pagination token to use to request the next page of results.
describeStandardsResponse_nextToken :: Lens.Lens' DescribeStandardsResponse (Prelude.Maybe Prelude.Text)
describeStandardsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeStandardsResponse -> f DescribeStandardsResponse
describeStandardsResponse_nextToken = (DescribeStandardsResponse -> Maybe Text)
-> (DescribeStandardsResponse
    -> Maybe Text -> DescribeStandardsResponse)
-> Lens' DescribeStandardsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeStandardsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeStandardsResponse' :: DescribeStandardsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeStandardsResponse
s@DescribeStandardsResponse' {} Maybe Text
a -> DescribeStandardsResponse
s {$sel:nextToken:DescribeStandardsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeStandardsResponse)

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

instance Prelude.NFData DescribeStandardsResponse