{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# 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.CreateClassificationJob
-- 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)
--
-- Creates and defines the settings for a classification job.
module Amazonka.MacieV2.CreateClassificationJob
  ( -- * Creating a Request
    CreateClassificationJob (..),
    newCreateClassificationJob,

    -- * Request Lenses
    createClassificationJob_initialRun,
    createClassificationJob_samplingPercentage,
    createClassificationJob_managedDataIdentifierSelector,
    createClassificationJob_customDataIdentifierIds,
    createClassificationJob_managedDataIdentifierIds,
    createClassificationJob_description,
    createClassificationJob_tags,
    createClassificationJob_scheduleFrequency,
    createClassificationJob_s3JobDefinition,
    createClassificationJob_jobType,
    createClassificationJob_clientToken,
    createClassificationJob_name,

    -- * Destructuring the Response
    CreateClassificationJobResponse (..),
    newCreateClassificationJobResponse,

    -- * Response Lenses
    createClassificationJobResponse_jobId,
    createClassificationJobResponse_jobArn,
    createClassificationJobResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MacieV2.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newCreateClassificationJob' smart constructor.
data CreateClassificationJob = CreateClassificationJob'
  { -- | For a recurring job, specifies whether to analyze all existing, eligible
    -- objects immediately after the job is created (true). To analyze only
    -- those objects that are created or changed after you create the job and
    -- before the job\'s first scheduled run, set this value to false.
    --
    -- If you configure the job to run only once, don\'t specify a value for
    -- this property.
    CreateClassificationJob -> Maybe Bool
initialRun :: Prelude.Maybe Prelude.Bool,
    -- | The sampling depth, as a percentage, for the job to apply when
    -- processing objects. This value determines the percentage of eligible
    -- objects that the job analyzes. If this value is less than 100, Amazon
    -- Macie selects the objects to analyze at random, up to the specified
    -- percentage, and analyzes all the data in those objects.
    CreateClassificationJob -> Maybe Int
samplingPercentage :: Prelude.Maybe Prelude.Int,
    -- | The selection type to apply when determining which managed data
    -- identifiers the job uses to analyze data. Valid values are:
    --
    -- -   ALL - Use all the managed data identifiers that Amazon Macie
    --     provides. If you specify this value, don\'t specify any values for
    --     the managedDataIdentifierIds property.
    --
    -- -   EXCLUDE - Use all the managed data identifiers that Macie provides
    --     except the managed data identifiers specified by the
    --     managedDataIdentifierIds property.
    --
    -- -   INCLUDE - Use only the managed data identifiers specified by the
    --     managedDataIdentifierIds property.
    --
    -- -   NONE - Don\'t use any managed data identifiers. If you specify this
    --     value, specify at least one custom data identifier for the job
    --     (customDataIdentifierIds) and don\'t specify any values for the
    --     managedDataIdentifierIds property.
    --
    -- If you don\'t specify a value for this property, the job uses all
    -- managed data identifiers. If you don\'t specify a value for this
    -- property or you specify ALL or EXCLUDE for a recurring job, the job also
    -- uses new managed data identifiers as they are released.
    CreateClassificationJob -> Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector :: Prelude.Maybe ManagedDataIdentifierSelector,
    -- | An array of unique identifiers, one for each custom data identifier for
    -- the job to use when it analyzes data. To use only managed data
    -- identifiers, don\'t specify a value for this property and specify a
    -- value other than NONE for the managedDataIdentifierSelector property.
    CreateClassificationJob -> Maybe [Text]
customDataIdentifierIds :: Prelude.Maybe [Prelude.Text],
    -- | An array of unique identifiers, one for each managed data identifier for
    -- the job to include (use) or exclude (not use) when it analyzes data.
    -- Inclusion or exclusion depends on the managed data identifier selection
    -- type that you specify for the job (managedDataIdentifierSelector).
    --
    -- To retrieve a list of valid values for this property, use the
    -- ListManagedDataIdentifiers operation.
    CreateClassificationJob -> Maybe [Text]
managedDataIdentifierIds :: Prelude.Maybe [Prelude.Text],
    -- | A custom description of the job. The description can contain as many as
    -- 200 characters.
    CreateClassificationJob -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | A map of key-value pairs that specifies the tags to associate with the
    -- job.
    --
    -- A job can have a maximum of 50 tags. Each tag consists of a tag key and
    -- an associated tag value. The maximum length of a tag key is 128
    -- characters. The maximum length of a tag value is 256 characters.
    CreateClassificationJob -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The recurrence pattern for running the job. To run the job only once,
    -- don\'t specify a value for this property and set the value for the
    -- jobType property to ONE_TIME.
    CreateClassificationJob -> Maybe JobScheduleFrequency
scheduleFrequency :: Prelude.Maybe JobScheduleFrequency,
    -- | The S3 buckets that contain the objects to analyze, and the scope of
    -- that analysis.
    CreateClassificationJob -> S3JobDefinition
s3JobDefinition :: S3JobDefinition,
    -- | The schedule for running the job. Valid values are:
    --
    -- -   ONE_TIME - Run the job only once. If you specify this value, don\'t
    --     specify a value for the scheduleFrequency property.
    --
    -- -   SCHEDULED - Run the job on a daily, weekly, or monthly basis. If you
    --     specify this value, use the scheduleFrequency property to define the
    --     recurrence pattern for the job.
    CreateClassificationJob -> JobType
jobType :: JobType,
    -- | A unique, case-sensitive token that you provide to ensure the
    -- idempotency of the request.
    CreateClassificationJob -> Text
clientToken :: Prelude.Text,
    -- | A custom name for the job. The name can contain as many as 500
    -- characters.
    CreateClassificationJob -> Text
name :: Prelude.Text
  }
  deriving (CreateClassificationJob -> CreateClassificationJob -> Bool
(CreateClassificationJob -> CreateClassificationJob -> Bool)
-> (CreateClassificationJob -> CreateClassificationJob -> Bool)
-> Eq CreateClassificationJob
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateClassificationJob -> CreateClassificationJob -> Bool
$c/= :: CreateClassificationJob -> CreateClassificationJob -> Bool
== :: CreateClassificationJob -> CreateClassificationJob -> Bool
$c== :: CreateClassificationJob -> CreateClassificationJob -> Bool
Prelude.Eq, ReadPrec [CreateClassificationJob]
ReadPrec CreateClassificationJob
Int -> ReadS CreateClassificationJob
ReadS [CreateClassificationJob]
(Int -> ReadS CreateClassificationJob)
-> ReadS [CreateClassificationJob]
-> ReadPrec CreateClassificationJob
-> ReadPrec [CreateClassificationJob]
-> Read CreateClassificationJob
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateClassificationJob]
$creadListPrec :: ReadPrec [CreateClassificationJob]
readPrec :: ReadPrec CreateClassificationJob
$creadPrec :: ReadPrec CreateClassificationJob
readList :: ReadS [CreateClassificationJob]
$creadList :: ReadS [CreateClassificationJob]
readsPrec :: Int -> ReadS CreateClassificationJob
$creadsPrec :: Int -> ReadS CreateClassificationJob
Prelude.Read, Int -> CreateClassificationJob -> ShowS
[CreateClassificationJob] -> ShowS
CreateClassificationJob -> String
(Int -> CreateClassificationJob -> ShowS)
-> (CreateClassificationJob -> String)
-> ([CreateClassificationJob] -> ShowS)
-> Show CreateClassificationJob
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateClassificationJob] -> ShowS
$cshowList :: [CreateClassificationJob] -> ShowS
show :: CreateClassificationJob -> String
$cshow :: CreateClassificationJob -> String
showsPrec :: Int -> CreateClassificationJob -> ShowS
$cshowsPrec :: Int -> CreateClassificationJob -> ShowS
Prelude.Show, (forall x.
 CreateClassificationJob -> Rep CreateClassificationJob x)
