{-# 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.SecurityHub.Types.AwsSsmComplianceSummary
-- 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.SecurityHub.Types.AwsSsmComplianceSummary where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Provides the details about the compliance status for a patch.
--
-- /See:/ 'newAwsSsmComplianceSummary' smart constructor.
data AwsSsmComplianceSummary = AwsSsmComplianceSummary'
  { -- | The current patch compliance status.
    --
    -- The possible status values are:
    --
    -- -   @COMPLIANT@
    --
    -- -   @NON_COMPLIANT@
    --
    -- -   @UNSPECIFIED_DATA@
    AwsSsmComplianceSummary -> Maybe Text
status :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are noncompliant, the number that have a severity
    -- of @LOW@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantLowCount :: Prelude.Maybe Prelude.Int,
    -- | For the patches that are compliant, the number that have a severity of
    -- @HIGH@.
    AwsSsmComplianceSummary -> Maybe Int
compliantHighCount :: Prelude.Maybe Prelude.Int,
    -- | For the patches that are noncompliant, the number that have a severity
    -- of @UNSPECIFIED@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantUnspecifiedCount :: Prelude.Maybe Prelude.Int,
    -- | The type of execution that was used determine compliance.
    AwsSsmComplianceSummary -> Maybe Text
executionType :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are compliant, the number that have a severity of
    -- @INFORMATIONAL@.
    AwsSsmComplianceSummary -> Maybe Int
compliantInformationalCount :: Prelude.Maybe Prelude.Int,
    -- | For the patches that are noncompliant, the number that have a severity
    -- of @HIGH@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantHighCount :: Prelude.Maybe Prelude.Int,
    -- | For the patches that are noncompliant, the number that have a severity
    -- of @MEDIUM@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantMediumCount :: Prelude.Maybe Prelude.Int,
    -- | The highest severity for the patches.
    AwsSsmComplianceSummary -> Maybe Text
overallSeverity :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are compliant, the number that have a severity of
    -- @CRITICAL@.
    AwsSsmComplianceSummary -> Maybe Int
compliantCriticalCount :: Prelude.Maybe Prelude.Int,
    -- | For the patches that are noncompliant, the number that have a severity
    -- of @INFORMATIONAL@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantInformationalCount :: Prelude.Maybe Prelude.Int,
    -- | The type of resource for which the compliance was determined. For
    -- @AwsSsmPatchCompliance@, @ComplianceType@ is @Patch@.
    AwsSsmComplianceSummary -> Maybe Text
complianceType :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are compliant, the number that have a severity of
    -- @UNSPECIFIED@.
    AwsSsmComplianceSummary -> Maybe Int
compliantUnspecifiedCount :: Prelude.Maybe Prelude.Int,
    -- | For the patch items that are noncompliant, the number of items that have
    -- a severity of @CRITICAL@.
    AwsSsmComplianceSummary -> Maybe Int
nonCompliantCriticalCount :: Prelude.Maybe Prelude.Int,
    -- | The identifier of the patch baseline. The patch baseline lists the
    -- patches that are approved for installation.
    AwsSsmComplianceSummary -> Maybe Text
patchBaselineId :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are compliant, the number that have a severity of
    -- @LOW@.
    AwsSsmComplianceSummary -> Maybe Int
compliantLowCount :: Prelude.Maybe Prelude.Int,
    -- | The identifier of the patch group for which compliance was determined. A
    -- patch group uses tags to group EC2 instances that should have the same
    -- patch compliance.
    AwsSsmComplianceSummary -> Maybe Text
patchGroup :: Prelude.Maybe Prelude.Text,
    -- | For the patches that are compliant, the number that have a severity of
    -- @MEDIUM@.
    AwsSsmComplianceSummary -> Maybe Int
compliantMediumCount :: Prelude.Maybe Prelude.Int
  }
  deriving (AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool
(AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool)
-> (AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool)
-> Eq AwsSsmComplianceSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool
$c/= :: AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool
== :: AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool
$c== :: AwsSsmComplianceSummary -> AwsSsmComplianceSummary -> Bool
Prelude.Eq, ReadPrec [AwsSsmComplianceSummary]
ReadPrec AwsSsmComplianceSummary
Int -> ReadS AwsSsmComplianceSummary
ReadS [AwsSsmComplianceSummary]
(Int -> ReadS AwsSsmComplianceSummary)
-> ReadS [AwsSsmComplianceSummary]
-> ReadPrec AwsSsmComplianceSummary
-> ReadPrec [AwsSsmComplianceSummary]
-> Read AwsSsmComplianceSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AwsSsmComplianceSummary]
$creadListPrec :: ReadPrec [AwsSsmComplianceSummary]
readPrec :: ReadPrec AwsSsmComplianceSummary
$creadPrec :: ReadPrec AwsSsmComplianceSummary
readList :: ReadS [AwsSsmComplianceSummary]
$creadList :: ReadS [AwsSsmComplianceSummary]
readsPrec :: Int -> ReadS AwsSsmComplianceSummary
$creadsPrec :: Int -> ReadS AwsSsmComplianceSummary
Prelude.Read, Int -> AwsSsmComplianceSummary -> ShowS
[AwsSsmComplianceSummary] -> ShowS
AwsSsmComplianceSummary -> String
(Int -> AwsSsmComplianceSummary -> ShowS)
-> (AwsSsmComplianceSummary -> String)
-> ([AwsSsmComplianceSummary] -> ShowS)
-> Show AwsSsmComplianceSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsSsmComplianceSummary] -> ShowS
$cshowList :: [AwsSsmComplianceSummary] -> ShowS
show :: AwsSsmComplianceSummary -> String
$cshow :: AwsSsmComplianceSummary -> String
showsPrec :: Int -> AwsSsmComplianceSummary -> ShowS
$cshowsPrec :: Int -> AwsSsmComplianceSummary -> ShowS
Prelude.Show, (forall x.
 AwsSsmComplianceSummary -> Rep AwsSsmComplianceSummary x)
