{-# 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.GetFindingAggregator
-- 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 the current finding aggregation configuration.
module Amazonka.SecurityHub.GetFindingAggregator
  ( -- * Creating a Request
    GetFindingAggregator (..),
    newGetFindingAggregator,

    -- * Request Lenses
    getFindingAggregator_findingAggregatorArn,

    -- * Destructuring the Response
    GetFindingAggregatorResponse (..),
    newGetFindingAggregatorResponse,

    -- * Response Lenses
    getFindingAggregatorResponse_regions,
    getFindingAggregatorResponse_findingAggregatorArn,
    getFindingAggregatorResponse_regionLinkingMode,
    getFindingAggregatorResponse_findingAggregationRegion,
    getFindingAggregatorResponse_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:/ 'newGetFindingAggregator' smart constructor.
data GetFindingAggregator = GetFindingAggregator'
  { -- | The ARN of the finding aggregator to return details for. To obtain the
    -- ARN, use @ListFindingAggregators@.
    GetFindingAggregator -> Text
findingAggregatorArn :: Prelude.Text
  }
  deriving (GetFindingAggregator -> GetFindingAggregator -> Bool
(GetFindingAggregator -> GetFindingAggregator -> Bool)
-> (GetFindingAggregator -> GetFindingAggregator -> Bool)
-> Eq GetFindingAggregator
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetFindingAggregator -> GetFindingAggregator -> Bool
$c/= :: GetFindingAggregator -> GetFindingAggregator -> Bool
== :: GetFindingAggregator -> GetFindingAggregator -> Bool
$c== :: GetFindingAggregator -> GetFindingAggregator -> Bool
Prelude.Eq, ReadPrec [GetFindingAggregator]
ReadPrec GetFindingAggregator
Int -> ReadS GetFindingAggregator
ReadS [GetFindingAggregator]
(Int -> ReadS GetFindingAggregator)
-> ReadS [GetFindingAggregator]
-> ReadPrec GetFindingAggregator
-> ReadPrec [GetFindingAggregator]
-> Read GetFindingAggregator
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetFindingAggregator]
$creadListPrec :: ReadPrec [GetFindingAggregator]
readPrec :: ReadPrec GetFindingAggregator
$creadPrec :: ReadPrec GetFindingAggregator
readList :: ReadS [GetFindingAggregator]
$creadList :: ReadS [GetFindingAggregator]
readsPrec :: Int -> ReadS GetFindingAggregator
$creadsPrec :: Int -> ReadS GetFindingAggregator
Prelude.Read, Int -> GetFindingAggregator -> ShowS
[GetFindingAggregator] -> ShowS
GetFindingAggregator -> String
(Int -> GetFindingAggregator -> ShowS)
-> (GetFindingAggregator -> String)
-> ([GetFindingAggregator] -> ShowS)
-> Show GetFindingAggregator
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetFindingAggregator] -> ShowS
$cshowList :: [GetFindingAggregator] -> ShowS
show :: GetFindingAggregator -> String
$cshow :: GetFindingAggregator -> String
showsPrec :: Int -> GetFindingAggregator -> ShowS
$cshowsPrec :: Int -> GetFindingAggregator -> ShowS
Prelude.Show, (forall x. GetFindingAggregator -> Rep GetFindingAggregator x)
-> (forall x. Rep GetFindingAggregator x -> GetFindingAggregator)
-> Generic GetFindingAggregator
forall x. Rep GetFindingAggregator x -> GetFindingAggregator
forall x. GetFindingAggregator -> Rep GetFindingAggregator x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GetFindingAggregator x -> GetFindingAggregator
$cfrom :: forall x. GetFindingAggregator -> Rep GetFindingAggregator x
Prelude.Generic)

-- |
-- Create a value of 'GetFindingAggregator' 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:
--
-- 'findingAggregatorArn', 'getFindingAggregator_findingAggregatorArn' - The ARN of the finding aggregator to return details for. To obtain the
-- ARN, use @ListFindingAggregators@.
newGetFindingAggregator ::
  -- | 'findingAggregatorArn'
  Prelude.Text ->
  GetFindingAggregator
