{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SSM.Types.ResourceComplianceSummaryItem
-- 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)
module Amazonka.SSM.Types.ResourceComplianceSummaryItem where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SSM.Types.ComplianceExecutionSummary
import Amazonka.SSM.Types.ComplianceSeverity
import Amazonka.SSM.Types.ComplianceStatus
import Amazonka.SSM.Types.CompliantSummary
import Amazonka.SSM.Types.NonCompliantSummary

-- | Compliance summary information for a specific resource.
--
-- /See:/ 'newResourceComplianceSummaryItem' smart constructor.
data ResourceComplianceSummaryItem = ResourceComplianceSummaryItem'
  { -- | A list of items that aren\'t compliant for the resource.
    ResourceComplianceSummaryItem -> Maybe NonCompliantSummary
nonCompliantSummary :: Prelude.Maybe NonCompliantSummary,
    -- | The compliance status for the resource.
    ResourceComplianceSummaryItem -> Maybe ComplianceStatus
status :: Prelude.Maybe ComplianceStatus,
    -- | The resource ID.
    ResourceComplianceSummaryItem -> Maybe Text
resourceId :: Prelude.Maybe Prelude.Text,
    -- | The resource type.
    ResourceComplianceSummaryItem -> Maybe Text
resourceType :: Prelude.Maybe Prelude.Text,
    -- | A list of items that are compliant for the resource.
    ResourceComplianceSummaryItem -> Maybe CompliantSummary
compliantSummary :: Prelude.Maybe CompliantSummary,
    -- | Information about the execution.
    ResourceComplianceSummaryItem -> Maybe ComplianceExecutionSummary
executionSummary :: Prelude.Maybe ComplianceExecutionSummary,
    -- | The highest severity item found for the resource. The resource is
    -- compliant for this item.
    ResourceComplianceSummaryItem -> Maybe ComplianceSeverity
overallSeverity :: Prelude.Maybe ComplianceSeverity,
    -- | The compliance type.
    ResourceComplianceSummaryItem -> Maybe Text
complianceType :: Prelude.Maybe Prelude.Text
  }
  deriving (ResourceComplianceSummaryItem
-> ResourceComplianceSummaryItem -> Bool
(ResourceComplianceSummaryItem
 -> ResourceComplianceSummaryItem -> Bool)
-> (ResourceComplianceSummaryItem
    -> ResourceComplianceSummaryItem -> Bool)
-> Eq ResourceComplianceSummaryItem
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ResourceComplianceSummaryItem
-> ResourceComplianceSummaryItem -> Bool
$c/= :: ResourceComplianceSummaryItem
-> ResourceComplianceSummaryItem -> Bool
== :: ResourceComplianceSummaryItem
-> ResourceComplianceSummaryItem -> Bool
$c== :: ResourceComplianceSummaryItem
-> ResourceComplianceSummaryItem -> Bool
Prelude.Eq, ReadPrec [ResourceComplianceSummaryItem]
ReadPrec ResourceComplianceSummaryItem
Int -> ReadS ResourceComplianceSummaryItem
ReadS [ResourceComplianceSummaryItem]
(Int -> ReadS ResourceComplianceSummaryItem)
-> ReadS [ResourceComplianceSummaryItem]
-> ReadPrec ResourceComplianceSummaryItem
-> ReadPrec [ResourceComplianceSummaryItem]
-> Read ResourceComplianceSummaryItem
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ResourceComplianceSummaryItem]
$creadListPrec :: ReadPrec [ResourceComplianceSummaryItem]
readPrec :: ReadPrec ResourceComplianceSummaryItem
$creadPrec :: ReadPrec ResourceComplianceSummaryItem
readList :: ReadS [ResourceComplianceSummaryItem]
$creadList :: ReadS [ResourceComplianceSummaryItem]
readsPrec :: Int -> ReadS ResourceComplianceSummaryItem
$creadsPrec :: Int -> ReadS ResourceComplianceSummaryItem
Prelude.Read, Int -> ResourceComplianceSummaryItem -> ShowS
[ResourceComplianceSummaryItem] -> ShowS
ResourceComplianceSummaryItem -> String
(Int -> ResourceComplianceSummaryItem -> ShowS)
-> (ResourceComplianceSummaryItem -> String)
-> ([ResourceComplianceSummaryItem] -> ShowS)
-> Show ResourceComplianceSummaryItem
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ResourceComplianceSummaryItem] -> ShowS
$cshowList :: [ResourceComplianceSummaryItem] -> ShowS
show :: ResourceComplianceSummaryItem -> String
$cshow :: ResourceComplianceSummaryItem -> String
showsPrec :: Int -> ResourceComplianceSummaryItem -> ShowS
$cshowsPrec :: Int -> ResourceComplianceSummaryItem -> ShowS
Prelude.Show, (forall x.
 ResourceComplianceSummaryItem
 -> Rep ResourceComplianceSummaryItem x)