-> (forall x.
    Rep AwsSsmComplianceSummary x -> AwsSsmComplianceSummary)
-> Generic AwsSsmComplianceSummary
forall x. Rep AwsSsmComplianceSummary x -> AwsSsmComplianceSummary
forall x. AwsSsmComplianceSummary -> Rep AwsSsmComplianceSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AwsSsmComplianceSummary x -> AwsSsmComplianceSummary
$cfrom :: forall x. AwsSsmComplianceSummary -> Rep AwsSsmComplianceSummary x
Prelude.Generic)

-- |
-- Create a value of 'AwsSsmComplianceSummary' 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:
--
-- 'status', 'awsSsmComplianceSummary_status' - The current patch compliance status.
--
-- The possible status values are:
--
-- -   @COMPLIANT@
--
-- -   @NON_COMPLIANT@
--
-- -   @UNSPECIFIED_DATA@
--
-- 'nonCompliantLowCount', 'awsSsmComplianceSummary_nonCompliantLowCount' - For the patches that are noncompliant, the number that have a severity
-- of @LOW@.
--
-- 'compliantHighCount', 'awsSsmComplianceSummary_compliantHighCount' - For the patches that are compliant, the number that have a severity of
-- @HIGH@.
--
-- 'nonCompliantUnspecifiedCount', 'awsSsmComplianceSummary_nonCompliantUnspecifiedCount' - For the patches that are noncompliant, the number that have a severity
-- of @UNSPECIFIED@.
--
-- 'executionType', 'awsSsmComplianceSummary_executionType' - The type of execution that was used determine compliance.
--
-- 'compliantInformationalCount', 'awsSsmComplianceSummary_compliantInformationalCount' - For the patches that are compliant, the number that have a severity of
-- @INFORMATIONAL@.
--
-- 'nonCompliantHighCount', 'awsSsmComplianceSummary_nonCompliantHighCount' - For the patches that are noncompliant, the number that have a severity
-- of @HIGH@.
--
-- 'nonCompliantMediumCount', 'awsSsmComplianceSummary_nonCompliantMediumCount' - For the patches that are noncompliant, the number that have a severity
-- of @MEDIUM@.
--
-- 'overallSeverity', 'awsSsmComplianceSummary_overallSeverity' - The highest severity for the patches.
--
-- 'compliantCriticalCount', 'awsSsmComplianceSummary_compliantCriticalCount' - For the patches that are compliant, the number that have a severity of
-- @CRITICAL@.
--
-- 'nonCompliantInformationalCount', 'awsSsmComplianceSummary_nonCompliantInformationalCount' - For the patches that are noncompliant, the number that have a severity
-- of @INFORMATIONAL@.
--
-- 'complianceType', 'awsSsmComplianceSummary_complianceType' - The type of resource for which the compliance was determined. For
-- @AwsSsmPatchCompliance@, @ComplianceType@ is @Patch@.
--
-- 'compliantUnspecifiedCount', 'awsSsmComplianceSummary_compliantUnspecifiedCount' - For the patches that are compliant, the number that have a severity of
-- @UNSPECIFIED@.
--
-- 'nonCompliantCriticalCount', 'awsSsmComplianceSummary_nonCompliantCriticalCount' - For the patch items that are noncompliant, the number of items that have
-- a severity of @CRITICAL@.
--
-- 'patchBaselineId', 'awsSsmComplianceSummary_patchBaselineId' - The identifier of the patch baseline. The patch baseline lists the
-- patches that are approved for installation.
--
-- 'compliantLowCount', 'awsSsmComplianceSummary_compliantLowCount' - For the patches that are compliant, the number that have a severity of
-- @LOW@.
--
-- 'patchGroup', 'awsSsmComplianceSummary_patchGroup' - The identifier of the patch group for which compliance was determined. A
-- patch group uses tags to group EC2 instances that should have the same
-- patch compliance.
--
-- 'compliantMediumCount', 'awsSsmComplianceSummary_compliantMediumCount' - For the patches that are compliant, the number that have a severity of
-- @MEDIUM@.
newAwsSsmComplianceSummary ::
  AwsSsmComplianceSummary
