{-# 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.MacieV2.Types.BatchGetCustomDataIdentifierSummary
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.MacieV2.Types.BatchGetCustomDataIdentifierSummary 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

-- | Provides information about a custom data identifier.
--
-- /See:/ 'newBatchGetCustomDataIdentifierSummary' smart constructor.
data BatchGetCustomDataIdentifierSummary = BatchGetCustomDataIdentifierSummary'
  { -- | The Amazon Resource Name (ARN) of the custom data identifier.
    BatchGetCustomDataIdentifierSummary -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
    -- | The date and time, in UTC and extended ISO 8601 format, when the custom
    -- data identifier was created.
    BatchGetCustomDataIdentifierSummary -> Maybe ISO8601
createdAt :: Prelude.Maybe Data.ISO8601,
    -- | Specifies whether the custom data identifier was deleted. If you delete
    -- a custom data identifier, Amazon Macie doesn\'t delete it permanently.
    -- Instead, it soft deletes the identifier.
    BatchGetCustomDataIdentifierSummary -> Maybe Bool
deleted :: Prelude.Maybe Prelude.Bool,
    -- | The custom description of the custom data identifier.
    BatchGetCustomDataIdentifierSummary -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The unique identifier for the custom data identifier.
    BatchGetCustomDataIdentifierSummary -> Maybe Text
id :: Prelude.Maybe Prelude.Text,
    -- | The custom name of the custom data identifier.
    BatchGetCustomDataIdentifierSummary -> Maybe Text
name :: Prelude.Maybe Prelude.Text
  }
  deriving (BatchGetCustomDataIdentifierSummary
-> BatchGetCustomDataIdentifierSummary -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchGetCustomDataIdentifierSummary
-> BatchGetCustomDataIdentifierSummary -> Bool
$c/= :: BatchGetCustomDataIdentifierSummary
-> BatchGetCustomDataIdentifierSummary -> Bool
== :: BatchGetCustomDataIdentifierSummary
-> BatchGetCustomDataIdentifierSummary -> Bool
$c== :: BatchGetCustomDataIdentifierSummary
-> BatchGetCustomDataIdentifierSummary -> Bool
Prelude.Eq, ReadPrec [BatchGetCustomDataIdentifierSummary]
ReadPrec BatchGetCustomDataIdentifierSummary
Int -> ReadS BatchGetCustomDataIdentifierSummary
ReadS [BatchGetCustomDataIdentifierSummary]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BatchGetCustomDataIdentifierSummary]
$creadListPrec :: ReadPrec [BatchGetCustomDataIdentifierSummary]
readPrec :: ReadPrec BatchGetCustomDataIdentifierSummary
$creadPrec :: ReadPrec BatchGetCustomDataIdentifierSummary
readList :: ReadS [BatchGetCustomDataIdentifierSummary]
$creadList :: ReadS [BatchGetCustomDataIdentifierSummary]
readsPrec :: Int -> ReadS BatchGetCustomDataIdentifierSummary
$creadsPrec :: Int -> ReadS BatchGetCustomDataIdentifierSummary
Prelude.Read, Int -> BatchGetCustomDataIdentifierSummary -> ShowS
[BatchGetCustomDataIdentifierSummary] -> ShowS
BatchGetCustomDataIdentifierSummary -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchGetCustomDataIdentifierSummary] -> ShowS
$cshowList :: [BatchGetCustomDataIdentifierSummary] -> ShowS
show :: BatchGetCustomDataIdentifierSummary -> String
$cshow :: BatchGetCustomDataIdentifierSummary -> String
showsPrec :: Int -> BatchGetCustomDataIdentifierSummary -> ShowS
$cshowsPrec :: Int -> BatchGetCustomDataIdentifierSummary -> ShowS
Prelude.Show, forall x.
Rep BatchGetCustomDataIdentifierSummary x
-> BatchGetCustomDataIdentifierSummary
forall x.
BatchGetCustomDataIdentifierSummary
-> Rep BatchGetCustomDataIdentifierSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BatchGetCustomDataIdentifierSummary x
-> BatchGetCustomDataIdentifierSummary
$cfrom :: forall x.
BatchGetCustomDataIdentifierSummary
-> Rep BatchGetCustomDataIdentifierSummary x
Prelude.Generic)