-> (forall x.
    Rep ResourceComplianceSummaryItem x
    -> ResourceComplianceSummaryItem)
-> Generic ResourceComplianceSummaryItem
forall x.
Rep ResourceComplianceSummaryItem x
-> ResourceComplianceSummaryItem
forall x.
ResourceComplianceSummaryItem
-> Rep ResourceComplianceSummaryItem x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ResourceComplianceSummaryItem x
-> ResourceComplianceSummaryItem
$cfrom :: forall x.
ResourceComplianceSummaryItem
-> Rep ResourceComplianceSummaryItem x
Prelude.Generic)

-- |
-- Create a value of 'ResourceComplianceSummaryItem' 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:
--
-- 'nonCompliantSummary', 'resourceComplianceSummaryItem_nonCompliantSummary' - A list of items that aren\'t compliant for the resource.
--
-- 'status', 'resourceComplianceSummaryItem_status' - The compliance status for the resource.
--
-- 'resourceId', 'resourceComplianceSummaryItem_resourceId' - The resource ID.
--
-- 'resourceType', 'resourceComplianceSummaryItem_resourceType' - The resource type.
--
-- 'compliantSummary', 'resourceComplianceSummaryItem_compliantSummary' - A list of items that are compliant for the resource.
--
-- 'executionSummary', 'resourceComplianceSummaryItem_executionSummary' - Information about the execution.
--
-- 'overallSeverity', 'resourceComplianceSummaryItem_overallSeverity' - The highest severity item found for the resource. The resource is
-- compliant for this item.
--
-- 'complianceType', 'resourceComplianceSummaryItem_complianceType' - The compliance type.
newResourceComplianceSummaryItem ::
  ResourceComplianceSummaryItem
newResourceComplianceSummaryItem :: ResourceComplianceSummaryItem
newResourceComplianceSummaryItem =
  ResourceComplianceSummaryItem' :: Maybe NonCompliantSummary
-> Maybe ComplianceStatus
-> Maybe Text
-> Maybe Text
-> Maybe CompliantSummary
-> Maybe ComplianceExecutionSummary
-> Maybe ComplianceSeverity
-> Maybe Text
-> ResourceComplianceSummaryItem
ResourceComplianceSummaryItem'
    { $sel:nonCompliantSummary:ResourceComplianceSummaryItem' :: Maybe NonCompliantSummary
nonCompliantSummary =
        Maybe NonCompliantSummary
forall a. Maybe a
Prelude.Nothing,
      $sel:status:ResourceComplianceSummaryItem' :: Maybe ComplianceStatus
status = Maybe ComplianceStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:resourceId:ResourceComplianceSummaryItem' :: Maybe Text
resourceId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:resourceType:ResourceComplianceSummaryItem' :: Maybe Text
resourceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantSummary:ResourceComplianceSummaryItem' :: Maybe CompliantSummary
compliantSummary = Maybe CompliantSummary
forall a. Maybe a
Prelude.Nothing,
      $sel:executionSummary:ResourceComplianceSummaryItem' :: Maybe ComplianceExecutionSummary
executionSummary = Maybe ComplianceExecutionSummary
forall a. Maybe a
Prelude.Nothing,
      $sel:overallSeverity:ResourceComplianceSummaryItem' :: Maybe ComplianceSeverity
overallSeverity = Maybe ComplianceSeverity
forall a. Maybe a
Prelude.Nothing,
      $sel:complianceType:ResourceComplianceSummaryItem' :: Maybe Text
complianceType = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | A list of items that aren\'t compliant for the resource.
resourceComplianceSummaryItem_nonCompliantSummary :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe NonCompliantSummary)
resourceComplianceSummaryItem_nonCompliantSummary :: (Maybe NonCompliantSummary -> f (Maybe NonCompliantSummary))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_nonCompliantSummary = (ResourceComplianceSummaryItem -> Maybe NonCompliantSummary)
-> (ResourceComplianceSummaryItem
    -> Maybe NonCompliantSummary -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe NonCompliantSummary)
     (Maybe NonCompliantSummary)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe NonCompliantSummary