newAwsSsmComplianceSummary :: AwsSsmComplianceSummary
newAwsSsmComplianceSummary =
  AwsSsmComplianceSummary' :: Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> AwsSsmComplianceSummary
AwsSsmComplianceSummary'
    { $sel:status:AwsSsmComplianceSummary' :: Maybe Text
status = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantLowCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantLowCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantHighCount:AwsSsmComplianceSummary' :: Maybe Int
compliantHighCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantUnspecifiedCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantUnspecifiedCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:executionType:AwsSsmComplianceSummary' :: Maybe Text
executionType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantInformationalCount:AwsSsmComplianceSummary' :: Maybe Int
compliantInformationalCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantHighCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantHighCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantMediumCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantMediumCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:overallSeverity:AwsSsmComplianceSummary' :: Maybe Text
overallSeverity = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantCriticalCount:AwsSsmComplianceSummary' :: Maybe Int
compliantCriticalCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantInformationalCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantInformationalCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:complianceType:AwsSsmComplianceSummary' :: Maybe Text
complianceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantUnspecifiedCount:AwsSsmComplianceSummary' :: Maybe Int
compliantUnspecifiedCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:nonCompliantCriticalCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantCriticalCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:patchBaselineId:AwsSsmComplianceSummary' :: Maybe Text
patchBaselineId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantLowCount:AwsSsmComplianceSummary' :: Maybe Int
compliantLowCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:patchGroup:AwsSsmComplianceSummary' :: Maybe Text
patchGroup = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:compliantMediumCount:AwsSsmComplianceSummary' :: Maybe Int
compliantMediumCount = Maybe Int
forall a. Maybe a
Prelude.Nothing
    }