-> (forall x.
    Rep CreateClassificationJob x -> CreateClassificationJob)
-> Generic CreateClassificationJob
forall x. Rep CreateClassificationJob x -> CreateClassificationJob
forall x. CreateClassificationJob -> Rep CreateClassificationJob x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateClassificationJob x -> CreateClassificationJob
$cfrom :: forall x. CreateClassificationJob -> Rep CreateClassificationJob x
Prelude.Generic)

-- |
-- Create a value of 'CreateClassificationJob' 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:
--
-- 'initialRun', 'createClassificationJob_initialRun' - For a recurring job, specifies whether to analyze all existing, eligible
-- objects immediately after the job is created (true). To analyze only
-- those objects that are created or changed after you create the job and
-- before the job\'s first scheduled run, set this value to false.
--
-- If you configure the job to run only once, don\'t specify a value for
-- this property.
--
-- 'samplingPercentage', 'createClassificationJob_samplingPercentage' - The sampling depth, as a percentage, for the job to apply when
-- processing objects. This value determines the percentage of eligible
-- objects that the job analyzes. If this value is less than 100, Amazon
-- Macie selects the objects to analyze at random, up to the specified
-- percentage, and analyzes all the data in those objects.
--
-- 'managedDataIdentifierSelector', 'createClassificationJob_managedDataIdentifierSelector' - The selection type to apply when determining which managed data
-- identifiers the job uses to analyze data. Valid values are:
--
-- -   ALL - Use all the managed data identifiers that Amazon Macie
--     provides. If you specify this value, don\'t specify any values for
--     the managedDataIdentifierIds property.
--
-- -   EXCLUDE - Use all the managed data identifiers that Macie provides
--     except the managed data identifiers specified by the
--     managedDataIdentifierIds property.
--
-- -   INCLUDE - Use only the managed data identifiers specified by the
--     managedDataIdentifierIds property.
--
-- -   NONE - Don\'t use any managed data identifiers. If you specify this
--     value, specify at least one custom data identifier for the job
--     (customDataIdentifierIds) and don\'t specify any values for the
--     managedDataIdentifierIds property.
--
-- If you don\'t specify a value for this property, the job uses all
-- managed data identifiers. If you don\'t specify a value for this
-- property or you specify ALL or EXCLUDE for a recurring job, the job also
-- uses new managed data identifiers as they are released.
--
-- 'customDataIdentifierIds', 'createClassificationJob_customDataIdentifierIds' - An array of unique identifiers, one for each custom data identifier for
-- the job to use when it analyzes data. To use only managed data
-- identifiers, don\'t specify a value for this property and specify a
-- value other than NONE for the managedDataIdentifierSelector property.
--
-- 'managedDataIdentifierIds', 'createClassificationJob_managedDataIdentifierIds' - An array of unique identifiers, one for each managed data identifier for
-- the job to include (use) or exclude (not use) when it analyzes data.
-- Inclusion or exclusion depends on the managed data identifier selection
-- type that you specify for the job (managedDataIdentifierSelector).
--
-- To retrieve a list of valid values for this property, use the
-- ListManagedDataIdentifiers operation.
--
-- 'description', 'createClassificationJob_description' - A custom description of the job. The description can contain as many as
-- 200 characters.
--
-- 'tags', 'createClassificationJob_tags' - A map of key-value pairs that specifies the tags to associate with the
-- job.
--
-- A job can have a maximum of 50 tags. Each tag consists of a tag key and
-- an associated tag value. The maximum length of a tag key is 128
-- characters. The maximum length of a tag value is 256 characters.
--
-- 'scheduleFrequency', 'createClassificationJob_scheduleFrequency' - The recurrence pattern for running the job. To run the job only once,
-- don\'t specify a value for this property and set the value for the
-- jobType property to ONE_TIME.
--
-- 's3JobDefinition', 'createClassificationJob_s3JobDefinition' - The S3 buckets that contain the objects to analyze, and the scope of
-- that analysis.
--
-- 'jobType', 'createClassificationJob_jobType' - The schedule for running the job. Valid values are:
--
-- -   ONE_TIME - Run the job only once. If you specify this value, don\'t
--     specify a value for the scheduleFrequency property.
--
-- -   SCHEDULED - Run the job on a daily, weekly, or monthly basis. If you
--     specify this value, use the scheduleFrequency property to define the
--     recurrence pattern for the job.
--
-- 'clientToken', 'createClassificationJob_clientToken' - A unique, case-sensitive token that you provide to ensure the
-- idempotency of the request.
--
-- 'name', 'createClassificationJob_name' - A custom name for the job. The name can contain as many as 500
-- characters.
newCreateClassificationJob ::
  -- | 's3JobDefinition'
  S3JobDefinition ->
  -- | 'jobType'
  JobType ->
  -- | 'clientToken'
  Prelude.Text ->
  -- | 'name'
  Prelude.Text ->
  CreateClassificationJob
