{-# 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.Support.DescribeTrustedAdvisorCheckResult
-- 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 results of the AWS Trusted Advisor check that has the
-- specified check ID. You can get the check IDs by calling the
-- DescribeTrustedAdvisorChecks operation.
--
-- The response contains a TrustedAdvisorCheckResult object, which contains
-- these three objects:
--
-- -   TrustedAdvisorCategorySpecificSummary
--
-- -   TrustedAdvisorResourceDetail
--
-- -   TrustedAdvisorResourcesSummary
--
-- In addition, the response contains these fields:
--
-- -   __status__ - The alert status of the check can be @ok@ (green),
--     @warning@ (yellow), @error@ (red), or @not_available@.
--
-- -   __timestamp__ - The time of the last refresh of the check.
--
-- -   __checkId__ - The unique identifier for the check.
--
-- -   You must have a Business or Enterprise Support plan to use the AWS
--     Support API.
--
-- -   If you call the AWS Support API from an account that does not have a
--     Business or Enterprise Support plan, the
--     @SubscriptionRequiredException@ error message appears. For
--     information about changing your support plan, see
--     <http://aws.amazon.com/premiumsupport/ AWS Support>.
module Amazonka.Support.DescribeTrustedAdvisorCheckResult
  ( -- * Creating a Request
    DescribeTrustedAdvisorCheckResult (..),
    newDescribeTrustedAdvisorCheckResult,

    -- * Request Lenses
    describeTrustedAdvisorCheckResult_language,
    describeTrustedAdvisorCheckResult_checkId,

    -- * Destructuring the Response
    DescribeTrustedAdvisorCheckResultResponse (..),
    newDescribeTrustedAdvisorCheckResultResponse,

    -- * Response Lenses
    describeTrustedAdvisorCheckResultResponse_result,
    describeTrustedAdvisorCheckResultResponse_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.Support.Types

-- |
--
-- /See:/ 'newDescribeTrustedAdvisorCheckResult' smart constructor.
data DescribeTrustedAdvisorCheckResult = DescribeTrustedAdvisorCheckResult'
  { -- | The ISO 639-1 code for the language in which AWS provides support. AWS
    -- Support currently supports English (\"en\") and Japanese (\"ja\").
    -- Language parameters must be passed explicitly for operations that take
    -- them.
    DescribeTrustedAdvisorCheckResult -> Maybe Text
language :: Prelude.Maybe Prelude.Text,
    -- | The unique identifier for the Trusted Advisor check.
    DescribeTrustedAdvisorCheckResult -> Text
checkId :: Prelude.Text
  }
  deriving (DescribeTrustedAdvisorCheckResult
-> DescribeTrustedAdvisorCheckResult -> Bool
(DescribeTrustedAdvisorCheckResult
 -> DescribeTrustedAdvisorCheckResult -> Bool)
-> (DescribeTrustedAdvisorCheckResult
    -> DescribeTrustedAdvisorCheckResult -> Bool)
-> Eq DescribeTrustedAdvisorCheckResult
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeTrustedAdvisorCheckResult
-> DescribeTrustedAdvisorCheckResult -> Bool
$c/= :: DescribeTrustedAdvisorCheckResult
-> DescribeTrustedAdvisorCheckResult -> Bool
== :: DescribeTrustedAdvisorCheckResult
-> DescribeTrustedAdvisorCheckResult -> Bool
$c== :: DescribeTrustedAdvisorCheckResult
-> DescribeTrustedAdvisorCheckResult -> Bool
Prelude.Eq, ReadPrec [DescribeTrustedAdvisorCheckResult]
ReadPrec DescribeTrustedAdvisorCheckResult
Int -> ReadS DescribeTrustedAdvisorCheckResult
ReadS [DescribeTrustedAdvisorCheckResult]
(Int -> ReadS DescribeTrustedAdvisorCheckResult)
-> ReadS [DescribeTrustedAdvisorCheckResult]
-> ReadPrec DescribeTrustedAdvisorCheckResult
-> ReadPrec [DescribeTrustedAdvisorCheckResult]
-> Read DescribeTrustedAdvisorCheckResult
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeTrustedAdvisorCheckResult]
$creadListPrec :: ReadPrec [DescribeTrustedAdvisorCheckResult]
readPrec :: ReadPrec DescribeTrustedAdvisorCheckResult
$creadPrec :: ReadPrec DescribeTrustedAdvisorCheckResult
readList :: ReadS [DescribeTrustedAdvisorCheckResult]
$creadList :: ReadS [DescribeTrustedAdvisorCheckResult]
readsPrec :: Int -> ReadS DescribeTrustedAdvisorCheckResult
$creadsPrec :: Int -> ReadS DescribeTrustedAdvisorCheckResult
Prelude.Read, Int -> DescribeTrustedAdvisorCheckResult -> ShowS
[DescribeTrustedAdvisorCheckResult] -> ShowS
DescribeTrustedAdvisorCheckResult -> String
(Int -> DescribeTrustedAdvisorCheckResult -> ShowS)
-> (DescribeTrustedAdvisorCheckResult -> String)
-> ([DescribeTrustedAdvisorCheckResult] -> ShowS)
-> Show DescribeTrustedAdvisorCheckResult
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeTrustedAdvisorCheckResult] -> ShowS
$cshowList :: [DescribeTrustedAdvisorCheckResult] -> ShowS
show :: DescribeTrustedAdvisorCheckResult -> String
$cshow :: DescribeTrustedAdvisorCheckResult -> String
showsPrec :: Int -> DescribeTrustedAdvisorCheckResult -> ShowS
$cshowsPrec :: Int -> DescribeTrustedAdvisorCheckResult -> ShowS
Prelude.Show, (forall x.
 DescribeTrustedAdvisorCheckResult
 -> Rep DescribeTrustedAdvisorCheckResult x)
-> (forall x.
    Rep DescribeTrustedAdvisorCheckResult x
    -> DescribeTrustedAdvisorCheckResult)
-> Generic DescribeTrustedAdvisorCheckResult
forall x.
Rep DescribeTrustedAdvisorCheckResult x
-> DescribeTrustedAdvisorCheckResult
forall x.
DescribeTrustedAdvisorCheckResult
-> Rep DescribeTrustedAdvisorCheckResult x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeTrustedAdvisorCheckResult x
-> DescribeTrustedAdvisorCheckResult
$cfrom :: forall x.
DescribeTrustedAdvisorCheckResult
-> Rep DescribeTrustedAdvisorCheckResult x
Prelude.Generic)

-- |
-- Create a value of 'DescribeTrustedAdvisorCheckResult' 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:
--
-- 'language', 'describeTrustedAdvisorCheckResult_language' - The ISO 639-1 code for the language in which AWS provides support. AWS
-- Support currently supports English (\"en\") and Japanese (\"ja\").
-- Language parameters must be passed explicitly for operations that take
-- them.
--
-- 'checkId', 'describeTrustedAdvisorCheckResult_checkId' - The unique identifier for the Trusted Advisor check.
newDescribeTrustedAdvisorCheckResult ::
  -- | 'checkId'
  Prelude.Text ->
  DescribeTrustedAdvisorCheckResult
newDescribeTrustedAdvisorCheckResult :: Text -> DescribeTrustedAdvisorCheckResult
newDescribeTrustedAdvisorCheckResult Text
pCheckId_ =
  DescribeTrustedAdvisorCheckResult' :: Maybe Text -> Text -> DescribeTrustedAdvisorCheckResult
DescribeTrustedAdvisorCheckResult'
    { $sel:language:DescribeTrustedAdvisorCheckResult' :: Maybe Text
language =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:checkId:DescribeTrustedAdvisorCheckResult' :: Text
checkId = Text
pCheckId_
    }

-- | The ISO 639-1 code for the language in which AWS provides support. AWS
-- Support currently supports English (\"en\") and Japanese (\"ja\").
-- Language parameters must be passed explicitly for operations that take
-- them.
describeTrustedAdvisorCheckResult_language :: Lens.Lens' DescribeTrustedAdvisorCheckResult (Prelude.Maybe Prelude.Text)
describeTrustedAdvisorCheckResult_language :: (Maybe Text -> f (Maybe Text))
-> DescribeTrustedAdvisorCheckResult
-> f DescribeTrustedAdvisorCheckResult
describeTrustedAdvisorCheckResult_language = (DescribeTrustedAdvisorCheckResult -> Maybe Text)
-> (DescribeTrustedAdvisorCheckResult
    -> Maybe Text -> DescribeTrustedAdvisorCheckResult)
-> Lens
     DescribeTrustedAdvisorCheckResult
     DescribeTrustedAdvisorCheckResult
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeTrustedAdvisorCheckResult' {Maybe Text
language :: Maybe Text
$sel:language:DescribeTrustedAdvisorCheckResult' :: DescribeTrustedAdvisorCheckResult -> Maybe Text
language} -> Maybe Text
language) (\s :: DescribeTrustedAdvisorCheckResult
s@DescribeTrustedAdvisorCheckResult' {} Maybe Text
a -> DescribeTrustedAdvisorCheckResult
s {$sel:language:DescribeTrustedAdvisorCheckResult' :: Maybe Text
language = Maybe Text
a} :: DescribeTrustedAdvisorCheckResult)

-- | The unique identifier for the Trusted Advisor check.
describeTrustedAdvisorCheckResult_checkId :: Lens.Lens' DescribeTrustedAdvisorCheckResult Prelude.Text
describeTrustedAdvisorCheckResult_checkId :: (Text -> f Text)
-> DescribeTrustedAdvisorCheckResult
-> f DescribeTrustedAdvisorCheckResult
describeTrustedAdvisorCheckResult_checkId = (DescribeTrustedAdvisorCheckResult -> Text)
-> (DescribeTrustedAdvisorCheckResult
    -> Text -> DescribeTrustedAdvisorCheckResult)
-> Lens
     DescribeTrustedAdvisorCheckResult
     DescribeTrustedAdvisorCheckResult
     Text
     Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeTrustedAdvisorCheckResult' {Text
checkId :: Text
$sel:checkId:DescribeTrustedAdvisorCheckResult' :: DescribeTrustedAdvisorCheckResult -> Text
checkId} -> Text
checkId) (\s :: DescribeTrustedAdvisorCheckResult
s@DescribeTrustedAdvisorCheckResult' {} Text
a -> DescribeTrustedAdvisorCheckResult
s {$sel:checkId:DescribeTrustedAdvisorCheckResult' :: Text
checkId = Text
a} :: DescribeTrustedAdvisorCheckResult)