newGetFindingAggregator :: Text -> GetFindingAggregator
newGetFindingAggregator Text
pFindingAggregatorArn_ =
  GetFindingAggregator' :: Text -> GetFindingAggregator
GetFindingAggregator'
    { $sel:findingAggregatorArn:GetFindingAggregator' :: Text
findingAggregatorArn =
        Text
pFindingAggregatorArn_
    }

-- | The ARN of the finding aggregator to return details for. To obtain the
-- ARN, use @ListFindingAggregators@.
getFindingAggregator_findingAggregatorArn :: Lens.Lens' GetFindingAggregator Prelude.Text
getFindingAggregator_findingAggregatorArn :: (Text -> f Text) -> GetFindingAggregator -> f GetFindingAggregator
getFindingAggregator_findingAggregatorArn = (GetFindingAggregator -> Text)
-> (GetFindingAggregator -> Text -> GetFindingAggregator)
-> Lens GetFindingAggregator GetFindingAggregator Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetFindingAggregator' {Text
findingAggregatorArn :: Text
$sel:findingAggregatorArn:GetFindingAggregator' :: GetFindingAggregator -> Text
findingAggregatorArn} -> Text
findingAggregatorArn) (\s :: GetFindingAggregator
s@GetFindingAggregator' {} Text
a -> GetFindingAggregator
s {$sel:findingAggregatorArn:GetFindingAggregator' :: Text
findingAggregatorArn = Text
a} :: GetFindingAggregator)

instance Core.AWSRequest GetFindingAggregator where
  type
    AWSResponse GetFindingAggregator =
      GetFindingAggregatorResponse
  request :: GetFindingAggregator -> Request GetFindingAggregator
request = Service -> GetFindingAggregator -> Request GetFindingAggregator
forall a. ToRequest a => Service -> a -> Request a
Request.get Service
defaultService
  response :: Logger
-> Service
-> Proxy GetFindingAggregator
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse GetFindingAggregator)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse GetFindingAggregator))
-> Logger
-> Service
-> Proxy GetFindingAggregator
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse GetFindingAggregator)))
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 [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> GetFindingAggregatorResponse
GetFindingAggregatorResponse'
            (Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Int
 -> GetFindingAggregatorResponse)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Text
      -> Maybe Text -> Maybe Text -> Int -> GetFindingAggregatorResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe (Maybe [Text]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Regions" Either String (Maybe (Maybe [Text]))
-> Maybe [Text] -> Either String (Maybe [Text])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [Text]
forall a. Monoid a => a
Prelude.mempty)
            Either
  String
  (Maybe Text
   -> Maybe Text -> Maybe Text -> Int -> GetFindingAggregatorResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text -> Maybe Text -> Int -> GetFindingAggregatorResponse)
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
"FindingAggregatorArn")
            Either
  String
  (Maybe Text -> Maybe Text -> Int -> GetFindingAggregatorResponse)
-> Either String (Maybe Text)
-> Either
     String (Maybe Text -> Int -> GetFindingAggregatorResponse)
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
"RegionLinkingMode")
            Either String (Maybe Text -> Int -> GetFindingAggregatorResponse)
-> Either String (Maybe Text)
-> Either String (Int -> GetFindingAggregatorResponse)
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
"FindingAggregationRegion")
            Either String (Int -> GetFindingAggregatorResponse)
-> Either String Int -> Either String GetFindingAggregatorResponse
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 GetFindingAggregator

instance Prelude.NFData GetFindingAggregator

instance Core.ToHeaders GetFindingAggregator where
  toHeaders :: GetFindingAggregator -> ResponseHeaders
toHeaders =
    ResponseHeaders -> GetFindingAggregator -> 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 GetFindingAggregator where
  toPath :: GetFindingAggregator -> ByteString
