{-# 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.BucketCountBySharedAccessType 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 BucketCountBySharedAccessType = BucketCountBySharedAccessType'
{
BucketCountBySharedAccessType -> Maybe Integer
external :: Prelude.Maybe Prelude.Integer,
BucketCountBySharedAccessType -> Maybe Integer
internal :: Prelude.Maybe Prelude.Integer,
BucketCountBySharedAccessType -> Maybe Integer
notShared :: Prelude.Maybe Prelude.Integer,
BucketCountBySharedAccessType -> Maybe Integer
unknown :: Prelude.Maybe Prelude.Integer
}
deriving (BucketCountBySharedAccessType
-> BucketCountBySharedAccessType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BucketCountBySharedAccessType
-> BucketCountBySharedAccessType -> Bool
$c/= :: BucketCountBySharedAccessType
-> BucketCountBySharedAccessType -> Bool
== :: BucketCountBySharedAccessType
-> BucketCountBySharedAccessType -> Bool
$c== :: BucketCountBySharedAccessType
-> BucketCountBySharedAccessType -> Bool
Prelude.Eq, ReadPrec [BucketCountBySharedAccessType]
ReadPrec BucketCountBySharedAccessType
Int -> ReadS BucketCountBySharedAccessType
ReadS [BucketCountBySharedAccessType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BucketCountBySharedAccessType]
$creadListPrec :: ReadPrec [BucketCountBySharedAccessType]
readPrec :: ReadPrec BucketCountBySharedAccessType
$creadPrec :: ReadPrec BucketCountBySharedAccessType
readList :: ReadS [BucketCountBySharedAccessType]
$creadList :: ReadS [BucketCountBySharedAccessType]
readsPrec :: Int -> ReadS BucketCountBySharedAccessType
$creadsPrec :: Int -> ReadS BucketCountBySharedAccessType
Prelude.Read, Int -> BucketCountBySharedAccessType -> ShowS
[BucketCountBySharedAccessType] -> ShowS
BucketCountBySharedAccessType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BucketCountBySharedAccessType] -> ShowS
$cshowList :: [BucketCountBySharedAccessType] -> ShowS
show :: BucketCountBySharedAccessType -> String
$cshow :: BucketCountBySharedAccessType -> String
showsPrec :: Int -> BucketCountBySharedAccessType -> ShowS
$cshowsPrec :: Int -> BucketCountBySharedAccessType -> ShowS
Prelude.Show, forall x.
Rep BucketCountBySharedAccessType x
-> BucketCountBySharedAccessType
forall x.
BucketCountBySharedAccessType
-> Rep BucketCountBySharedAccessType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BucketCountBySharedAccessType x
-> BucketCountBySharedAccessType
$cfrom :: forall x.
BucketCountBySharedAccessType
-> Rep BucketCountBySharedAccessType x
Prelude.Generic)
newBucketCountBySharedAccessType ::
BucketCountBySharedAccessType
newBucketCountBySharedAccessType :: BucketCountBySharedAccessType
newBucketCountBySharedAccessType =
BucketCountBySharedAccessType'
{ $sel:external:BucketCountBySharedAccessType' :: Maybe Integer
external =
forall a. Maybe a
Prelude.Nothing,
$sel:internal:BucketCountBySharedAccessType' :: Maybe Integer
internal = forall a. Maybe a
Prelude.Nothing,
$sel:notShared:BucketCountBySharedAccessType' :: Maybe Integer
notShared = forall a. Maybe a
Prelude.Nothing,
$sel:unknown:BucketCountBySharedAccessType' :: Maybe Integer
unknown = forall a. Maybe a
Prelude.Nothing
}
bucketCountBySharedAccessType_external :: Lens.Lens' BucketCountBySharedAccessType (Prelude.Maybe Prelude.Integer)
bucketCountBySharedAccessType_external :: Lens' BucketCountBySharedAccessType (Maybe Integer)
bucketCountBySharedAccessType_external = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountBySharedAccessType' {Maybe Integer
external :: Maybe Integer
$sel:external:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
external} -> Maybe Integer
external) (\s :: BucketCountBySharedAccessType
s@BucketCountBySharedAccessType' {} Maybe Integer
a -> BucketCountBySharedAccessType
s {$sel:external:BucketCountBySharedAccessType' :: Maybe Integer
external = Maybe Integer
a} :: BucketCountBySharedAccessType)
bucketCountBySharedAccessType_internal :: Lens.Lens' BucketCountBySharedAccessType (Prelude.Maybe Prelude.Integer)
bucketCountBySharedAccessType_internal :: Lens' BucketCountBySharedAccessType (Maybe Integer)
bucketCountBySharedAccessType_internal = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountBySharedAccessType' {Maybe Integer
internal :: Maybe Integer
$sel:internal:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
internal} -> Maybe Integer
internal) (\s :: BucketCountBySharedAccessType
s@BucketCountBySharedAccessType' {} Maybe Integer
a -> BucketCountBySharedAccessType
s {$sel:internal:BucketCountBySharedAccessType' :: Maybe Integer
internal = Maybe Integer
a} :: BucketCountBySharedAccessType)
bucketCountBySharedAccessType_notShared :: Lens.Lens' BucketCountBySharedAccessType (Prelude.Maybe Prelude.Integer)
bucketCountBySharedAccessType_notShared :: Lens' BucketCountBySharedAccessType (Maybe Integer)
bucketCountBySharedAccessType_notShared = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountBySharedAccessType' {Maybe Integer
notShared :: Maybe Integer
$sel:notShared:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
notShared} -> Maybe Integer
notShared) (\s :: BucketCountBySharedAccessType
s@BucketCountBySharedAccessType' {} Maybe Integer
a -> BucketCountBySharedAccessType
s {$sel:notShared:BucketCountBySharedAccessType' :: Maybe Integer
notShared = Maybe Integer
a} :: BucketCountBySharedAccessType)
bucketCountBySharedAccessType_unknown :: Lens.Lens' BucketCountBySharedAccessType (Prelude.Maybe Prelude.Integer)
bucketCountBySharedAccessType_unknown :: Lens' BucketCountBySharedAccessType (Maybe Integer)
bucketCountBySharedAccessType_unknown = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BucketCountBySharedAccessType' {Maybe Integer
unknown :: Maybe Integer
$sel:unknown:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
unknown} -> Maybe Integer
unknown) (\s :: BucketCountBySharedAccessType
s@BucketCountBySharedAccessType' {} Maybe Integer
a -> BucketCountBySharedAccessType
s {$sel:unknown:BucketCountBySharedAccessType' :: Maybe Integer
unknown = Maybe Integer
a} :: BucketCountBySharedAccessType)
instance Data.FromJSON BucketCountBySharedAccessType where
parseJSON :: Value -> Parser BucketCountBySharedAccessType
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"BucketCountBySharedAccessType"
( \Object
x ->
Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> Maybe Integer
-> BucketCountBySharedAccessType
BucketCountBySharedAccessType'
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
"external")
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
"internal")
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
"notShared")
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
BucketCountBySharedAccessType
where
hashWithSalt :: Int -> BucketCountBySharedAccessType -> Int
hashWithSalt Int
_salt BucketCountBySharedAccessType' {Maybe Integer
unknown :: Maybe Integer
notShared :: Maybe Integer
internal :: Maybe Integer
external :: Maybe Integer
$sel:unknown:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:notShared:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:internal:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:external:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
external
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
internal
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
notShared
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Integer
unknown
instance Prelude.NFData BucketCountBySharedAccessType where
rnf :: BucketCountBySharedAccessType -> ()
rnf BucketCountBySharedAccessType' {Maybe Integer
unknown :: Maybe Integer
notShared :: Maybe Integer
internal :: Maybe Integer
external :: Maybe Integer
$sel:unknown:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:notShared:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:internal:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
$sel:external:BucketCountBySharedAccessType' :: BucketCountBySharedAccessType -> Maybe Integer
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
external
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
internal
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
notShared
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Integer
unknown