{-# 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.SageMakerA2IRuntime.Types.HumanLoopSummary 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
import Amazonka.SageMakerA2IRuntime.Types.HumanLoopStatus
data HumanLoopSummary = HumanLoopSummary'
{
HumanLoopSummary -> Maybe ISO8601
creationTime :: Prelude.Maybe Data.ISO8601,
HumanLoopSummary -> Maybe Text
failureReason :: Prelude.Maybe Prelude.Text,
HumanLoopSummary -> Maybe Text
flowDefinitionArn :: Prelude.Maybe Prelude.Text,
HumanLoopSummary -> Maybe Text
humanLoopName :: Prelude.Maybe Prelude.Text,
HumanLoopSummary -> Maybe HumanLoopStatus
humanLoopStatus :: Prelude.Maybe HumanLoopStatus
}
deriving (HumanLoopSummary -> HumanLoopSummary -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: HumanLoopSummary -> HumanLoopSummary -> Bool
$c/= :: HumanLoopSummary -> HumanLoopSummary -> Bool
== :: HumanLoopSummary -> HumanLoopSummary -> Bool
$c== :: HumanLoopSummary -> HumanLoopSummary -> Bool
Prelude.Eq, ReadPrec [HumanLoopSummary]
ReadPrec HumanLoopSummary
Int -> ReadS HumanLoopSummary
ReadS [HumanLoopSummary]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [HumanLoopSummary]
$creadListPrec :: ReadPrec [HumanLoopSummary]
readPrec :: ReadPrec HumanLoopSummary
$creadPrec :: ReadPrec HumanLoopSummary
readList :: ReadS [HumanLoopSummary]
$creadList :: ReadS [HumanLoopSummary]
readsPrec :: Int -> ReadS HumanLoopSummary
$creadsPrec :: Int -> ReadS HumanLoopSummary
Prelude.Read, Int -> HumanLoopSummary -> ShowS
[HumanLoopSummary] -> ShowS
HumanLoopSummary -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [HumanLoopSummary] -> ShowS
$cshowList :: [HumanLoopSummary] -> ShowS
show :: HumanLoopSummary -> String
$cshow :: HumanLoopSummary -> String
showsPrec :: Int -> HumanLoopSummary -> ShowS
$cshowsPrec :: Int -> HumanLoopSummary -> ShowS
Prelude.Show, forall x. Rep HumanLoopSummary x -> HumanLoopSummary
forall x. HumanLoopSummary -> Rep HumanLoopSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep HumanLoopSummary x -> HumanLoopSummary
$cfrom :: forall x. HumanLoopSummary -> Rep HumanLoopSummary x
Prelude.Generic)
newHumanLoopSummary ::
HumanLoopSummary
newHumanLoopSummary :: HumanLoopSummary
newHumanLoopSummary =
HumanLoopSummary'
{ $sel:creationTime:HumanLoopSummary' :: Maybe ISO8601
creationTime = forall a. Maybe a
Prelude.Nothing,
$sel:failureReason:HumanLoopSummary' :: Maybe Text
failureReason = forall a. Maybe a
Prelude.Nothing,
$sel:flowDefinitionArn:HumanLoopSummary' :: Maybe Text
flowDefinitionArn = forall a. Maybe a
Prelude.Nothing,
$sel:humanLoopName:HumanLoopSummary' :: Maybe Text
humanLoopName = forall a. Maybe a
Prelude.Nothing,
$sel:humanLoopStatus:HumanLoopSummary' :: Maybe HumanLoopStatus
humanLoopStatus = forall a. Maybe a
Prelude.Nothing
}
humanLoopSummary_creationTime :: Lens.Lens' HumanLoopSummary (Prelude.Maybe Prelude.UTCTime)
humanLoopSummary_creationTime :: Lens' HumanLoopSummary (Maybe UTCTime)
humanLoopSummary_creationTime = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HumanLoopSummary' {Maybe ISO8601
creationTime :: Maybe ISO8601
$sel:creationTime:HumanLoopSummary' :: HumanLoopSummary -> Maybe ISO8601
creationTime} -> Maybe ISO8601
creationTime) (\s :: HumanLoopSummary
s@HumanLoopSummary' {} Maybe ISO8601
a -> HumanLoopSummary
s {$sel:creationTime:HumanLoopSummary' :: Maybe ISO8601
creationTime = Maybe ISO8601
a} :: HumanLoopSummary) 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
humanLoopSummary_failureReason :: Lens.Lens' HumanLoopSummary (Prelude.Maybe Prelude.Text)
humanLoopSummary_failureReason :: Lens' HumanLoopSummary (Maybe Text)
humanLoopSummary_failureReason = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HumanLoopSummary' {Maybe Text
failureReason :: Maybe Text
$sel:failureReason:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
failureReason} -> Maybe Text
failureReason) (\s :: HumanLoopSummary
s@HumanLoopSummary' {} Maybe Text
a -> HumanLoopSummary
s {$sel:failureReason:HumanLoopSummary' :: Maybe Text
failureReason = Maybe Text
a} :: HumanLoopSummary)
humanLoopSummary_flowDefinitionArn :: Lens.Lens' HumanLoopSummary (Prelude.Maybe Prelude.Text)
humanLoopSummary_flowDefinitionArn :: Lens' HumanLoopSummary (Maybe Text)
humanLoopSummary_flowDefinitionArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HumanLoopSummary' {Maybe Text
flowDefinitionArn :: Maybe Text
$sel:flowDefinitionArn:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
flowDefinitionArn} -> Maybe Text
flowDefinitionArn) (\s :: HumanLoopSummary
s@HumanLoopSummary' {} Maybe Text
a -> HumanLoopSummary
s {$sel:flowDefinitionArn:HumanLoopSummary' :: Maybe Text
flowDefinitionArn = Maybe Text
a} :: HumanLoopSummary)
humanLoopSummary_humanLoopName :: Lens.Lens' HumanLoopSummary (Prelude.Maybe Prelude.Text)
humanLoopSummary_humanLoopName :: Lens' HumanLoopSummary (Maybe Text)
humanLoopSummary_humanLoopName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HumanLoopSummary' {Maybe Text
humanLoopName :: Maybe Text
$sel:humanLoopName:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
humanLoopName} -> Maybe Text
humanLoopName) (\s :: HumanLoopSummary
s@HumanLoopSummary' {} Maybe Text
a -> HumanLoopSummary
s {$sel:humanLoopName:HumanLoopSummary' :: Maybe Text
humanLoopName = Maybe Text
a} :: HumanLoopSummary)
humanLoopSummary_humanLoopStatus :: Lens.Lens' HumanLoopSummary (Prelude.Maybe HumanLoopStatus)
humanLoopSummary_humanLoopStatus :: Lens' HumanLoopSummary (Maybe HumanLoopStatus)
humanLoopSummary_humanLoopStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HumanLoopSummary' {Maybe HumanLoopStatus
humanLoopStatus :: Maybe HumanLoopStatus
$sel:humanLoopStatus:HumanLoopSummary' :: HumanLoopSummary -> Maybe HumanLoopStatus
humanLoopStatus} -> Maybe HumanLoopStatus
humanLoopStatus) (\s :: HumanLoopSummary
s@HumanLoopSummary' {} Maybe HumanLoopStatus
a -> HumanLoopSummary
s {$sel:humanLoopStatus:HumanLoopSummary' :: Maybe HumanLoopStatus
humanLoopStatus = Maybe HumanLoopStatus
a} :: HumanLoopSummary)
instance Data.FromJSON HumanLoopSummary where
parseJSON :: Value -> Parser HumanLoopSummary
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"HumanLoopSummary"
( \Object
x ->
Maybe ISO8601
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe HumanLoopStatus
-> HumanLoopSummary
HumanLoopSummary'
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
"CreationTime")
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
"FailureReason")
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
"FlowDefinitionArn")
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
"HumanLoopName")
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
"HumanLoopStatus")
)
instance Prelude.Hashable HumanLoopSummary where
hashWithSalt :: Int -> HumanLoopSummary -> Int
hashWithSalt Int
_salt HumanLoopSummary' {Maybe Text
Maybe ISO8601
Maybe HumanLoopStatus
humanLoopStatus :: Maybe HumanLoopStatus
humanLoopName :: Maybe Text
flowDefinitionArn :: Maybe Text
failureReason :: Maybe Text
creationTime :: Maybe ISO8601
$sel:humanLoopStatus:HumanLoopSummary' :: HumanLoopSummary -> Maybe HumanLoopStatus
$sel:humanLoopName:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:flowDefinitionArn:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:failureReason:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:creationTime:HumanLoopSummary' :: HumanLoopSummary -> Maybe ISO8601
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ISO8601
creationTime
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
failureReason
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
flowDefinitionArn
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
humanLoopName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe HumanLoopStatus
humanLoopStatus
instance Prelude.NFData HumanLoopSummary where
rnf :: HumanLoopSummary -> ()
rnf HumanLoopSummary' {Maybe Text
Maybe ISO8601
Maybe HumanLoopStatus
humanLoopStatus :: Maybe HumanLoopStatus
humanLoopName :: Maybe Text
flowDefinitionArn :: Maybe Text
failureReason :: Maybe Text
creationTime :: Maybe ISO8601
$sel:humanLoopStatus:HumanLoopSummary' :: HumanLoopSummary -> Maybe HumanLoopStatus
$sel:humanLoopName:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:flowDefinitionArn:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:failureReason:HumanLoopSummary' :: HumanLoopSummary -> Maybe Text
$sel:creationTime:HumanLoopSummary' :: HumanLoopSummary -> Maybe ISO8601
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe ISO8601
creationTime
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
failureReason
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
flowDefinitionArn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
humanLoopName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe HumanLoopStatus
humanLoopStatus