-- |
-- Create a value of 'BatchGetCustomDataIdentifierSummary' 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:
--
-- 'arn', 'batchGetCustomDataIdentifierSummary_arn' - The Amazon Resource Name (ARN) of the custom data identifier.
--
-- 'createdAt', 'batchGetCustomDataIdentifierSummary_createdAt' - The date and time, in UTC and extended ISO 8601 format, when the custom
-- data identifier was created.
--
-- 'deleted', 'batchGetCustomDataIdentifierSummary_deleted' - Specifies whether the custom data identifier was deleted. If you delete
-- a custom data identifier, Amazon Macie doesn\'t delete it permanently.
-- Instead, it soft deletes the identifier.
--
-- 'description', 'batchGetCustomDataIdentifierSummary_description' - The custom description of the custom data identifier.
--
-- 'id', 'batchGetCustomDataIdentifierSummary_id' - The unique identifier for the custom data identifier.
--
-- 'name', 'batchGetCustomDataIdentifierSummary_name' - The custom name of the custom data identifier.
newBatchGetCustomDataIdentifierSummary ::
  BatchGetCustomDataIdentifierSummary
newBatchGetCustomDataIdentifierSummary :: BatchGetCustomDataIdentifierSummary
newBatchGetCustomDataIdentifierSummary =
  BatchGetCustomDataIdentifierSummary'
    { $sel:arn:BatchGetCustomDataIdentifierSummary' :: Maybe Text
arn =
        forall a. Maybe a
Prelude.Nothing,
      $sel:createdAt:BatchGetCustomDataIdentifierSummary' :: Maybe ISO8601
createdAt = forall a. Maybe a
Prelude.Nothing,
      $sel:deleted:BatchGetCustomDataIdentifierSummary' :: Maybe Bool
deleted = forall a. Maybe a
Prelude.Nothing,
      $sel:description:BatchGetCustomDataIdentifierSummary' :: Maybe Text
description = forall a. Maybe a
Prelude.Nothing,
      $sel:id:BatchGetCustomDataIdentifierSummary' :: Maybe Text
id = forall a. Maybe a
Prelude.Nothing,
      $sel:name:BatchGetCustomDataIdentifierSummary' :: Maybe Text
name = forall a. Maybe a
Prelude.Nothing
    }

-- | The Amazon Resource Name (ARN) of the custom data identifier.
batchGetCustomDataIdentifierSummary_arn :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.Text)
batchGetCustomDataIdentifierSummary_arn :: Lens' BatchGetCustomDataIdentifierSummary (Maybe Text)
batchGetCustomDataIdentifierSummary_arn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe Text
arn :: Maybe Text
$sel:arn:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
arn} -> Maybe Text
arn) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe Text
a -> BatchGetCustomDataIdentifierSummary
s {$sel:arn:BatchGetCustomDataIdentifierSummary' :: Maybe Text
arn = Maybe Text
a} :: BatchGetCustomDataIdentifierSummary)

-- | The date and time, in UTC and extended ISO 8601 format, when the custom
-- data identifier was created.
batchGetCustomDataIdentifierSummary_createdAt :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.UTCTime)
batchGetCustomDataIdentifierSummary_createdAt :: Lens' BatchGetCustomDataIdentifierSummary (Maybe UTCTime)
batchGetCustomDataIdentifierSummary_createdAt = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe ISO8601
createdAt :: Maybe ISO8601
$sel:createdAt:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe ISO8601
createdAt} -> Maybe ISO8601
createdAt) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe ISO8601
a -> BatchGetCustomDataIdentifierSummary
s {$sel:createdAt:BatchGetCustomDataIdentifierSummary' :: Maybe ISO8601
createdAt = Maybe ISO8601
a} :: BatchGetCustomDataIdentifierSummary) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall (a :: Format). Iso' (Time a) UTCTime
Data._Time

-- | Specifies whether the custom data identifier was deleted. If you delete
-- a custom data identifier, Amazon Macie doesn\'t delete it permanently.
-- Instead, it soft deletes the identifier.
batchGetCustomDataIdentifierSummary_deleted :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.Bool)
batchGetCustomDataIdentifierSummary_deleted :: Lens' BatchGetCustomDataIdentifierSummary (Maybe Bool)
batchGetCustomDataIdentifierSummary_deleted = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe Bool
deleted :: Maybe Bool
$sel:deleted:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Bool
deleted} -> Maybe Bool
deleted) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe Bool
a -> BatchGetCustomDataIdentifierSummary
s {$sel:deleted:BatchGetCustomDataIdentifierSummary' :: Maybe Bool
deleted = Maybe Bool
a} :: BatchGetCustomDataIdentifierSummary)

