{-# 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.SageMaker.Types.CandidateArtifactLocations
-- 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.SageMaker.Types.CandidateArtifactLocations where

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

-- | The location of artifacts for an AutoML candidate job.
--
-- /See:/ 'newCandidateArtifactLocations' smart constructor.
data CandidateArtifactLocations = CandidateArtifactLocations'
  { -- | The Amazon S3 prefix to the explainability artifacts generated for the
    -- AutoML candidate.
    CandidateArtifactLocations -> Text
explainability :: Prelude.Text
  }
  deriving (CandidateArtifactLocations -> CandidateArtifactLocations -> Bool
(CandidateArtifactLocations -> CandidateArtifactLocations -> Bool)
-> (CandidateArtifactLocations
    -> CandidateArtifactLocations -> Bool)
-> Eq CandidateArtifactLocations
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CandidateArtifactLocations -> CandidateArtifactLocations -> Bool
$c/= :: CandidateArtifactLocations -> CandidateArtifactLocations -> Bool
== :: CandidateArtifactLocations -> CandidateArtifactLocations -> Bool
$c== :: CandidateArtifactLocations -> CandidateArtifactLocations -> Bool
Prelude.Eq, ReadPrec [CandidateArtifactLocations]
ReadPrec CandidateArtifactLocations
Int -> ReadS CandidateArtifactLocations
ReadS [CandidateArtifactLocations]
(Int -> ReadS CandidateArtifactLocations)
-> ReadS [CandidateArtifactLocations]
-> ReadPrec CandidateArtifactLocations
-> ReadPrec [CandidateArtifactLocations]
-> Read CandidateArtifactLocations
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CandidateArtifactLocations]
$creadListPrec :: ReadPrec [CandidateArtifactLocations]
readPrec :: ReadPrec CandidateArtifactLocations
$creadPrec :: ReadPrec CandidateArtifactLocations
readList :: ReadS [CandidateArtifactLocations]
$creadList :: ReadS [CandidateArtifactLocations]
readsPrec :: Int -> ReadS CandidateArtifactLocations
$creadsPrec :: Int -> ReadS CandidateArtifactLocations
Prelude.Read, Int -> CandidateArtifactLocations -> ShowS
[CandidateArtifactLocations] -> ShowS
CandidateArtifactLocations -> String
(Int -> CandidateArtifactLocations -> ShowS)
-> (CandidateArtifactLocations -> String)
-> ([CandidateArtifactLocations] -> ShowS)
-> Show CandidateArtifactLocations
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CandidateArtifactLocations] -> ShowS
$cshowList :: [CandidateArtifactLocations] -> ShowS
show :: CandidateArtifactLocations -> String
$cshow :: CandidateArtifactLocations -> String
showsPrec :: Int -> CandidateArtifactLocations -> ShowS
$cshowsPrec :: Int -> CandidateArtifactLocations -> ShowS
Prelude.Show, (forall x.
 CandidateArtifactLocations -> Rep CandidateArtifactLocations x)
-> (forall x.
    Rep CandidateArtifactLocations x -> CandidateArtifactLocations)
-> Generic CandidateArtifactLocations
forall x.
Rep CandidateArtifactLocations x -> CandidateArtifactLocations
forall x.
CandidateArtifactLocations -> Rep CandidateArtifactLocations x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CandidateArtifactLocations x -> CandidateArtifactLocations
$cfrom :: forall x.
CandidateArtifactLocations -> Rep CandidateArtifactLocations x
Prelude.Generic)

-- |
-- Create a value of 'CandidateArtifactLocations' 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:
--
-- 'explainability', 'candidateArtifactLocations_explainability' - The Amazon S3 prefix to the explainability artifacts generated for the
-- AutoML candidate.
newCandidateArtifactLocations ::
  -- | 'explainability'
  Prelude.Text ->
  CandidateArtifactLocations
newCandidateArtifactLocations :: Text -> CandidateArtifactLocations
newCandidateArtifactLocations Text
pExplainability_ =
  CandidateArtifactLocations' :: Text -> CandidateArtifactLocations
CandidateArtifactLocations'
    { $sel:explainability:CandidateArtifactLocations' :: Text
explainability =
        Text
pExplainability_
    }

-- | The Amazon S3 prefix to the explainability artifacts generated for the
-- AutoML candidate.
candidateArtifactLocations_explainability :: Lens.Lens' CandidateArtifactLocations Prelude.Text
candidateArtifactLocations_explainability :: (Text -> f Text)
-> CandidateArtifactLocations -> f CandidateArtifactLocations
candidateArtifactLocations_explainability = (CandidateArtifactLocations -> Text)
-> (CandidateArtifactLocations
    -> Text -> CandidateArtifactLocations)
-> Lens
     CandidateArtifactLocations CandidateArtifactLocations Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CandidateArtifactLocations' {Text
explainability :: Text
$sel:explainability:CandidateArtifactLocations' :: CandidateArtifactLocations -> Text
explainability} -> Text
explainability) (\s :: CandidateArtifactLocations
s@CandidateArtifactLocations' {} Text
a -> CandidateArtifactLocations
s {$sel:explainability:CandidateArtifactLocations' :: Text
explainability = Text
a} :: CandidateArtifactLocations)

instance Core.FromJSON CandidateArtifactLocations where
  parseJSON :: Value -> Parser CandidateArtifactLocations
parseJSON =
    String
-> (Object -> Parser CandidateArtifactLocations)
-> Value
-> Parser CandidateArtifactLocations
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"CandidateArtifactLocations"
      ( \Object
x ->
          Text -> CandidateArtifactLocations
CandidateArtifactLocations'
            (Text -> CandidateArtifactLocations)
-> Parser Text -> Parser CandidateArtifactLocations
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"Explainability")
      )

instance Prelude.Hashable CandidateArtifactLocations

instance Prelude.NFData CandidateArtifactLocations