toPath GetFindingAggregator' {Text
findingAggregatorArn :: Text
$sel:findingAggregatorArn:GetFindingAggregator' :: GetFindingAggregator -> Text
..} =
    [ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
      [ ByteString
"/findingAggregator/get/",
        Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
findingAggregatorArn
      ]

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

-- | /See:/ 'newGetFindingAggregatorResponse' smart constructor.
data GetFindingAggregatorResponse = GetFindingAggregatorResponse'
  { -- | The list of excluded Regions or included Regions.
    GetFindingAggregatorResponse -> Maybe [Text]
regions :: Prelude.Maybe [Prelude.Text],
    -- | The ARN of the finding aggregator.
    GetFindingAggregatorResponse -> Maybe Text
findingAggregatorArn :: Prelude.Maybe Prelude.Text,
    -- | Indicates whether to link all Regions, all Regions except for a list of
    -- excluded Regions, or a list of included Regions.
    GetFindingAggregatorResponse -> Maybe Text
regionLinkingMode :: Prelude.Maybe Prelude.Text,
    -- | The aggregation Region.
    GetFindingAggregatorResponse -> Maybe Text
findingAggregationRegion :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    GetFindingAggregatorResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (GetFindingAggregatorResponse
-> GetFindingAggregatorResponse -> Bool
(GetFindingAggregatorResponse
 -> GetFindingAggregatorResponse -> Bool)
-> (GetFindingAggregatorResponse
    -> GetFindingAggregatorResponse -> Bool)
-> Eq GetFindingAggregatorResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GetFindingAggregatorResponse
-> GetFindingAggregatorResponse -> Bool
$c/= :: GetFindingAggregatorResponse
-> GetFindingAggregatorResponse -> Bool
== :: GetFindingAggregatorResponse
-> GetFindingAggregatorResponse -> Bool
$c== :: GetFindingAggregatorResponse
-> GetFindingAggregatorResponse -> Bool
Prelude.Eq, ReadPrec [GetFindingAggregatorResponse]
ReadPrec GetFindingAggregatorResponse
Int -> ReadS GetFindingAggregatorResponse
ReadS [GetFindingAggregatorResponse]
(Int -> ReadS GetFindingAggregatorResponse)
-> ReadS [GetFindingAggregatorResponse]
-> ReadPrec GetFindingAggregatorResponse
-> ReadPrec [GetFindingAggregatorResponse]
-> Read GetFindingAggregatorResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GetFindingAggregatorResponse]
$creadListPrec :: ReadPrec [GetFindingAggregatorResponse]
readPrec :: ReadPrec GetFindingAggregatorResponse
$creadPrec :: ReadPrec GetFindingAggregatorResponse
readList :: ReadS [GetFindingAggregatorResponse]
$creadList :: ReadS [GetFindingAggregatorResponse]
readsPrec :: Int -> ReadS GetFindingAggregatorResponse
$creadsPrec :: Int -> ReadS GetFindingAggregatorResponse
Prelude.Read, Int -> GetFindingAggregatorResponse -> ShowS
[GetFindingAggregatorResponse] -> ShowS
GetFindingAggregatorResponse -> String
(Int -> GetFindingAggregatorResponse -> ShowS)
-> (GetFindingAggregatorResponse -> String)
-> ([GetFindingAggregatorResponse] -> ShowS)
-> Show GetFindingAggregatorResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GetFindingAggregatorResponse] -> ShowS
$cshowList :: [GetFindingAggregatorResponse] -> ShowS
show :: GetFindingAggregatorResponse -> String
$cshow :: GetFindingAggregatorResponse -> String
showsPrec :: Int -> GetFindingAggregatorResponse -> ShowS
$cshowsPrec :: Int -> GetFindingAggregatorResponse -> ShowS
Prelude.Show, (forall x.
 GetFindingAggregatorResponse -> Rep GetFindingAggregatorResponse x)
-> (forall x.
    Rep GetFindingAggregatorResponse x -> GetFindingAggregatorResponse)
-> Generic GetFindingAggregatorResponse
forall x.
Rep GetFindingAggregatorResponse x -> GetFindingAggregatorResponse
forall x.
GetFindingAggregatorResponse -> Rep GetFindingAggregatorResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep GetFindingAggregatorResponse x -> GetFindingAggregatorResponse
$cfrom :: forall x.
GetFindingAggregatorResponse -> Rep GetFindingAggregatorResponse x
Prelude.Generic)