newCreateClassificationJob :: S3JobDefinition
-> JobType -> Text -> Text -> CreateClassificationJob
newCreateClassificationJob
  S3JobDefinition
pS3JobDefinition_
  JobType
pJobType_
  Text
pClientToken_
  Text
pName_ =
    CreateClassificationJob' :: Maybe Bool
-> Maybe Int
-> Maybe ManagedDataIdentifierSelector
-> Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe JobScheduleFrequency
-> S3JobDefinition
-> JobType
-> Text
-> Text
-> CreateClassificationJob
CreateClassificationJob'
      { $sel:initialRun:CreateClassificationJob' :: Maybe Bool
initialRun =
          Maybe Bool
forall a. Maybe a
Prelude.Nothing,
        $sel:samplingPercentage:CreateClassificationJob' :: Maybe Int
samplingPercentage = Maybe Int
forall a. Maybe a
Prelude.Nothing,
        $sel:managedDataIdentifierSelector:CreateClassificationJob' :: Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector = Maybe ManagedDataIdentifierSelector
forall a. Maybe a
Prelude.Nothing,
        $sel:customDataIdentifierIds:CreateClassificationJob' :: Maybe [Text]
customDataIdentifierIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:managedDataIdentifierIds:CreateClassificationJob' :: Maybe [Text]
managedDataIdentifierIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
        $sel:description:CreateClassificationJob' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
        $sel:tags:CreateClassificationJob' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
        $sel:scheduleFrequency:CreateClassificationJob' :: Maybe JobScheduleFrequency
scheduleFrequency = Maybe JobScheduleFrequency
forall a. Maybe a
Prelude.Nothing,
        $sel:s3JobDefinition:CreateClassificationJob' :: S3JobDefinition
s3JobDefinition = S3JobDefinition
pS3JobDefinition_,
        $sel:jobType:CreateClassificationJob' :: JobType
jobType = JobType
pJobType_,
        $sel:clientToken:CreateClassificationJob' :: Text
clientToken = Text
pClientToken_,
        $sel:name:CreateClassificationJob' :: Text
name = Text
pName_
      }

-- | For a recurring job, specifies whether to analyze all existing, eligible
-- objects immediately after the job is created (true). To analyze only
-- those objects that are created or changed after you create the job and
-- before the job\'s first scheduled run, set this value to false.
--
-- If you configure the job to run only once, don\'t specify a value for
-- this property.
createClassificationJob_initialRun :: Lens.Lens' CreateClassificationJob (Prelude.Maybe Prelude.Bool)
createClassificationJob_initialRun :: (Maybe Bool -> f (Maybe Bool))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_initialRun = (CreateClassificationJob -> Maybe Bool)
-> (CreateClassificationJob
    -> Maybe Bool -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe Bool
initialRun :: Maybe Bool
$sel:initialRun:CreateClassificationJob' :: CreateClassificationJob -> Maybe Bool
initialRun} -> Maybe Bool
initialRun) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe Bool
a -> CreateClassificationJob
s {$sel:initialRun:CreateClassificationJob' :: Maybe Bool
initialRun = Maybe Bool
a} :: CreateClassificationJob)