-- | The current patch compliance status.
--
-- The possible status values are:
--
-- -   @COMPLIANT@
--
-- -   @NON_COMPLIANT@
--
-- -   @UNSPECIFIED_DATA@
awsSsmComplianceSummary_status :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_status :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_status = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
status :: Maybe Text
$sel:status:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
status} -> Maybe Text
status) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:status:AwsSsmComplianceSummary' :: Maybe Text
status = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are noncompliant, the number that have a severity
-- of @LOW@.
awsSsmComplianceSummary_nonCompliantLowCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantLowCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantLowCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantLowCount :: Maybe Int
$sel:nonCompliantLowCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantLowCount} -> Maybe Int
nonCompliantLowCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantLowCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantLowCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @HIGH@.
awsSsmComplianceSummary_compliantHighCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantHighCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantHighCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantHighCount :: Maybe Int
$sel:compliantHighCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantHighCount} -> Maybe Int
compliantHighCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantHighCount:AwsSsmComplianceSummary' :: Maybe Int
compliantHighCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patches that are noncompliant, the number that have a severity
-- of @UNSPECIFIED@.
awsSsmComplianceSummary_nonCompliantUnspecifiedCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantUnspecifiedCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantUnspecifiedCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantUnspecifiedCount :: Maybe Int
$sel:nonCompliantUnspecifiedCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantUnspecifiedCount} -> Maybe Int
nonCompliantUnspecifiedCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantUnspecifiedCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantUnspecifiedCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | The type of execution that was used determine compliance.
awsSsmComplianceSummary_executionType :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_executionType :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_executionType = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
executionType :: Maybe Text
$sel:executionType:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
executionType} -> Maybe Text
executionType) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:executionType:AwsSsmComplianceSummary' :: Maybe Text
executionType = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @INFORMATIONAL@.
awsSsmComplianceSummary_compliantInformationalCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantInformationalCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantInformationalCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantInformationalCount :: Maybe Int
$sel:compliantInformationalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantInformationalCount} -> Maybe Int
compliantInformationalCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantInformationalCount:AwsSsmComplianceSummary' :: Maybe Int
compliantInformationalCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patches that are noncompliant, the number that have a severity
-- of @HIGH@.
awsSsmComplianceSummary_nonCompliantHighCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantHighCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantHighCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantHighCount :: Maybe Int
$sel:nonCompliantHighCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantHighCount} -> Maybe Int
nonCompliantHighCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantHighCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantHighCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patches that are noncompliant, the number that have a severity
-- of @MEDIUM@.
awsSsmComplianceSummary_nonCompliantMediumCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantMediumCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantMediumCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantMediumCount :: Maybe Int
$sel:nonCompliantMediumCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantMediumCount} -> Maybe Int
nonCompliantMediumCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantMediumCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantMediumCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | The highest severity for the patches.
awsSsmComplianceSummary_overallSeverity :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_overallSeverity :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_overallSeverity = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
overallSeverity :: Maybe Text
$sel:overallSeverity:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
overallSeverity} -> Maybe Text
overallSeverity) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:overallSeverity:AwsSsmComplianceSummary' :: Maybe Text
overallSeverity = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @CRITICAL@.
awsSsmComplianceSummary_compliantCriticalCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantCriticalCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantCriticalCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantCriticalCount :: Maybe Int
$sel:compliantCriticalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantCriticalCount} -> Maybe Int
compliantCriticalCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantCriticalCount:AwsSsmComplianceSummary' :: Maybe Int
compliantCriticalCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patches that are noncompliant, the number that have a severity
-- of @INFORMATIONAL@.
awsSsmComplianceSummary_nonCompliantInformationalCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantInformationalCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantInformationalCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantInformationalCount :: Maybe Int
$sel:nonCompliantInformationalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantInformationalCount} -> Maybe Int
nonCompliantInformationalCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantInformationalCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantInformationalCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | The type of resource for which the compliance was determined. For
-- @AwsSsmPatchCompliance@, @ComplianceType@ is @Patch@.
awsSsmComplianceSummary_complianceType :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_complianceType :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_complianceType = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
complianceType :: Maybe Text
$sel:complianceType:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
complianceType} -> Maybe Text
complianceType) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:complianceType:AwsSsmComplianceSummary' :: Maybe Text
complianceType = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @UNSPECIFIED@.
awsSsmComplianceSummary_compliantUnspecifiedCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantUnspecifiedCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantUnspecifiedCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantUnspecifiedCount :: Maybe Int
$sel:compliantUnspecifiedCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantUnspecifiedCount} -> Maybe Int
compliantUnspecifiedCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantUnspecifiedCount:AwsSsmComplianceSummary' :: Maybe Int
compliantUnspecifiedCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | For the patch items that are noncompliant, the number of items that have
-- a severity of @CRITICAL@.
awsSsmComplianceSummary_nonCompliantCriticalCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_nonCompliantCriticalCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_nonCompliantCriticalCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
nonCompliantCriticalCount :: Maybe Int
$sel:nonCompliantCriticalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
nonCompliantCriticalCount} -> Maybe Int
nonCompliantCriticalCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:nonCompliantCriticalCount:AwsSsmComplianceSummary' :: Maybe Int
nonCompliantCriticalCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | The identifier of the patch baseline. The patch baseline lists the
-- patches that are approved for installation.
awsSsmComplianceSummary_patchBaselineId :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_patchBaselineId :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_patchBaselineId = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
patchBaselineId :: Maybe Text
$sel:patchBaselineId:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
patchBaselineId} -> Maybe Text
patchBaselineId) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:patchBaselineId:AwsSsmComplianceSummary' :: Maybe Text
patchBaselineId = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @LOW@.
awsSsmComplianceSummary_compliantLowCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantLowCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantLowCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantLowCount :: Maybe Int
$sel:compliantLowCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantLowCount} -> Maybe Int
compliantLowCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantLowCount:AwsSsmComplianceSummary' :: Maybe Int
compliantLowCount = Maybe Int
a} :: AwsSsmComplianceSummary)