-- |
-- Create a value of 'GetFindingAggregatorResponse' 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:
--
-- 'regions', 'getFindingAggregatorResponse_regions' - The list of excluded Regions or included Regions.
--
-- 'findingAggregatorArn', 'getFindingAggregatorResponse_findingAggregatorArn' - The ARN of the finding aggregator.
--
-- 'regionLinkingMode', 'getFindingAggregatorResponse_regionLinkingMode' - Indicates whether to link all Regions, all Regions except for a list of
-- excluded Regions, or a list of included Regions.
--
-- 'findingAggregationRegion', 'getFindingAggregatorResponse_findingAggregationRegion' - The aggregation Region.
--
-- 'httpStatus', 'getFindingAggregatorResponse_httpStatus' - The response's http status code.
newGetFindingAggregatorResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  GetFindingAggregatorResponse
newGetFindingAggregatorResponse :: Int -> GetFindingAggregatorResponse
newGetFindingAggregatorResponse Int
pHttpStatus_ =
  GetFindingAggregatorResponse' :: Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Int
-> GetFindingAggregatorResponse
GetFindingAggregatorResponse'
    { $sel:regions:GetFindingAggregatorResponse' :: Maybe [Text]
regions =
        Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:findingAggregatorArn:GetFindingAggregatorResponse' :: Maybe Text
findingAggregatorArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:regionLinkingMode:GetFindingAggregatorResponse' :: Maybe Text
regionLinkingMode = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:findingAggregationRegion:GetFindingAggregatorResponse' :: Maybe Text
findingAggregationRegion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:GetFindingAggregatorResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The list of excluded Regions or included Regions.
getFindingAggregatorResponse_regions :: Lens.Lens' GetFindingAggregatorResponse (Prelude.Maybe [Prelude.Text])
getFindingAggregatorResponse_regions :: (Maybe [Text] -> f (Maybe [Text]))
-> GetFindingAggregatorResponse -> f GetFindingAggregatorResponse
getFindingAggregatorResponse_regions = (GetFindingAggregatorResponse -> Maybe [Text])
-> (GetFindingAggregatorResponse
    -> Maybe [Text] -> GetFindingAggregatorResponse)
-> Lens
     GetFindingAggregatorResponse
     GetFindingAggregatorResponse
     (Maybe [Text])
     (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetFindingAggregatorResponse' {Maybe [Text]
regions :: Maybe [Text]
$sel:regions:GetFindingAggregatorResponse' :: GetFindingAggregatorResponse -> Maybe [Text]
regions} -> Maybe [Text]
regions) (\s :: GetFindingAggregatorResponse
s@GetFindingAggregatorResponse' {} Maybe [Text]
a -> GetFindingAggregatorResponse
s {$sel:regions:GetFindingAggregatorResponse' :: Maybe [Text]
regions = Maybe [Text]
a} :: GetFindingAggregatorResponse) ((Maybe [Text] -> f (Maybe [Text]))
 -> GetFindingAggregatorResponse -> f GetFindingAggregatorResponse)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> GetFindingAggregatorResponse