instance
  Core.AWSRequest
    DescribeTrustedAdvisorCheckResult
  where
  type
    AWSResponse DescribeTrustedAdvisorCheckResult =
      DescribeTrustedAdvisorCheckResultResponse
  request :: DescribeTrustedAdvisorCheckResult
-> Request DescribeTrustedAdvisorCheckResult
request = Service
-> DescribeTrustedAdvisorCheckResult
-> Request DescribeTrustedAdvisorCheckResult
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy DescribeTrustedAdvisorCheckResult
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse DescribeTrustedAdvisorCheckResult)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse DescribeTrustedAdvisorCheckResult))
-> Logger
-> Service
-> Proxy DescribeTrustedAdvisorCheckResult
-> ClientResponse ClientBody
-> m (Either
        Error
        (ClientResponse (AWSResponse DescribeTrustedAdvisorCheckResult)))
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 TrustedAdvisorCheckResult
-> Int -> DescribeTrustedAdvisorCheckResultResponse
DescribeTrustedAdvisorCheckResultResponse'
            (Maybe TrustedAdvisorCheckResult
 -> Int -> DescribeTrustedAdvisorCheckResultResponse)
-> Either String (Maybe TrustedAdvisorCheckResult)
-> Either String (Int -> DescribeTrustedAdvisorCheckResultResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe TrustedAdvisorCheckResult)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"result")
              Either String (Int -> DescribeTrustedAdvisorCheckResultResponse)
