{-# 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 #-}
module Amazonka.MacieV2.Types.BucketCountByEncryptionType where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data BucketCountByEncryptionType = BucketCountByEncryptionType'
{
BucketCountByEncryptionType -> Maybe Integer
kmsManaged :: Prelude.Maybe Prelude.Integer,
BucketCountByEncryptionType -> Maybe Integer
s3Managed :: Prelude.Maybe Prelude.Integer,
BucketCountByEncryptionType -> Maybe Integer
unencrypted :: Prelude.Maybe Prelude.Integer,
BucketCountByEncryptionType -> Maybe Integer
unknown :: Prelude.Maybe Prelude.Integer
}
deriving (BucketCountByEncryptionType -> BucketCountByEncryptionType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BucketCountByEncryptionType -> BucketCountByEncryptionType -> Bool
$c/= :: BucketCountByEncryptionType -> BucketCountByEncryptionType -> Bool
== :: BucketCountByEncryptionType -> BucketCountByEncryptionType -> Bool
$c== :: BucketCountByEncryptionType -> BucketCountByEncryptionType -> Bool
Prelude.Eq, ReadPrec [BucketCountByEncryptionType]
ReadPrec BucketCountByEncryptionType
Int -> ReadS BucketCountByEncryptionType
ReadS [BucketCountByEncryptionType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BucketCountByEncryptionType]
$creadListPrec :: ReadPrec [BucketCountByEncryptionType]
readPrec :: ReadPrec BucketCountByEncryptionType
$creadPrec :: ReadPrec BucketCountByEncryptionType
readList :: ReadS [BucketCountByEncryptionType]
$creadList :: ReadS [BucketCountByEncryptionType]
readsPrec :: Int -> ReadS BucketCountByEncryptionType
$creadsPrec :: Int -> ReadS BucketCountByEncryptionType
Prelude.Read, Int -> BucketCountByEncryptionType -> ShowS
[BucketCountByEncryptionType] -> ShowS
BucketCountByEncryptionType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BucketCountByEncryptionType] -> ShowS
$cshowList :: [BucketCountByEncryptionType] -> ShowS
show :: BucketCountByEncryptionType -> String
$cshow :: BucketCountByEncryptionType -> String
showsPrec :: Int -> BucketCountByEncryptionType -> ShowS
$cshowsPrec :: Int -> BucketCountByEncryptionType -> ShowS
Prelude.Show, forall x.
Rep BucketCountByEncryptionType x -> BucketCountByEncryptionType
forall x.
BucketCountByEncryptionType -> Rep BucketCountByEncryptionType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BucketCountByEncryptionType x -> BucketCountByEncryptionType
$cfrom :: forall x.
BucketCountByEncryptionType -> Rep BucketCountByEncryptionType x
Prelude.Generic)
newBucketCountByEncryptionType ::
BucketCountByEncryptionType
newBucketCountByEncryptionType :: BucketCountByEncryptionType
newBucketCountByEncryptionType =
BucketCountByEncryptionType'
{ $sel:kmsManaged:BucketCountByEncryptionType' :: Maybe Integer
kmsManaged =
forall a. Maybe a
Prelude.Nothing,
$sel:s3Managed:BucketCountByEncryptionType' :: Maybe Integer
s3Managed = forall a. Maybe a
Prelude.Nothing,
$sel:unencrypted:BucketCountByEncryptionType' :: Maybe Integer
unencrypted = forall a. Maybe a
Prelude.Nothing,
$sel:unknown:BucketCountByEncryptionType' :: Maybe Integer
unknown = forall a. Maybe a
Prelude.Nothing
}
bucketCountByEncryptionType_kmsManaged :: Lens.Lens' BucketCountByEncryptionType (Prelude.Maybe Prelude.Integer)
bucketCountByEncryptionType_kmsManaged :: Lens' BucketCountByEncryptionType (Maybe Integer)
bucketCountByEncryptionType_kmsManaged = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountByEncryptionType' {Maybe Integer
kmsManaged :: Maybe Integer
$sel:kmsManaged:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
kmsManaged} -> Maybe Integer
kmsManaged) (\s :: BucketCountByEncryptionType
s@BucketCountByEncryptionType' {} Maybe Integer
a -> BucketCountByEncryptionType
s {$sel:kmsManaged:BucketCountByEncryptionType' :: Maybe Integer
kmsManaged = Maybe Integer
a} :: BucketCountByEncryptionType)
bucketCountByEncryptionType_s3Managed :: Lens.Lens' BucketCountByEncryptionType (Prelude.Maybe Prelude.Integer)
bucketCountByEncryptionType_s3Managed :: Lens' BucketCountByEncryptionType (Maybe Integer)
bucketCountByEncryptionType_s3Managed = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountByEncryptionType' {Maybe Integer
s3Managed :: Maybe Integer
$sel:s3Managed:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
s3Managed} -> Maybe Integer
s3Managed) (\s :: BucketCountByEncryptionType
s@BucketCountByEncryptionType' {} Maybe Integer
a -> BucketCountByEncryptionType
s {$sel:s3Managed:BucketCountByEncryptionType' :: Maybe Integer
s3Managed = Maybe Integer
a} :: BucketCountByEncryptionType)
bucketCountByEncryptionType_unencrypted :: Lens.Lens' BucketCountByEncryptionType (Prelude.Maybe Prelude.Integer)
bucketCountByEncryptionType_unencrypted :: Lens' BucketCountByEncryptionType (Maybe Integer)
bucketCountByEncryptionType_unencrypted = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountByEncryptionType' {Maybe Integer
unencrypted :: Maybe Integer
$sel:unencrypted:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
unencrypted} -> Maybe Integer
unencrypted) (\s :: BucketCountByEncryptionType
s@BucketCountByEncryptionType' {} Maybe Integer
a -> BucketCountByEncryptionType
s {$sel:unencrypted:BucketCountByEncryptionType' :: Maybe Integer
unencrypted = Maybe Integer
a} :: BucketCountByEncryptionType)
bucketCountByEncryptionType_unknown :: Lens.Lens' BucketCountByEncryptionType (Prelude.Maybe Prelude.Integer)
bucketCountByEncryptionType_unknown :: Lens' BucketCountByEncryptionType (Maybe Integer)
bucketCountByEncryptionType_unknown = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountByEncryptionType' {Maybe Integer
unknown :: Maybe Integer
$sel:unknown:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
unknown} -> Maybe Integer
unknown) (\s :: BucketCountByEncryptionType
s@BucketCountByEncryptionType' {} Maybe Integer
a -> BucketCountByEncryptionType
s {$sel:unknown:BucketCountByEncryptionType' :: Maybe Integer
unknown = Maybe Integer
a} :: BucketCountByEncryptionType)
instance Data.FromJSON BucketCountByEncryptionType where
parseJSON :: Value -> Parser BucketCountByEncryptionType
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"BucketCountByEncryptionType"
( \Object
x ->
Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> BucketCountByEncryptionType
BucketCountByEncryptionType'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"kmsManaged")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"s3Managed")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"unencrypted")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"unknown")
)
instance Prelude.Hashable BucketCountByEncryptionType where
hashWithSalt :: Int -> BucketCountByEncryptionType -> Int
hashWithSalt Int
_salt BucketCountByEncryptionType' {Maybe Integer
unknown :: Maybe Integer
unencrypted :: Maybe Integer
s3Managed :: Maybe Integer
kmsManaged :: Maybe Integer
$sel:unknown:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:unencrypted:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:s3Managed:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:kmsManaged:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
kmsManaged
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
s3Managed
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
unencrypted
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
unknown
instance Prelude.NFData BucketCountByEncryptionType where
rnf :: BucketCountByEncryptionType -> ()
rnf BucketCountByEncryptionType' {Maybe Integer
unknown :: Maybe Integer
unencrypted :: Maybe Integer
s3Managed :: Maybe Integer
kmsManaged :: Maybe Integer
$sel:unknown:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:unencrypted:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:s3Managed:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
$sel:kmsManaged:BucketCountByEncryptionType' :: BucketCountByEncryptionType -> Maybe Integer
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
kmsManaged
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
s3Managed
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
unencrypted
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
unknown