-- | The sampling depth, as a percentage, for the job to apply when
-- processing objects. This value determines the percentage of eligible
-- objects that the job analyzes. If this value is less than 100, Amazon
-- Macie selects the objects to analyze at random, up to the specified
-- percentage, and analyzes all the data in those objects.
createClassificationJob_samplingPercentage :: Lens.Lens' CreateClassificationJob (Prelude.Maybe Prelude.Int)
createClassificationJob_samplingPercentage :: (Maybe Int -> f (Maybe Int))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_samplingPercentage = (CreateClassificationJob -> Maybe Int)
-> (CreateClassificationJob
    -> Maybe Int -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe Int
samplingPercentage :: Maybe Int
$sel:samplingPercentage:CreateClassificationJob' :: CreateClassificationJob -> Maybe Int
samplingPercentage} -> Maybe Int
samplingPercentage) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe Int
a -> CreateClassificationJob
s {$sel:samplingPercentage:CreateClassificationJob' :: Maybe Int
samplingPercentage = Maybe Int
a} :: CreateClassificationJob)

-- | The selection type to apply when determining which managed data
-- identifiers the job uses to analyze data. Valid values are:
--
-- -   ALL - Use all the managed data identifiers that Amazon Macie
--     provides. If you specify this value, don\'t specify any values for
--     the managedDataIdentifierIds property.
--
-- -   EXCLUDE - Use all the managed data identifiers that Macie provides
--     except the managed data identifiers specified by the
--     managedDataIdentifierIds property.
--
-- -   INCLUDE - Use only the managed data identifiers specified by the
--     managedDataIdentifierIds property.
--
-- -   NONE - Don\'t use any managed data identifiers. If you specify this
--     value, specify at least one custom data identifier for the job
--     (customDataIdentifierIds) and don\'t specify any values for the
--     managedDataIdentifierIds property.
--
-- If you don\'t specify a value for this property, the job uses all
-- managed data identifiers. If you don\'t specify a value for this
-- property or you specify ALL or EXCLUDE for a recurring job, the job also
-- uses new managed data identifiers as they are released.
createClassificationJob_managedDataIdentifierSelector :: Lens.Lens' CreateClassificationJob (Prelude.Maybe ManagedDataIdentifierSelector)
createClassificationJob_managedDataIdentifierSelector :: (Maybe ManagedDataIdentifierSelector
 -> f (Maybe ManagedDataIdentifierSelector))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_managedDataIdentifierSelector = (CreateClassificationJob -> Maybe ManagedDataIdentifierSelector)
-> (CreateClassificationJob
    -> Maybe ManagedDataIdentifierSelector -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe ManagedDataIdentifierSelector)
     (Maybe ManagedDataIdentifierSelector)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector :: Maybe ManagedDataIdentifierSelector
$sel:managedDataIdentifierSelector:CreateClassificationJob' :: CreateClassificationJob -> Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector} -> Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe ManagedDataIdentifierSelector
a -> CreateClassificationJob
s {$sel:managedDataIdentifierSelector:CreateClassificationJob' :: Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector = Maybe ManagedDataIdentifierSelector
a} :: CreateClassificationJob)

-- | An array of unique identifiers, one for each custom data identifier for
-- the job to use when it analyzes data. To use only managed data
-- identifiers, don\'t specify a value for this property and specify a
-- value other than NONE for the managedDataIdentifierSelector property.
createClassificationJob_customDataIdentifierIds :: Lens.Lens' CreateClassificationJob (Prelude.Maybe [Prelude.Text])
createClassificationJob_customDataIdentifierIds :: (Maybe [Text] -> f (Maybe [Text]))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_customDataIdentifierIds = (CreateClassificationJob -> Maybe [Text])
-> (CreateClassificationJob
    -> Maybe [Text] -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe [Text])
     (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe [Text]
customDataIdentifierIds :: Maybe [Text]
$sel:customDataIdentifierIds:CreateClassificationJob' :: CreateClassificationJob -> Maybe [Text]
customDataIdentifierIds} -> Maybe [Text]
customDataIdentifierIds) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe [Text]
a -> CreateClassificationJob
s {$sel:customDataIdentifierIds:CreateClassificationJob' :: Maybe [Text]
customDataIdentifierIds = Maybe [Text]
a} :: CreateClassificationJob) ((Maybe [Text] -> f (Maybe [Text]))
 -> CreateClassificationJob -> f CreateClassificationJob)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> CreateClassificationJob