-> Either String Int
-> Either String DescribeTrustedAdvisorCheckResultResponse
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
    DescribeTrustedAdvisorCheckResult

instance
  Prelude.NFData
    DescribeTrustedAdvisorCheckResult

instance
  Core.ToHeaders
    DescribeTrustedAdvisorCheckResult
  where
  toHeaders :: DescribeTrustedAdvisorCheckResult -> ResponseHeaders
toHeaders =
    ResponseHeaders
-> DescribeTrustedAdvisorCheckResult -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"X-Amz-Target"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWSSupport_20130415.DescribeTrustedAdvisorCheckResult" ::
                          Prelude.ByteString
                      ),
            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.ToJSON
    DescribeTrustedAdvisorCheckResult
  where
  toJSON :: DescribeTrustedAdvisorCheckResult -> Value
toJSON DescribeTrustedAdvisorCheckResult' {Maybe Text
Text
checkId :: Text
language :: Maybe Text
$sel:checkId:DescribeTrustedAdvisorCheckResult' :: DescribeTrustedAdvisorCheckResult -> Text
$sel:language:DescribeTrustedAdvisorCheckResult' :: DescribeTrustedAdvisorCheckResult -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"language" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
language,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"checkId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
checkId)
          ]
      )

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

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

-- | The result of the Trusted Advisor check returned by the
-- DescribeTrustedAdvisorCheckResult operation.
--
-- /See:/ 'newDescribeTrustedAdvisorCheckResultResponse' smart constructor.
data DescribeTrustedAdvisorCheckResultResponse = DescribeTrustedAdvisorCheckResultResponse'
  { -- | The detailed results of the Trusted Advisor check.
    DescribeTrustedAdvisorCheckResultResponse
-> Maybe TrustedAdvisorCheckResult
result :: Prelude.Maybe TrustedAdvisorCheckResult,
    -- | The response's http status code.
    DescribeTrustedAdvisorCheckResultResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (DescribeTrustedAdvisorCheckResultResponse
-> DescribeTrustedAdvisorCheckResultResponse -> Bool
(DescribeTrustedAdvisorCheckResultResponse
 -> DescribeTrustedAdvisorCheckResultResponse -> Bool)
-> (DescribeTrustedAdvisorCheckResultResponse
    -> DescribeTrustedAdvisorCheckResultResponse -> Bool)
-> Eq DescribeTrustedAdvisorCheckResultResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeTrustedAdvisorCheckResultResponse
-> DescribeTrustedAdvisorCheckResultResponse -> Bool
$c/= :: DescribeTrustedAdvisorCheckResultResponse
-> DescribeTrustedAdvisorCheckResultResponse -> Bool
== :: DescribeTrustedAdvisorCheckResultResponse
-> DescribeTrustedAdvisorCheckResultResponse -> Bool
$c== :: DescribeTrustedAdvisorCheckResultResponse
-> DescribeTrustedAdvisorCheckResultResponse -> Bool
Prelude.Eq, ReadPrec [DescribeTrustedAdvisorCheckResultResponse]
ReadPrec DescribeTrustedAdvisorCheckResultResponse
Int -> ReadS DescribeTrustedAdvisorCheckResultResponse
ReadS [DescribeTrustedAdvisorCheckResultResponse]
(Int -> ReadS DescribeTrustedAdvisorCheckResultResponse)
-> ReadS [DescribeTrustedAdvisorCheckResultResponse]
-> ReadPrec DescribeTrustedAdvisorCheckResultResponse
-> ReadPrec [DescribeTrustedAdvisorCheckResultResponse]
-> Read DescribeTrustedAdvisorCheckResultResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeTrustedAdvisorCheckResultResponse]
$creadListPrec :: ReadPrec [DescribeTrustedAdvisorCheckResultResponse]
readPrec :: ReadPrec DescribeTrustedAdvisorCheckResultResponse
$creadPrec :: ReadPrec DescribeTrustedAdvisorCheckResultResponse
readList :: ReadS [DescribeTrustedAdvisorCheckResultResponse]
$creadList :: ReadS [DescribeTrustedAdvisorCheckResultResponse]
readsPrec :: Int -> ReadS DescribeTrustedAdvisorCheckResultResponse
$creadsPrec :: Int -> ReadS DescribeTrustedAdvisorCheckResultResponse
Prelude.Read, Int -> DescribeTrustedAdvisorCheckResultResponse -> ShowS
[DescribeTrustedAdvisorCheckResultResponse] -> ShowS
DescribeTrustedAdvisorCheckResultResponse -> String
(Int -> DescribeTrustedAdvisorCheckResultResponse -> ShowS)
-> (DescribeTrustedAdvisorCheckResultResponse -> String)
-> ([DescribeTrustedAdvisorCheckResultResponse] -> ShowS)
-> Show DescribeTrustedAdvisorCheckResultResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeTrustedAdvisorCheckResultResponse] -> ShowS
$cshowList :: [DescribeTrustedAdvisorCheckResultResponse] -> ShowS
show :: DescribeTrustedAdvisorCheckResultResponse -> String
$cshow :: DescribeTrustedAdvisorCheckResultResponse -> String
showsPrec :: Int -> DescribeTrustedAdvisorCheckResultResponse -> ShowS
$cshowsPrec :: Int -> DescribeTrustedAdvisorCheckResultResponse -> ShowS
Prelude.Show, (forall x.
 DescribeTrustedAdvisorCheckResultResponse
 -> Rep DescribeTrustedAdvisorCheckResultResponse x)
