{-# 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.AlgorithmStatusDetails where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SageMaker.Types.AlgorithmStatusItem
data AlgorithmStatusDetails = AlgorithmStatusDetails'
{
AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem]
imageScanStatuses :: Prelude.Maybe [AlgorithmStatusItem],
AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem]
validationStatuses :: Prelude.Maybe [AlgorithmStatusItem]
}
deriving (AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool
(AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool)
-> (AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool)
-> Eq AlgorithmStatusDetails
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool
$c/= :: AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool
== :: AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool
$c== :: AlgorithmStatusDetails -> AlgorithmStatusDetails -> Bool
Prelude.Eq, ReadPrec [AlgorithmStatusDetails]
ReadPrec AlgorithmStatusDetails
Int -> ReadS AlgorithmStatusDetails
ReadS [AlgorithmStatusDetails]
(Int -> ReadS AlgorithmStatusDetails)
-> ReadS [AlgorithmStatusDetails]
-> ReadPrec AlgorithmStatusDetails
-> ReadPrec [AlgorithmStatusDetails]
-> Read AlgorithmStatusDetails
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AlgorithmStatusDetails]
$creadListPrec :: ReadPrec [AlgorithmStatusDetails]
readPrec :: ReadPrec AlgorithmStatusDetails
$creadPrec :: ReadPrec AlgorithmStatusDetails
readList :: ReadS [AlgorithmStatusDetails]
$creadList :: ReadS [AlgorithmStatusDetails]
readsPrec :: Int -> ReadS AlgorithmStatusDetails
$creadsPrec :: Int -> ReadS AlgorithmStatusDetails
Prelude.Read, Int -> AlgorithmStatusDetails -> ShowS
[AlgorithmStatusDetails] -> ShowS
AlgorithmStatusDetails -> String
(Int -> AlgorithmStatusDetails -> ShowS)
-> (AlgorithmStatusDetails -> String)
-> ([AlgorithmStatusDetails] -> ShowS)
-> Show AlgorithmStatusDetails
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AlgorithmStatusDetails] -> ShowS
$cshowList :: [AlgorithmStatusDetails] -> ShowS
show :: AlgorithmStatusDetails -> String
$cshow :: AlgorithmStatusDetails -> String
showsPrec :: Int -> AlgorithmStatusDetails -> ShowS
$cshowsPrec :: Int -> AlgorithmStatusDetails -> ShowS
Prelude.Show, (forall x. AlgorithmStatusDetails -> Rep AlgorithmStatusDetails x)
-> (forall x.
Rep AlgorithmStatusDetails x -> AlgorithmStatusDetails)
-> Generic AlgorithmStatusDetails
forall x. Rep AlgorithmStatusDetails x -> AlgorithmStatusDetails
forall x. AlgorithmStatusDetails -> Rep AlgorithmStatusDetails x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AlgorithmStatusDetails x -> AlgorithmStatusDetails
$cfrom :: forall x. AlgorithmStatusDetails -> Rep AlgorithmStatusDetails x
Prelude.Generic)
newAlgorithmStatusDetails ::
AlgorithmStatusDetails
newAlgorithmStatusDetails :: AlgorithmStatusDetails
newAlgorithmStatusDetails =
AlgorithmStatusDetails' :: Maybe [AlgorithmStatusItem]
-> Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails
AlgorithmStatusDetails'
{ $sel:imageScanStatuses:AlgorithmStatusDetails' :: Maybe [AlgorithmStatusItem]
imageScanStatuses =
Maybe [AlgorithmStatusItem]
forall a. Maybe a
Prelude.Nothing,
$sel:validationStatuses:AlgorithmStatusDetails' :: Maybe [AlgorithmStatusItem]
validationStatuses = Maybe [AlgorithmStatusItem]
forall a. Maybe a
Prelude.Nothing
}
algorithmStatusDetails_imageScanStatuses :: Lens.Lens' AlgorithmStatusDetails (Prelude.Maybe [AlgorithmStatusItem])
algorithmStatusDetails_imageScanStatuses :: (Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails -> f AlgorithmStatusDetails
algorithmStatusDetails_imageScanStatuses = (AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem])
-> (AlgorithmStatusDetails
-> Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails)
-> Lens
AlgorithmStatusDetails
AlgorithmStatusDetails
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AlgorithmStatusDetails' {Maybe [AlgorithmStatusItem]
imageScanStatuses :: Maybe [AlgorithmStatusItem]
$sel:imageScanStatuses:AlgorithmStatusDetails' :: AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem]
imageScanStatuses} -> Maybe [AlgorithmStatusItem]
imageScanStatuses) (\s :: AlgorithmStatusDetails
s@AlgorithmStatusDetails' {} Maybe [AlgorithmStatusItem]
a -> AlgorithmStatusDetails
s {$sel:imageScanStatuses:AlgorithmStatusDetails' :: Maybe [AlgorithmStatusItem]
imageScanStatuses = Maybe [AlgorithmStatusItem]
a} :: AlgorithmStatusDetails) ((Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails -> f AlgorithmStatusDetails)
-> ((Maybe [AlgorithmStatusItem]
-> f (Maybe [AlgorithmStatusItem]))
-> Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> (Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails
-> f AlgorithmStatusDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
-> Iso
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
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
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
algorithmStatusDetails_validationStatuses :: Lens.Lens' AlgorithmStatusDetails (Prelude.Maybe [AlgorithmStatusItem])
algorithmStatusDetails_validationStatuses :: (Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails -> f AlgorithmStatusDetails
algorithmStatusDetails_validationStatuses = (AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem])
-> (AlgorithmStatusDetails
-> Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails)
-> Lens
AlgorithmStatusDetails
AlgorithmStatusDetails
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AlgorithmStatusDetails' {Maybe [AlgorithmStatusItem]
validationStatuses :: Maybe [AlgorithmStatusItem]
$sel:validationStatuses:AlgorithmStatusDetails' :: AlgorithmStatusDetails -> Maybe [AlgorithmStatusItem]
validationStatuses} -> Maybe [AlgorithmStatusItem]
validationStatuses) (\s :: AlgorithmStatusDetails
s@AlgorithmStatusDetails' {} Maybe [AlgorithmStatusItem]
a -> AlgorithmStatusDetails
s {$sel:validationStatuses:AlgorithmStatusDetails' :: Maybe [AlgorithmStatusItem]
validationStatuses = Maybe [AlgorithmStatusItem]
a} :: AlgorithmStatusDetails) ((Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails -> f AlgorithmStatusDetails)
-> ((Maybe [AlgorithmStatusItem]
-> f (Maybe [AlgorithmStatusItem]))
-> Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> (Maybe [AlgorithmStatusItem] -> f (Maybe [AlgorithmStatusItem]))
-> AlgorithmStatusDetails
-> f AlgorithmStatusDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
-> Iso
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
(Maybe [AlgorithmStatusItem])
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
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
[AlgorithmStatusItem]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Core.FromJSON AlgorithmStatusDetails where
parseJSON :: Value -> Parser AlgorithmStatusDetails
parseJSON =
String
-> (Object -> Parser AlgorithmStatusDetails)
-> Value
-> Parser AlgorithmStatusDetails
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AlgorithmStatusDetails"
( \Object
x ->
Maybe [AlgorithmStatusItem]
-> Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails
AlgorithmStatusDetails'
(Maybe [AlgorithmStatusItem]
-> Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails)
-> Parser (Maybe [AlgorithmStatusItem])
-> Parser (Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object -> Text -> Parser (Maybe (Maybe [AlgorithmStatusItem]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ImageScanStatuses"
Parser (Maybe (Maybe [AlgorithmStatusItem]))
-> Maybe [AlgorithmStatusItem]
-> Parser (Maybe [AlgorithmStatusItem])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AlgorithmStatusItem]
forall a. Monoid a => a
Prelude.mempty
)
Parser (Maybe [AlgorithmStatusItem] -> AlgorithmStatusDetails)
-> Parser (Maybe [AlgorithmStatusItem])
-> Parser AlgorithmStatusDetails
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [AlgorithmStatusItem]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ValidationStatuses"
Parser (Maybe (Maybe [AlgorithmStatusItem]))
-> Maybe [AlgorithmStatusItem]
-> Parser (Maybe [AlgorithmStatusItem])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AlgorithmStatusItem]
forall a. Monoid a => a
Prelude.mempty
)
)
instance Prelude.Hashable AlgorithmStatusDetails
instance Prelude.NFData AlgorithmStatusDetails