-- | The custom description of the custom data identifier.
batchGetCustomDataIdentifierSummary_description :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.Text)
batchGetCustomDataIdentifierSummary_description :: Lens' BatchGetCustomDataIdentifierSummary (Maybe Text)
batchGetCustomDataIdentifierSummary_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe Text
description :: Maybe Text
$sel:description:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
description} -> Maybe Text
description) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe Text
a -> BatchGetCustomDataIdentifierSummary
s {$sel:description:BatchGetCustomDataIdentifierSummary' :: Maybe Text
description = Maybe Text
a} :: BatchGetCustomDataIdentifierSummary)

-- | The unique identifier for the custom data identifier.
batchGetCustomDataIdentifierSummary_id :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.Text)
batchGetCustomDataIdentifierSummary_id :: Lens' BatchGetCustomDataIdentifierSummary (Maybe Text)
batchGetCustomDataIdentifierSummary_id = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe Text
id :: Maybe Text
$sel:id:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
id} -> Maybe Text
id) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe Text
a -> BatchGetCustomDataIdentifierSummary
s {$sel:id:BatchGetCustomDataIdentifierSummary' :: Maybe Text
id = Maybe Text
a} :: BatchGetCustomDataIdentifierSummary)

-- | The custom name of the custom data identifier.
batchGetCustomDataIdentifierSummary_name :: Lens.Lens' BatchGetCustomDataIdentifierSummary (Prelude.Maybe Prelude.Text)
batchGetCustomDataIdentifierSummary_name :: Lens' BatchGetCustomDataIdentifierSummary (Maybe Text)
batchGetCustomDataIdentifierSummary_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchGetCustomDataIdentifierSummary' {Maybe Text
name :: Maybe Text
$sel:name:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
name} -> Maybe Text
name) (\s :: BatchGetCustomDataIdentifierSummary
s@BatchGetCustomDataIdentifierSummary' {} Maybe Text
a -> BatchGetCustomDataIdentifierSummary
s {$sel:name:BatchGetCustomDataIdentifierSummary' :: Maybe Text
name = Maybe Text
a} :: BatchGetCustomDataIdentifierSummary)

instance
  Data.FromJSON
    BatchGetCustomDataIdentifierSummary
  where
  parseJSON :: Value -> Parser BatchGetCustomDataIdentifierSummary
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"BatchGetCustomDataIdentifierSummary"
      ( \Object
x ->
          Maybe Text
-> Maybe ISO8601
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> BatchGetCustomDataIdentifierSummary
BatchGetCustomDataIdentifierSummary'
            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
"arn")
            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
"createdAt")
            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
"deleted")
            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
"description")
            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
"id")
            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
"name")
      )

instance
  Prelude.Hashable
    BatchGetCustomDataIdentifierSummary
  where
  hashWithSalt :: Int -> BatchGetCustomDataIdentifierSummary -> Int
hashWithSalt
    Int
_salt
    BatchGetCustomDataIdentifierSummary' {Maybe Bool
Maybe Text
Maybe ISO8601
name :: Maybe Text
id :: Maybe Text
description :: Maybe Text
deleted :: Maybe Bool
createdAt :: Maybe ISO8601
arn :: Maybe Text
$sel:name:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:id:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:description:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:deleted:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Bool
$sel:createdAt:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe ISO8601
$sel:arn:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
..} =
      Int
_salt
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
arn
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ISO8601
createdAt
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
deleted
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
description
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
id
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
name

instance
  Prelude.NFData
    BatchGetCustomDataIdentifierSummary
  where
  rnf :: BatchGetCustomDataIdentifierSummary -> ()
rnf BatchGetCustomDataIdentifierSummary' {Maybe Bool
Maybe Text
Maybe ISO8601
name :: Maybe Text
id :: Maybe Text
description :: Maybe Text
deleted :: Maybe Bool
createdAt :: Maybe ISO8601
arn :: Maybe Text
$sel:name:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:id:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:description:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
$sel:deleted:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Bool
$sel:createdAt:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe ISO8601
$sel:arn:BatchGetCustomDataIdentifierSummary' :: BatchGetCustomDataIdentifierSummary -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
arn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ISO8601
createdAt
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
deleted
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
id
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
name