-> f CreateClassificationJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | An array of unique identifiers, one for each managed data identifier for
-- the job to include (use) or exclude (not use) when it analyzes data.
-- Inclusion or exclusion depends on the managed data identifier selection
-- type that you specify for the job (managedDataIdentifierSelector).
--
-- To retrieve a list of valid values for this property, use the
-- ListManagedDataIdentifiers operation.
createClassificationJob_managedDataIdentifierIds :: Lens.Lens' CreateClassificationJob (Prelude.Maybe [Prelude.Text])
createClassificationJob_managedDataIdentifierIds :: (Maybe [Text] -> f (Maybe [Text]))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_managedDataIdentifierIds = (CreateClassificationJob -> Maybe [Text])
-> (CreateClassificationJob
    -> Maybe [Text] -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe [Text])
     (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe [Text]
managedDataIdentifierIds :: Maybe [Text]
$sel:managedDataIdentifierIds:CreateClassificationJob' :: CreateClassificationJob -> Maybe [Text]
managedDataIdentifierIds} -> Maybe [Text]
managedDataIdentifierIds) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe [Text]
a -> CreateClassificationJob
s {$sel:managedDataIdentifierIds:CreateClassificationJob' :: Maybe [Text]
managedDataIdentifierIds = Maybe [Text]
a} :: CreateClassificationJob) ((Maybe [Text] -> f (Maybe [Text]))
 -> CreateClassificationJob -> f CreateClassificationJob)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> CreateClassificationJob
-> f CreateClassificationJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
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 AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A custom description of the job. The description can contain as many as
-- 200 characters.
createClassificationJob_description :: Lens.Lens' CreateClassificationJob (Prelude.Maybe Prelude.Text)
createClassificationJob_description :: (Maybe Text -> f (Maybe Text))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_description = (CreateClassificationJob -> Maybe Text)
-> (CreateClassificationJob
    -> Maybe Text -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe Text
description :: Maybe Text
$sel:description:CreateClassificationJob' :: CreateClassificationJob -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe Text
a -> CreateClassificationJob
s {$sel:description:CreateClassificationJob' :: Maybe Text
description = Maybe Text
a} :: CreateClassificationJob)

-- | A map of key-value pairs that specifies the tags to associate with the
-- job.
--
-- A job can have a maximum of 50 tags. Each tag consists of a tag key and
-- an associated tag value. The maximum length of a tag key is 128
-- characters. The maximum length of a tag value is 256 characters.
createClassificationJob_tags :: Lens.Lens' CreateClassificationJob (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createClassificationJob_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_tags = (CreateClassificationJob -> Maybe (HashMap Text Text))
-> (CreateClassificationJob
    -> Maybe (HashMap Text Text) -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:CreateClassificationJob' :: CreateClassificationJob -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe (HashMap Text Text)
a -> CreateClassificationJob
s {$sel:tags:CreateClassificationJob' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: CreateClassificationJob) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> CreateClassificationJob -> f CreateClassificationJob)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> CreateClassificationJob
-> f CreateClassificationJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
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 AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The recurrence pattern for running the job. To run the job only once,
-- don\'t specify a value for this property and set the value for the
-- jobType property to ONE_TIME.
createClassificationJob_scheduleFrequency :: Lens.Lens' CreateClassificationJob (Prelude.Maybe JobScheduleFrequency)
createClassificationJob_scheduleFrequency :: (Maybe JobScheduleFrequency -> f (Maybe JobScheduleFrequency))
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_scheduleFrequency = (CreateClassificationJob -> Maybe JobScheduleFrequency)
-> (CreateClassificationJob
    -> Maybe JobScheduleFrequency -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     (Maybe JobScheduleFrequency)
     (Maybe JobScheduleFrequency)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Maybe JobScheduleFrequency
scheduleFrequency :: Maybe JobScheduleFrequency
$sel:scheduleFrequency:CreateClassificationJob' :: CreateClassificationJob -> Maybe JobScheduleFrequency
scheduleFrequency} -> Maybe JobScheduleFrequency
scheduleFrequency) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Maybe JobScheduleFrequency
a -> CreateClassificationJob
s {$sel:scheduleFrequency:CreateClassificationJob' :: Maybe JobScheduleFrequency
scheduleFrequency = Maybe JobScheduleFrequency
a} :: CreateClassificationJob)

-- | The S3 buckets that contain the objects to analyze, and the scope of
-- that analysis.
createClassificationJob_s3JobDefinition :: Lens.Lens' CreateClassificationJob S3JobDefinition
createClassificationJob_s3JobDefinition :: (S3JobDefinition -> f S3JobDefinition)
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_s3JobDefinition = (CreateClassificationJob -> S3JobDefinition)
-> (CreateClassificationJob
    -> S3JobDefinition -> CreateClassificationJob)
-> Lens
     CreateClassificationJob
     CreateClassificationJob
     S3JobDefinition
     S3JobDefinition
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {S3JobDefinition
s3JobDefinition :: S3JobDefinition
$sel:s3JobDefinition:CreateClassificationJob' :: CreateClassificationJob -> S3JobDefinition
s3JobDefinition} -> S3JobDefinition
s3JobDefinition) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} S3JobDefinition
a -> CreateClassificationJob
s {$sel:s3JobDefinition:CreateClassificationJob' :: S3JobDefinition
s3JobDefinition = S3JobDefinition
a} :: CreateClassificationJob)