-> (forall x.
    Rep DescribeTrustedAdvisorCheckResultResponse x
    -> DescribeTrustedAdvisorCheckResultResponse)
-> Generic DescribeTrustedAdvisorCheckResultResponse
forall x.
Rep DescribeTrustedAdvisorCheckResultResponse x
-> DescribeTrustedAdvisorCheckResultResponse
forall x.
DescribeTrustedAdvisorCheckResultResponse
-> Rep DescribeTrustedAdvisorCheckResultResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeTrustedAdvisorCheckResultResponse x
-> DescribeTrustedAdvisorCheckResultResponse
$cfrom :: forall x.
DescribeTrustedAdvisorCheckResultResponse
-> Rep DescribeTrustedAdvisorCheckResultResponse x
Prelude.Generic)

-- |
-- Create a value of 'DescribeTrustedAdvisorCheckResultResponse' 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:
--
-- 'result', 'describeTrustedAdvisorCheckResultResponse_result' - The detailed results of the Trusted Advisor check.
--
-- 'httpStatus', 'describeTrustedAdvisorCheckResultResponse_httpStatus' - The response's http status code.
newDescribeTrustedAdvisorCheckResultResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  DescribeTrustedAdvisorCheckResultResponse
newDescribeTrustedAdvisorCheckResultResponse :: Int -> DescribeTrustedAdvisorCheckResultResponse
newDescribeTrustedAdvisorCheckResultResponse
  Int
