{-# 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.SageMaker.Types.PipelineExperimentConfig where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data PipelineExperimentConfig = PipelineExperimentConfig'
{
PipelineExperimentConfig -> Maybe Text
experimentName :: Prelude.Maybe Prelude.Text,
PipelineExperimentConfig -> Maybe Text
trialName :: Prelude.Maybe Prelude.Text
}
deriving (PipelineExperimentConfig -> PipelineExperimentConfig -> Bool
(PipelineExperimentConfig -> PipelineExperimentConfig -> Bool)
-> (PipelineExperimentConfig -> PipelineExperimentConfig -> Bool)
-> Eq PipelineExperimentConfig
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PipelineExperimentConfig -> PipelineExperimentConfig -> Bool
$c/= :: PipelineExperimentConfig -> PipelineExperimentConfig -> Bool
== :: PipelineExperimentConfig -> PipelineExperimentConfig -> Bool
$c== :: PipelineExperimentConfig -> PipelineExperimentConfig -> Bool
Prelude.Eq, ReadPrec [PipelineExperimentConfig]
ReadPrec PipelineExperimentConfig
Int -> ReadS PipelineExperimentConfig
ReadS [PipelineExperimentConfig]
(Int -> ReadS PipelineExperimentConfig)
-> ReadS [PipelineExperimentConfig]
-> ReadPrec PipelineExperimentConfig
-> ReadPrec [PipelineExperimentConfig]
-> Read PipelineExperimentConfig
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PipelineExperimentConfig]
$creadListPrec :: ReadPrec [PipelineExperimentConfig]
readPrec :: ReadPrec PipelineExperimentConfig
$creadPrec :: ReadPrec PipelineExperimentConfig
readList :: ReadS [PipelineExperimentConfig]
$creadList :: ReadS [PipelineExperimentConfig]
readsPrec :: Int -> ReadS PipelineExperimentConfig
$creadsPrec :: Int -> ReadS PipelineExperimentConfig
Prelude.Read, Int -> PipelineExperimentConfig -> ShowS
[PipelineExperimentConfig] -> ShowS
PipelineExperimentConfig -> String
(Int -> PipelineExperimentConfig -> ShowS)
-> (PipelineExperimentConfig -> String)
-> ([PipelineExperimentConfig] -> ShowS)
-> Show PipelineExperimentConfig
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PipelineExperimentConfig] -> ShowS
$cshowList :: [PipelineExperimentConfig] -> ShowS
show :: PipelineExperimentConfig -> String
$cshow :: PipelineExperimentConfig -> String
showsPrec :: Int -> PipelineExperimentConfig -> ShowS
$cshowsPrec :: Int -> PipelineExperimentConfig -> ShowS
Prelude.Show, (forall x.
PipelineExperimentConfig -> Rep PipelineExperimentConfig x)
-> (forall x.
Rep PipelineExperimentConfig x -> PipelineExperimentConfig)
-> Generic PipelineExperimentConfig
forall x.
Rep PipelineExperimentConfig x -> PipelineExperimentConfig
forall x.
PipelineExperimentConfig -> Rep PipelineExperimentConfig x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PipelineExperimentConfig x -> PipelineExperimentConfig
$cfrom :: forall x.
PipelineExperimentConfig -> Rep PipelineExperimentConfig x
Prelude.Generic)
newPipelineExperimentConfig ::
PipelineExperimentConfig
newPipelineExperimentConfig :: PipelineExperimentConfig
newPipelineExperimentConfig =
PipelineExperimentConfig' :: Maybe Text -> Maybe Text -> PipelineExperimentConfig
PipelineExperimentConfig'
{ $sel:experimentName:PipelineExperimentConfig' :: Maybe Text
experimentName =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:trialName:PipelineExperimentConfig' :: Maybe Text
trialName = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
pipelineExperimentConfig_experimentName :: Lens.Lens' PipelineExperimentConfig (Prelude.Maybe Prelude.Text)
pipelineExperimentConfig_experimentName :: (Maybe Text -> f (Maybe Text))
-> PipelineExperimentConfig -> f PipelineExperimentConfig
pipelineExperimentConfig_experimentName = (PipelineExperimentConfig -> Maybe Text)
-> (PipelineExperimentConfig
-> Maybe Text -> PipelineExperimentConfig)
-> Lens
PipelineExperimentConfig
PipelineExperimentConfig
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PipelineExperimentConfig' {Maybe Text
experimentName :: Maybe Text
$sel:experimentName:PipelineExperimentConfig' :: PipelineExperimentConfig -> Maybe Text
experimentName} -> Maybe Text
experimentName) (\s :: PipelineExperimentConfig
s@PipelineExperimentConfig' {} Maybe Text
a -> PipelineExperimentConfig
s {$sel:experimentName:PipelineExperimentConfig' :: Maybe Text
experimentName = Maybe Text
a} :: PipelineExperimentConfig)
pipelineExperimentConfig_trialName :: Lens.Lens' PipelineExperimentConfig (Prelude.Maybe Prelude.Text)
pipelineExperimentConfig_trialName :: (Maybe Text -> f (Maybe Text))
-> PipelineExperimentConfig -> f PipelineExperimentConfig
pipelineExperimentConfig_trialName = (PipelineExperimentConfig -> Maybe Text)
-> (PipelineExperimentConfig
-> Maybe Text -> PipelineExperimentConfig)
-> Lens
PipelineExperimentConfig
PipelineExperimentConfig
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PipelineExperimentConfig' {Maybe Text
trialName :: Maybe Text
$sel:trialName:PipelineExperimentConfig' :: PipelineExperimentConfig -> Maybe Text
trialName} -> Maybe Text
trialName) (\s :: PipelineExperimentConfig
s@PipelineExperimentConfig' {} Maybe Text
a -> PipelineExperimentConfig
s {$sel:trialName:PipelineExperimentConfig' :: Maybe Text
trialName = Maybe Text
a} :: PipelineExperimentConfig)
instance Core.FromJSON PipelineExperimentConfig where
parseJSON :: Value -> Parser PipelineExperimentConfig
parseJSON =
String
-> (Object -> Parser PipelineExperimentConfig)
-> Value
-> Parser PipelineExperimentConfig
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"PipelineExperimentConfig"
( \Object
x ->
Maybe Text -> Maybe Text -> PipelineExperimentConfig
PipelineExperimentConfig'
(Maybe Text -> Maybe Text -> PipelineExperimentConfig)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> PipelineExperimentConfig)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExperimentName")
Parser (Maybe Text -> PipelineExperimentConfig)
-> Parser (Maybe Text) -> Parser PipelineExperimentConfig
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TrialName")
)
instance Prelude.Hashable PipelineExperimentConfig
instance Prelude.NFData PipelineExperimentConfig