-- | The schedule for running the job. Valid values are:
--
-- -   ONE_TIME - Run the job only once. If you specify this value, don\'t
--     specify a value for the scheduleFrequency property.
--
-- -   SCHEDULED - Run the job on a daily, weekly, or monthly basis. If you
--     specify this value, use the scheduleFrequency property to define the
--     recurrence pattern for the job.
createClassificationJob_jobType :: Lens.Lens' CreateClassificationJob JobType
createClassificationJob_jobType :: (JobType -> f JobType)
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_jobType = (CreateClassificationJob -> JobType)
-> (CreateClassificationJob -> JobType -> CreateClassificationJob)
-> Lens
     CreateClassificationJob CreateClassificationJob JobType JobType
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {JobType
jobType :: JobType
$sel:jobType:CreateClassificationJob' :: CreateClassificationJob -> JobType
jobType} -> JobType
jobType) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} JobType
a -> CreateClassificationJob
s {$sel:jobType:CreateClassificationJob' :: JobType
jobType = JobType
a} :: CreateClassificationJob)

-- | A unique, case-sensitive token that you provide to ensure the
-- idempotency of the request.
createClassificationJob_clientToken :: Lens.Lens' CreateClassificationJob Prelude.Text
createClassificationJob_clientToken :: (Text -> f Text)
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_clientToken = (CreateClassificationJob -> Text)
-> (CreateClassificationJob -> Text -> CreateClassificationJob)
-> Lens CreateClassificationJob CreateClassificationJob Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Text
clientToken :: Text
$sel:clientToken:CreateClassificationJob' :: CreateClassificationJob -> Text
clientToken} -> Text
clientToken) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Text
a -> CreateClassificationJob
s {$sel:clientToken:CreateClassificationJob' :: Text
clientToken = Text
a} :: CreateClassificationJob)

-- | A custom name for the job. The name can contain as many as 500
-- characters.
createClassificationJob_name :: Lens.Lens' CreateClassificationJob Prelude.Text
createClassificationJob_name :: (Text -> f Text)
-> CreateClassificationJob -> f CreateClassificationJob
createClassificationJob_name = (CreateClassificationJob -> Text)
-> (CreateClassificationJob -> Text -> CreateClassificationJob)
-> Lens CreateClassificationJob CreateClassificationJob Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJob' {Text
name :: Text
$sel:name:CreateClassificationJob' :: CreateClassificationJob -> Text
name} -> Text
name) (\s :: CreateClassificationJob
s@CreateClassificationJob' {} Text
a -> CreateClassificationJob
s {$sel:name:CreateClassificationJob' :: Text
name = Text
a} :: CreateClassificationJob)

instance Core.AWSRequest CreateClassificationJob where
  type
    AWSResponse CreateClassificationJob =
      CreateClassificationJobResponse
  request :: CreateClassificationJob -> Request CreateClassificationJob
request = Service
-> CreateClassificationJob -> Request CreateClassificationJob
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy CreateClassificationJob
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateClassificationJob)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse CreateClassificationJob))
-> Logger
-> Service
-> Proxy CreateClassificationJob
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse CreateClassificationJob)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe Text -> Maybe Text -> Int -> CreateClassificationJobResponse
CreateClassificationJobResponse'
            (Maybe Text
 -> Maybe Text -> Int -> CreateClassificationJobResponse)
-> Either String (Maybe Text)
-> Either
     String (Maybe Text -> Int -> CreateClassificationJobResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"jobId")
            Either
  String (Maybe Text -> Int -> CreateClassificationJobResponse)
-> Either String (Maybe Text)
-> Either String (Int -> CreateClassificationJobResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"jobArn")
            Either String (Int -> CreateClassificationJobResponse)
-> Either String Int
-> Either String CreateClassificationJobResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable CreateClassificationJob

instance Prelude.NFData CreateClassificationJob

instance Core.ToHeaders CreateClassificationJob where
  toHeaders :: CreateClassificationJob -> ResponseHeaders
toHeaders =
    ResponseHeaders -> CreateClassificationJob -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON CreateClassificationJob where
  toJSON :: CreateClassificationJob -> Value