nonCompliantSummary :: Maybe NonCompliantSummary
$sel:nonCompliantSummary:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe NonCompliantSummary
nonCompliantSummary} -> Maybe NonCompliantSummary
nonCompliantSummary) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe NonCompliantSummary
a -> ResourceComplianceSummaryItem
s {$sel:nonCompliantSummary:ResourceComplianceSummaryItem' :: Maybe NonCompliantSummary
nonCompliantSummary = Maybe NonCompliantSummary
a} :: ResourceComplianceSummaryItem)

-- | The compliance status for the resource.
resourceComplianceSummaryItem_status :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe ComplianceStatus)
resourceComplianceSummaryItem_status :: (Maybe ComplianceStatus -> f (Maybe ComplianceStatus))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_status = (ResourceComplianceSummaryItem -> Maybe ComplianceStatus)
-> (ResourceComplianceSummaryItem
    -> Maybe ComplianceStatus -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe ComplianceStatus)
     (Maybe ComplianceStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe ComplianceStatus
status :: Maybe ComplianceStatus
$sel:status:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe ComplianceStatus
status} -> Maybe ComplianceStatus
status) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe ComplianceStatus
a -> ResourceComplianceSummaryItem
s {$sel:status:ResourceComplianceSummaryItem' :: Maybe ComplianceStatus
status = Maybe ComplianceStatus
a} :: ResourceComplianceSummaryItem)

-- | The resource ID.
resourceComplianceSummaryItem_resourceId :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe Prelude.Text)
resourceComplianceSummaryItem_resourceId :: (Maybe Text -> f (Maybe Text))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_resourceId = (ResourceComplianceSummaryItem -> Maybe Text)
-> (ResourceComplianceSummaryItem
    -> Maybe Text -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe Text
resourceId :: Maybe Text
$sel:resourceId:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe Text
resourceId} -> Maybe Text
resourceId) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe Text
a -> ResourceComplianceSummaryItem
s {$sel:resourceId:ResourceComplianceSummaryItem' :: Maybe Text
resourceId = Maybe Text
a} :: ResourceComplianceSummaryItem)

-- | The resource type.
resourceComplianceSummaryItem_resourceType :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe Prelude.Text)
resourceComplianceSummaryItem_resourceType :: (Maybe Text -> f (Maybe Text))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_resourceType = (ResourceComplianceSummaryItem -> Maybe Text)
-> (ResourceComplianceSummaryItem
    -> Maybe Text -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe Text
resourceType :: Maybe Text
$sel:resourceType:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe Text
resourceType} -> Maybe Text
resourceType) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe Text
a -> ResourceComplianceSummaryItem
s {$sel:resourceType:ResourceComplianceSummaryItem' :: Maybe Text
resourceType = Maybe Text
a} :: ResourceComplianceSummaryItem)

-- | A list of items that are compliant for the resource.
resourceComplianceSummaryItem_compliantSummary :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe CompliantSummary)
resourceComplianceSummaryItem_compliantSummary :: (Maybe CompliantSummary -> f (Maybe CompliantSummary))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_compliantSummary = (ResourceComplianceSummaryItem -> Maybe CompliantSummary)
-> (ResourceComplianceSummaryItem
    -> Maybe CompliantSummary -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe CompliantSummary)
     (Maybe CompliantSummary)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe CompliantSummary