-- | The identifier of the patch group for which compliance was determined. A
-- patch group uses tags to group EC2 instances that should have the same
-- patch compliance.
awsSsmComplianceSummary_patchGroup :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Text)
awsSsmComplianceSummary_patchGroup :: (Maybe Text -> f (Maybe Text))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_patchGroup = (AwsSsmComplianceSummary -> Maybe Text)
-> (AwsSsmComplianceSummary
    -> Maybe Text -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Text
patchGroup :: Maybe Text
$sel:patchGroup:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
patchGroup} -> Maybe Text
patchGroup) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Text
a -> AwsSsmComplianceSummary
s {$sel:patchGroup:AwsSsmComplianceSummary' :: Maybe Text
patchGroup = Maybe Text
a} :: AwsSsmComplianceSummary)

-- | For the patches that are compliant, the number that have a severity of
-- @MEDIUM@.
awsSsmComplianceSummary_compliantMediumCount :: Lens.Lens' AwsSsmComplianceSummary (Prelude.Maybe Prelude.Int)
awsSsmComplianceSummary_compliantMediumCount :: (Maybe Int -> f (Maybe Int))
-> AwsSsmComplianceSummary -> f AwsSsmComplianceSummary
awsSsmComplianceSummary_compliantMediumCount = (AwsSsmComplianceSummary -> Maybe Int)
-> (AwsSsmComplianceSummary
    -> Maybe Int -> AwsSsmComplianceSummary)
-> Lens
     AwsSsmComplianceSummary
     AwsSsmComplianceSummary
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsSsmComplianceSummary' {Maybe Int
compliantMediumCount :: Maybe Int
$sel:compliantMediumCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
compliantMediumCount} -> Maybe Int
compliantMediumCount) (\s :: AwsSsmComplianceSummary
s@AwsSsmComplianceSummary' {} Maybe Int
a -> AwsSsmComplianceSummary
s {$sel:compliantMediumCount:AwsSsmComplianceSummary' :: Maybe Int
compliantMediumCount = Maybe Int
a} :: AwsSsmComplianceSummary)

instance Core.FromJSON AwsSsmComplianceSummary where
  parseJSON :: Value -> Parser AwsSsmComplianceSummary
parseJSON =
    String