toJSON CreateClassificationJob' {Maybe Bool
Maybe Int
Maybe [Text]
Maybe Text
Maybe (HashMap Text Text)
Maybe ManagedDataIdentifierSelector
Maybe JobScheduleFrequency
Text
JobType
S3JobDefinition
name :: Text
clientToken :: Text
jobType :: JobType
s3JobDefinition :: S3JobDefinition
scheduleFrequency :: Maybe JobScheduleFrequency
tags :: Maybe (HashMap Text Text)
description :: Maybe Text
managedDataIdentifierIds :: Maybe [Text]
customDataIdentifierIds :: Maybe [Text]
managedDataIdentifierSelector :: Maybe ManagedDataIdentifierSelector
samplingPercentage :: Maybe Int
initialRun :: Maybe Bool
$sel:name:CreateClassificationJob' :: CreateClassificationJob -> Text
$sel:clientToken:CreateClassificationJob' :: CreateClassificationJob -> Text
$sel:jobType:CreateClassificationJob' :: CreateClassificationJob -> JobType
$sel:s3JobDefinition:CreateClassificationJob' :: CreateClassificationJob -> S3JobDefinition
$sel:scheduleFrequency:CreateClassificationJob' :: CreateClassificationJob -> Maybe JobScheduleFrequency
$sel:tags:CreateClassificationJob' :: CreateClassificationJob -> Maybe (HashMap Text Text)
$sel:description:CreateClassificationJob' :: CreateClassificationJob -> Maybe Text
$sel:managedDataIdentifierIds:CreateClassificationJob' :: CreateClassificationJob -> Maybe [Text]
$sel:customDataIdentifierIds:CreateClassificationJob' :: CreateClassificationJob -> Maybe [Text]
$sel:managedDataIdentifierSelector:CreateClassificationJob' :: CreateClassificationJob -> Maybe ManagedDataIdentifierSelector
$sel:samplingPercentage:CreateClassificationJob' :: CreateClassificationJob -> Maybe Int
$sel:initialRun:CreateClassificationJob' :: CreateClassificationJob -> Maybe Bool
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"initialRun" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
initialRun,
            (Text
"samplingPercentage" 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
samplingPercentage,
            (Text
"managedDataIdentifierSelector" Text -> ManagedDataIdentifierSelector -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (ManagedDataIdentifierSelector -> Pair)
-> Maybe ManagedDataIdentifierSelector -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ManagedDataIdentifierSelector
managedDataIdentifierSelector,
            (Text
"customDataIdentifierIds" 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]
customDataIdentifierIds,
            (Text
"managedDataIdentifierIds" 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]
managedDataIdentifierIds,
            (Text
"description" 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
description,
            (Text
"tags" Text -> HashMap Text Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (HashMap Text Text -> Pair)
-> Maybe (HashMap Text Text) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (HashMap Text Text)
tags,
            (Text
"scheduleFrequency" Text -> JobScheduleFrequency -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (JobScheduleFrequency -> Pair)
-> Maybe JobScheduleFrequency -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe JobScheduleFrequency
scheduleFrequency,
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
              (Text
"s3JobDefinition" Text -> S3JobDefinition -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= S3JobDefinition
s3JobDefinition),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"jobType" Text -> JobType -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= JobType
jobType),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"clientToken" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
clientToken),
            Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
name)
          ]
      )

instance Core.ToPath CreateClassificationJob where
  toPath :: CreateClassificationJob -> ByteString
toPath = ByteString -> CreateClassificationJob -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/jobs"

instance Core.ToQuery CreateClassificationJob where
  toQuery :: CreateClassificationJob -> QueryString
toQuery = QueryString -> CreateClassificationJob -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newCreateClassificationJobResponse' smart constructor.
data CreateClassificationJobResponse = CreateClassificationJobResponse'
  { -- | The unique identifier for the job.
    CreateClassificationJobResponse -> Maybe Text
jobId :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the job.
    CreateClassificationJobResponse -> Maybe Text
jobArn :: Prelude.Maybe Prelude.Text,
    -- | The response's http status code.
    CreateClassificationJobResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (CreateClassificationJobResponse
-> CreateClassificationJobResponse -> Bool
(CreateClassificationJobResponse
 -> CreateClassificationJobResponse -> Bool)
-> (CreateClassificationJobResponse
    -> CreateClassificationJobResponse -> Bool)
-> Eq CreateClassificationJobResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateClassificationJobResponse
-> CreateClassificationJobResponse -> Bool
$c/= :: CreateClassificationJobResponse
-> CreateClassificationJobResponse -> Bool
== :: CreateClassificationJobResponse
-> CreateClassificationJobResponse -> Bool
$c== :: CreateClassificationJobResponse
-> CreateClassificationJobResponse -> Bool
Prelude.Eq, ReadPrec [CreateClassificationJobResponse]
ReadPrec CreateClassificationJobResponse
Int -> ReadS CreateClassificationJobResponse
ReadS [CreateClassificationJobResponse]
(Int -> ReadS CreateClassificationJobResponse)
-> ReadS [CreateClassificationJobResponse]
-> ReadPrec CreateClassificationJobResponse
-> ReadPrec [CreateClassificationJobResponse]
-> Read CreateClassificationJobResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateClassificationJobResponse]
$creadListPrec :: ReadPrec [CreateClassificationJobResponse]
readPrec :: ReadPrec CreateClassificationJobResponse
$creadPrec :: ReadPrec CreateClassificationJobResponse
readList :: ReadS [CreateClassificationJobResponse]
$creadList :: ReadS [CreateClassificationJobResponse]
readsPrec :: Int -> ReadS CreateClassificationJobResponse
$creadsPrec :: Int -> ReadS CreateClassificationJobResponse
Prelude.Read, Int -> CreateClassificationJobResponse -> ShowS
[CreateClassificationJobResponse] -> ShowS
CreateClassificationJobResponse -> String
(Int -> CreateClassificationJobResponse -> ShowS)
-> (CreateClassificationJobResponse -> String)
-> ([CreateClassificationJobResponse] -> ShowS)
-> Show CreateClassificationJobResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateClassificationJobResponse] -> ShowS
$cshowList :: [CreateClassificationJobResponse] -> ShowS
show :: CreateClassificationJobResponse -> String
$cshow :: CreateClassificationJobResponse -> String
showsPrec :: Int -> CreateClassificationJobResponse -> ShowS
$cshowsPrec :: Int -> CreateClassificationJobResponse -> ShowS
Prelude.Show, (forall x.
 CreateClassificationJobResponse
 -> Rep CreateClassificationJobResponse x)