compliantSummary :: Maybe CompliantSummary
$sel:compliantSummary:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe CompliantSummary
compliantSummary} -> Maybe CompliantSummary
compliantSummary) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe CompliantSummary
a -> ResourceComplianceSummaryItem
s {$sel:compliantSummary:ResourceComplianceSummaryItem' :: Maybe CompliantSummary
compliantSummary = Maybe CompliantSummary
a} :: ResourceComplianceSummaryItem)

-- | Information about the execution.
resourceComplianceSummaryItem_executionSummary :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe ComplianceExecutionSummary)
resourceComplianceSummaryItem_executionSummary :: (Maybe ComplianceExecutionSummary
 -> f (Maybe ComplianceExecutionSummary))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_executionSummary = (ResourceComplianceSummaryItem -> Maybe ComplianceExecutionSummary)
-> (ResourceComplianceSummaryItem
    -> Maybe ComplianceExecutionSummary
    -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe ComplianceExecutionSummary)
     (Maybe ComplianceExecutionSummary)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe ComplianceExecutionSummary
executionSummary :: Maybe ComplianceExecutionSummary
$sel:executionSummary:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe ComplianceExecutionSummary
executionSummary} -> Maybe ComplianceExecutionSummary
executionSummary) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe ComplianceExecutionSummary
a -> ResourceComplianceSummaryItem
s {$sel:executionSummary:ResourceComplianceSummaryItem' :: Maybe ComplianceExecutionSummary
executionSummary = Maybe ComplianceExecutionSummary
a} :: ResourceComplianceSummaryItem)

-- | The highest severity item found for the resource. The resource is
-- compliant for this item.
resourceComplianceSummaryItem_overallSeverity :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe ComplianceSeverity)
resourceComplianceSummaryItem_overallSeverity :: (Maybe ComplianceSeverity -> f (Maybe ComplianceSeverity))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_overallSeverity = (ResourceComplianceSummaryItem -> Maybe ComplianceSeverity)
-> (ResourceComplianceSummaryItem
    -> Maybe ComplianceSeverity -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe ComplianceSeverity)
     (Maybe ComplianceSeverity)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe ComplianceSeverity
overallSeverity :: Maybe ComplianceSeverity
$sel:overallSeverity:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe ComplianceSeverity
overallSeverity} -> Maybe ComplianceSeverity
overallSeverity) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe ComplianceSeverity
a -> ResourceComplianceSummaryItem
s {$sel:overallSeverity:ResourceComplianceSummaryItem' :: Maybe ComplianceSeverity
overallSeverity = Maybe ComplianceSeverity
a} :: ResourceComplianceSummaryItem)

-- | The compliance type.
resourceComplianceSummaryItem_complianceType :: Lens.Lens' ResourceComplianceSummaryItem (Prelude.Maybe Prelude.Text)
resourceComplianceSummaryItem_complianceType :: (Maybe Text -> f (Maybe Text))
-> ResourceComplianceSummaryItem -> f ResourceComplianceSummaryItem
resourceComplianceSummaryItem_complianceType = (ResourceComplianceSummaryItem -> Maybe Text)
-> (ResourceComplianceSummaryItem
    -> Maybe Text -> ResourceComplianceSummaryItem)
-> Lens
     ResourceComplianceSummaryItem
     ResourceComplianceSummaryItem
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ResourceComplianceSummaryItem' {Maybe Text
complianceType :: Maybe Text
$sel:complianceType:ResourceComplianceSummaryItem' :: ResourceComplianceSummaryItem -> Maybe Text
complianceType} -> Maybe Text
complianceType) (\s :: ResourceComplianceSummaryItem
s@ResourceComplianceSummaryItem' {} Maybe Text
a -> ResourceComplianceSummaryItem
s {$sel:complianceType:ResourceComplianceSummaryItem' :: Maybe Text
complianceType = Maybe Text
a} :: ResourceComplianceSummaryItem)

instance Core.FromJSON ResourceComplianceSummaryItem where
  parseJSON :: Value -> Parser ResourceComplianceSummaryItem