-> f GetFindingAggregatorResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ARN of the finding aggregator.
getFindingAggregatorResponse_findingAggregatorArn :: Lens.Lens' GetFindingAggregatorResponse (Prelude.Maybe Prelude.Text)
getFindingAggregatorResponse_findingAggregatorArn :: (Maybe Text -> f (Maybe Text))
-> GetFindingAggregatorResponse -> f GetFindingAggregatorResponse
getFindingAggregatorResponse_findingAggregatorArn = (GetFindingAggregatorResponse -> Maybe Text)
-> (GetFindingAggregatorResponse
    -> Maybe Text -> GetFindingAggregatorResponse)
-> Lens
     GetFindingAggregatorResponse
     GetFindingAggregatorResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetFindingAggregatorResponse' {Maybe Text
findingAggregatorArn :: Maybe Text
$sel:findingAggregatorArn:GetFindingAggregatorResponse' :: GetFindingAggregatorResponse -> Maybe Text
findingAggregatorArn} -> Maybe Text
findingAggregatorArn) (\s :: GetFindingAggregatorResponse
s@GetFindingAggregatorResponse' {} Maybe Text
a -> GetFindingAggregatorResponse
s {$sel:findingAggregatorArn:GetFindingAggregatorResponse' :: Maybe Text
findingAggregatorArn = Maybe Text
a} :: GetFindingAggregatorResponse)

-- | Indicates whether to link all Regions, all Regions except for a list of
-- excluded Regions, or a list of included Regions.
getFindingAggregatorResponse_regionLinkingMode :: Lens.Lens' GetFindingAggregatorResponse (Prelude.Maybe Prelude.Text)
getFindingAggregatorResponse_regionLinkingMode :: (Maybe Text -> f (Maybe Text))
-> GetFindingAggregatorResponse -> f GetFindingAggregatorResponse
getFindingAggregatorResponse_regionLinkingMode = (GetFindingAggregatorResponse -> Maybe Text)
-> (GetFindingAggregatorResponse
    -> Maybe Text -> GetFindingAggregatorResponse)
-> Lens
     GetFindingAggregatorResponse
     GetFindingAggregatorResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetFindingAggregatorResponse' {Maybe Text
regionLinkingMode :: Maybe Text
$sel:regionLinkingMode:GetFindingAggregatorResponse' :: GetFindingAggregatorResponse -> Maybe Text
regionLinkingMode} -> Maybe Text
regionLinkingMode) (\s :: GetFindingAggregatorResponse
s@GetFindingAggregatorResponse' {} Maybe Text
a -> GetFindingAggregatorResponse
s {$sel:regionLinkingMode:GetFindingAggregatorResponse' :: Maybe Text
regionLinkingMode = Maybe Text
a} :: GetFindingAggregatorResponse)

-- | The aggregation Region.
getFindingAggregatorResponse_findingAggregationRegion :: Lens.Lens' GetFindingAggregatorResponse (Prelude.Maybe Prelude.Text)
getFindingAggregatorResponse_findingAggregationRegion :: (Maybe Text -> f (Maybe Text))
-> GetFindingAggregatorResponse -> f GetFindingAggregatorResponse
getFindingAggregatorResponse_findingAggregationRegion = (GetFindingAggregatorResponse -> Maybe Text)
-> (GetFindingAggregatorResponse
    -> Maybe Text -> GetFindingAggregatorResponse)
-> Lens
     GetFindingAggregatorResponse
     GetFindingAggregatorResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GetFindingAggregatorResponse' {Maybe Text
findingAggregationRegion :: Maybe Text
$sel:findingAggregationRegion:GetFindingAggregatorResponse' :: GetFindingAggregatorResponse -> Maybe Text
findingAggregationRegion} -> Maybe Text
findingAggregationRegion) (\s :: GetFindingAggregatorResponse
s@GetFindingAggregatorResponse' {} Maybe Text
a -> GetFindingAggregatorResponse
s {$sel:findingAggregationRegion:GetFindingAggregatorResponse' :: Maybe Text
findingAggregationRegion = Maybe Text
a} :: GetFindingAggregatorResponse)

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

instance Prelude.NFData GetFindingAggregatorResponse