pHttpStatus_ =
    DescribeTrustedAdvisorCheckResultResponse' :: Maybe TrustedAdvisorCheckResult
-> Int -> DescribeTrustedAdvisorCheckResultResponse
DescribeTrustedAdvisorCheckResultResponse'
      { $sel:result:DescribeTrustedAdvisorCheckResultResponse' :: Maybe TrustedAdvisorCheckResult
result =
          Maybe TrustedAdvisorCheckResult
forall a. Maybe a
Prelude.Nothing,
        $sel:httpStatus:DescribeTrustedAdvisorCheckResultResponse' :: Int
httpStatus = Int
pHttpStatus_
      }

-- | The detailed results of the Trusted Advisor check.
describeTrustedAdvisorCheckResultResponse_result :: Lens.Lens' DescribeTrustedAdvisorCheckResultResponse (Prelude.Maybe TrustedAdvisorCheckResult)
describeTrustedAdvisorCheckResultResponse_result :: (Maybe TrustedAdvisorCheckResult
 -> f (Maybe TrustedAdvisorCheckResult))
-> DescribeTrustedAdvisorCheckResultResponse
-> f DescribeTrustedAdvisorCheckResultResponse
describeTrustedAdvisorCheckResultResponse_result = (DescribeTrustedAdvisorCheckResultResponse
 -> Maybe TrustedAdvisorCheckResult)
-> (DescribeTrustedAdvisorCheckResultResponse
    -> Maybe TrustedAdvisorCheckResult
    -> DescribeTrustedAdvisorCheckResultResponse)
-> Lens
     DescribeTrustedAdvisorCheckResultResponse
     DescribeTrustedAdvisorCheckResultResponse
     (Maybe TrustedAdvisorCheckResult)
     (Maybe TrustedAdvisorCheckResult)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeTrustedAdvisorCheckResultResponse' {Maybe TrustedAdvisorCheckResult
result :: Maybe TrustedAdvisorCheckResult
$sel:result:DescribeTrustedAdvisorCheckResultResponse' :: DescribeTrustedAdvisorCheckResultResponse
-> Maybe TrustedAdvisorCheckResult
result} -> Maybe TrustedAdvisorCheckResult
result) (\s :: DescribeTrustedAdvisorCheckResultResponse
s@DescribeTrustedAdvisorCheckResultResponse' {} Maybe TrustedAdvisorCheckResult
a -> DescribeTrustedAdvisorCheckResultResponse
s {$sel:result:DescribeTrustedAdvisorCheckResultResponse' :: Maybe TrustedAdvisorCheckResult
result = Maybe TrustedAdvisorCheckResult
a} :: DescribeTrustedAdvisorCheckResultResponse)

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

instance
  Prelude.NFData
    DescribeTrustedAdvisorCheckResultResponse