parseJSON =
    String
-> (Object -> Parser ResourceComplianceSummaryItem)
-> Value
-> Parser ResourceComplianceSummaryItem
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"ResourceComplianceSummaryItem"
      ( \Object
x ->
          Maybe NonCompliantSummary
-> Maybe ComplianceStatus
-> Maybe Text
-> Maybe Text
-> Maybe CompliantSummary
-> Maybe ComplianceExecutionSummary
-> Maybe ComplianceSeverity
-> Maybe Text
-> ResourceComplianceSummaryItem
ResourceComplianceSummaryItem'
            (Maybe NonCompliantSummary
 -> Maybe ComplianceStatus
 -> Maybe Text
 -> Maybe Text
 -> Maybe CompliantSummary
 -> Maybe ComplianceExecutionSummary
 -> Maybe ComplianceSeverity
 -> Maybe Text
 -> ResourceComplianceSummaryItem)
-> Parser (Maybe NonCompliantSummary)
-> Parser
     (Maybe ComplianceStatus
      -> Maybe Text
      -> Maybe Text
      -> Maybe CompliantSummary
      -> Maybe ComplianceExecutionSummary
      -> Maybe ComplianceSeverity
      -> Maybe Text
      -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe NonCompliantSummary)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantSummary")
            Parser
  (Maybe ComplianceStatus
   -> Maybe Text
   -> Maybe Text
   -> Maybe CompliantSummary
   -> Maybe ComplianceExecutionSummary
   -> Maybe ComplianceSeverity
   -> Maybe Text
   -> ResourceComplianceSummaryItem)
-> Parser (Maybe ComplianceStatus)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe CompliantSummary
      -> Maybe ComplianceExecutionSummary
      -> Maybe ComplianceSeverity
      -> Maybe Text
      -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ComplianceStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Status")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe CompliantSummary
   -> Maybe ComplianceExecutionSummary
   -> Maybe ComplianceSeverity
   -> Maybe Text
   -> ResourceComplianceSummaryItem)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe CompliantSummary
      -> Maybe ComplianceExecutionSummary
      -> Maybe ComplianceSeverity
      -> Maybe Text
      -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ResourceId")
            Parser
  (Maybe Text
   -> Maybe CompliantSummary
   -> Maybe ComplianceExecutionSummary
   -> Maybe ComplianceSeverity
   -> Maybe Text
   -> ResourceComplianceSummaryItem)
-> Parser (Maybe Text)
-> Parser
     (Maybe CompliantSummary
      -> Maybe ComplianceExecutionSummary
      -> Maybe ComplianceSeverity
      -> Maybe Text
      -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ResourceType")
            Parser
  (Maybe CompliantSummary
   -> Maybe ComplianceExecutionSummary
   -> Maybe ComplianceSeverity
   -> Maybe Text
   -> ResourceComplianceSummaryItem)
-> Parser (Maybe CompliantSummary)
-> Parser
     (Maybe ComplianceExecutionSummary
      -> Maybe ComplianceSeverity
      -> Maybe Text
      -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe CompliantSummary)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantSummary")
            Parser
  (Maybe ComplianceExecutionSummary
   -> Maybe ComplianceSeverity
   -> Maybe Text
   -> ResourceComplianceSummaryItem)
-> Parser (Maybe ComplianceExecutionSummary)
-> Parser
     (Maybe ComplianceSeverity
      -> Maybe Text -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ComplianceExecutionSummary)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutionSummary")
            Parser
  (Maybe ComplianceSeverity
   -> Maybe Text -> ResourceComplianceSummaryItem)
-> Parser (Maybe ComplianceSeverity)
-> Parser (Maybe Text -> ResourceComplianceSummaryItem)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ComplianceSeverity)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"OverallSeverity")
            Parser (Maybe Text -> ResourceComplianceSummaryItem)
-> Parser (Maybe Text) -> Parser ResourceComplianceSummaryItem
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ComplianceType")
      )

instance
  Prelude.Hashable
    ResourceComplianceSummaryItem

instance Prelude.NFData ResourceComplianceSummaryItem