-> (Object -> Parser AwsSsmComplianceSummary)
-> Value
-> Parser AwsSsmComplianceSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsSsmComplianceSummary"
      ( \Object
x ->
          Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> AwsSsmComplianceSummary
AwsSsmComplianceSummary'
            (Maybe Text
 -> Maybe Int
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Functor 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
"Status")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantLowCount")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantHighCount")
            Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantUnspecifiedCount")
            Parser
  (Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
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
"ExecutionType")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantInformationalCount")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantHighCount")
            Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantMediumCount")
            Parser
  (Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
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
"OverallSeverity")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantCriticalCount")
            Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantInformationalCount")
            Parser
  (Maybe Text
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
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")
            Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantUnspecifiedCount")
            Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Int -> Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NonCompliantCriticalCount")
            Parser
  (Maybe Text
   -> Maybe Int -> Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int -> Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
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
"PatchBaselineId")
            Parser
  (Maybe Int -> Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
-> Parser (Maybe Int)
-> Parser (Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantLowCount")
            Parser (Maybe Text -> Maybe Int -> AwsSsmComplianceSummary)
-> Parser (Maybe Text)
-> Parser (Maybe Int -> AwsSsmComplianceSummary)
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
"PatchGroup")
            Parser (Maybe Int -> AwsSsmComplianceSummary)
-> Parser (Maybe Int) -> Parser AwsSsmComplianceSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompliantMediumCount")
      )

instance Prelude.Hashable AwsSsmComplianceSummary

instance Prelude.NFData AwsSsmComplianceSummary

instance Core.ToJSON AwsSsmComplianceSummary where
  toJSON :: AwsSsmComplianceSummary -> Value
toJSON AwsSsmComplianceSummary' {Maybe Int
Maybe Text
compliantMediumCount :: Maybe Int
patchGroup :: Maybe Text
compliantLowCount :: Maybe Int
patchBaselineId :: Maybe Text
nonCompliantCriticalCount :: Maybe Int
compliantUnspecifiedCount :: Maybe Int
complianceType :: Maybe Text
nonCompliantInformationalCount :: Maybe Int
compliantCriticalCount :: Maybe Int
overallSeverity :: Maybe Text
nonCompliantMediumCount :: Maybe Int
nonCompliantHighCount :: Maybe Int
compliantInformationalCount :: Maybe Int
executionType :: Maybe Text
nonCompliantUnspecifiedCount :: Maybe Int
compliantHighCount :: Maybe Int
nonCompliantLowCount :: Maybe Int
status :: Maybe Text
$sel:compliantMediumCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:patchGroup:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
$sel:compliantLowCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:patchBaselineId:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
$sel:nonCompliantCriticalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:compliantUnspecifiedCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:complianceType:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
$sel:nonCompliantInformationalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:compliantCriticalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:overallSeverity:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
$sel:nonCompliantMediumCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:nonCompliantHighCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:compliantInformationalCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:executionType:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
$sel:nonCompliantUnspecifiedCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:compliantHighCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:nonCompliantLowCount:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Int
$sel:status:AwsSsmComplianceSummary' :: AwsSsmComplianceSummary -> Maybe Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"Status" 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
status,
            (Text
"NonCompliantLowCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantLowCount,
            (Text
"CompliantHighCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantHighCount,
            (Text
"NonCompliantUnspecifiedCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantUnspecifiedCount,
            (Text
"ExecutionType" 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
executionType,
            (Text
"CompliantInformationalCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantInformationalCount,
            (Text
"NonCompliantHighCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantHighCount,
            (Text
"NonCompliantMediumCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantMediumCount,
            (Text
"OverallSeverity" 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
overallSeverity,
            (Text
"CompliantCriticalCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantCriticalCount,
            (Text
"NonCompliantInformationalCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantInformationalCount,
            (Text
"ComplianceType" 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
complianceType,
            (Text
"CompliantUnspecifiedCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantUnspecifiedCount,
            (Text
"NonCompliantCriticalCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
nonCompliantCriticalCount,
            (Text
"PatchBaselineId" 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
patchBaselineId,
            (Text
"CompliantLowCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantLowCount,
            (Text
"PatchGroup" 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
patchGroup,
            (Text
"CompliantMediumCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
compliantMediumCount
          ]
      )