-> (forall x.
    Rep CreateClassificationJobResponse x
    -> CreateClassificationJobResponse)
-> Generic CreateClassificationJobResponse
forall x.
Rep CreateClassificationJobResponse x
-> CreateClassificationJobResponse
forall x.
CreateClassificationJobResponse
-> Rep CreateClassificationJobResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CreateClassificationJobResponse x
-> CreateClassificationJobResponse
$cfrom :: forall x.
CreateClassificationJobResponse
-> Rep CreateClassificationJobResponse x
Prelude.Generic)

-- |
-- Create a value of 'CreateClassificationJobResponse' 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:
--
-- 'jobId', 'createClassificationJobResponse_jobId' - The unique identifier for the job.
--
-- 'jobArn', 'createClassificationJobResponse_jobArn' - The Amazon Resource Name (ARN) of the job.
--
-- 'httpStatus', 'createClassificationJobResponse_httpStatus' - The response's http status code.
newCreateClassificationJobResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  CreateClassificationJobResponse
newCreateClassificationJobResponse :: Int -> CreateClassificationJobResponse
newCreateClassificationJobResponse Int
pHttpStatus_ =
  CreateClassificationJobResponse' :: Maybe Text -> Maybe Text -> Int -> CreateClassificationJobResponse
CreateClassificationJobResponse'
    { $sel:jobId:CreateClassificationJobResponse' :: Maybe Text
jobId =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:jobArn:CreateClassificationJobResponse' :: Maybe Text
jobArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:CreateClassificationJobResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The unique identifier for the job.
createClassificationJobResponse_jobId :: Lens.Lens' CreateClassificationJobResponse (Prelude.Maybe Prelude.Text)
createClassificationJobResponse_jobId :: (Maybe Text -> f (Maybe Text))
-> CreateClassificationJobResponse
-> f CreateClassificationJobResponse
createClassificationJobResponse_jobId = (CreateClassificationJobResponse -> Maybe Text)
-> (CreateClassificationJobResponse
    -> Maybe Text -> CreateClassificationJobResponse)
-> Lens
     CreateClassificationJobResponse
     CreateClassificationJobResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJobResponse' {Maybe Text
jobId :: Maybe Text
$sel:jobId:CreateClassificationJobResponse' :: CreateClassificationJobResponse -> Maybe Text
jobId} -> Maybe Text
jobId) (\s :: CreateClassificationJobResponse
s@CreateClassificationJobResponse' {} Maybe Text
a -> CreateClassificationJobResponse
s {$sel:jobId:CreateClassificationJobResponse' :: Maybe Text
jobId = Maybe Text
a} :: CreateClassificationJobResponse)

-- | The Amazon Resource Name (ARN) of the job.
createClassificationJobResponse_jobArn :: Lens.Lens' CreateClassificationJobResponse (Prelude.Maybe Prelude.Text)
createClassificationJobResponse_jobArn :: (Maybe Text -> f (Maybe Text))
-> CreateClassificationJobResponse
-> f CreateClassificationJobResponse
createClassificationJobResponse_jobArn = (CreateClassificationJobResponse -> Maybe Text)
-> (CreateClassificationJobResponse
    -> Maybe Text -> CreateClassificationJobResponse)
-> Lens
     CreateClassificationJobResponse
     CreateClassificationJobResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJobResponse' {Maybe Text
jobArn :: Maybe Text
$sel:jobArn:CreateClassificationJobResponse' :: CreateClassificationJobResponse -> Maybe Text
jobArn} -> Maybe Text
jobArn) (\s :: CreateClassificationJobResponse
s@CreateClassificationJobResponse' {} Maybe Text
a -> CreateClassificationJobResponse
s {$sel:jobArn:CreateClassificationJobResponse' :: Maybe Text
jobArn = Maybe Text
a} :: CreateClassificationJobResponse)

-- | The response's http status code.
createClassificationJobResponse_httpStatus :: Lens.Lens' CreateClassificationJobResponse Prelude.Int
createClassificationJobResponse_httpStatus :: (Int -> f Int)
-> CreateClassificationJobResponse
-> f CreateClassificationJobResponse
createClassificationJobResponse_httpStatus = (CreateClassificationJobResponse -> Int)
-> (CreateClassificationJobResponse
    -> Int -> CreateClassificationJobResponse)
-> Lens
     CreateClassificationJobResponse
     CreateClassificationJobResponse
     Int
     Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateClassificationJobResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateClassificationJobResponse' :: CreateClassificationJobResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateClassificationJobResponse
s@CreateClassificationJobResponse' {} Int
a -> CreateClassificationJobResponse
s {$sel:httpStatus:CreateClassificationJobResponse' :: Int
httpStatus = Int
a} :: CreateClassificationJobResponse)

instance
  Prelude.NFData
    CreateClassificationJobResponse