{-# 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.AssociationSummary where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SageMaker.Types.AssociationEdgeType
import Amazonka.SageMaker.Types.UserContext
data AssociationSummary = AssociationSummary'
{
AssociationSummary -> Maybe POSIX
creationTime :: Prelude.Maybe Core.POSIX,
AssociationSummary -> Maybe Text
sourceName :: Prelude.Maybe Prelude.Text,
AssociationSummary -> Maybe Text
sourceType :: Prelude.Maybe Prelude.Text,
AssociationSummary -> Maybe Text
sourceArn :: Prelude.Maybe Prelude.Text,
AssociationSummary -> Maybe UserContext
createdBy :: Prelude.Maybe UserContext,
AssociationSummary -> Maybe AssociationEdgeType
associationType :: Prelude.Maybe AssociationEdgeType,
AssociationSummary -> Maybe Text
destinationArn :: Prelude.Maybe Prelude.Text,
AssociationSummary -> Maybe Text
destinationType :: Prelude.Maybe Prelude.Text,
AssociationSummary -> Maybe Text
destinationName :: Prelude.Maybe Prelude.Text
}
deriving (AssociationSummary -> AssociationSummary -> Bool
(AssociationSummary -> AssociationSummary -> Bool)
-> (AssociationSummary -> AssociationSummary -> Bool)
-> Eq AssociationSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AssociationSummary -> AssociationSummary -> Bool
$c/= :: AssociationSummary -> AssociationSummary -> Bool
== :: AssociationSummary -> AssociationSummary -> Bool
$c== :: AssociationSummary -> AssociationSummary -> Bool
Prelude.Eq, ReadPrec [AssociationSummary]
ReadPrec AssociationSummary
Int -> ReadS AssociationSummary
ReadS [AssociationSummary]
(Int -> ReadS AssociationSummary)
-> ReadS [AssociationSummary]
-> ReadPrec AssociationSummary
-> ReadPrec [AssociationSummary]
-> Read AssociationSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AssociationSummary]
$creadListPrec :: ReadPrec [AssociationSummary]
readPrec :: ReadPrec AssociationSummary
$creadPrec :: ReadPrec AssociationSummary
readList :: ReadS [AssociationSummary]
$creadList :: ReadS [AssociationSummary]
readsPrec :: Int -> ReadS AssociationSummary
$creadsPrec :: Int -> ReadS AssociationSummary
Prelude.Read, Int -> AssociationSummary -> ShowS
[AssociationSummary] -> ShowS
AssociationSummary -> String
(Int -> AssociationSummary -> ShowS)
-> (AssociationSummary -> String)
-> ([AssociationSummary] -> ShowS)
-> Show AssociationSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AssociationSummary] -> ShowS
$cshowList :: [AssociationSummary] -> ShowS
show :: AssociationSummary -> String
$cshow :: AssociationSummary -> String
showsPrec :: Int -> AssociationSummary -> ShowS
$cshowsPrec :: Int -> AssociationSummary -> ShowS
Prelude.Show, (forall x. AssociationSummary -> Rep AssociationSummary x)
-> (forall x. Rep AssociationSummary x -> AssociationSummary)
-> Generic AssociationSummary
forall x. Rep AssociationSummary x -> AssociationSummary
forall x. AssociationSummary -> Rep AssociationSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AssociationSummary x -> AssociationSummary
$cfrom :: forall x. AssociationSummary -> Rep AssociationSummary x
Prelude.Generic)
newAssociationSummary ::
AssociationSummary
newAssociationSummary :: AssociationSummary
newAssociationSummary =
AssociationSummary' :: Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary
AssociationSummary'
{ $sel:creationTime:AssociationSummary' :: Maybe POSIX
creationTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:sourceName:AssociationSummary' :: Maybe Text
sourceName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sourceType:AssociationSummary' :: Maybe Text
sourceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sourceArn:AssociationSummary' :: Maybe Text
sourceArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:createdBy:AssociationSummary' :: Maybe UserContext
createdBy = Maybe UserContext
forall a. Maybe a
Prelude.Nothing,
$sel:associationType:AssociationSummary' :: Maybe AssociationEdgeType
associationType = Maybe AssociationEdgeType
forall a. Maybe a
Prelude.Nothing,
$sel:destinationArn:AssociationSummary' :: Maybe Text
destinationArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:destinationType:AssociationSummary' :: Maybe Text
destinationType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:destinationName:AssociationSummary' :: Maybe Text
destinationName = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
associationSummary_creationTime :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.UTCTime)
associationSummary_creationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> AssociationSummary -> f AssociationSummary
associationSummary_creationTime = (AssociationSummary -> Maybe POSIX)
-> (AssociationSummary -> Maybe POSIX -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe POSIX
creationTime :: Maybe POSIX
$sel:creationTime:AssociationSummary' :: AssociationSummary -> Maybe POSIX
creationTime} -> Maybe POSIX
creationTime) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe POSIX
a -> AssociationSummary
s {$sel:creationTime:AssociationSummary' :: Maybe POSIX
creationTime = Maybe POSIX
a} :: AssociationSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> AssociationSummary -> f AssociationSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> AssociationSummary
-> f AssociationSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
associationSummary_sourceName :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_sourceName :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_sourceName = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
sourceName :: Maybe Text
$sel:sourceName:AssociationSummary' :: AssociationSummary -> Maybe Text
sourceName} -> Maybe Text
sourceName) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:sourceName:AssociationSummary' :: Maybe Text
sourceName = Maybe Text
a} :: AssociationSummary)
associationSummary_sourceType :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_sourceType :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_sourceType = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
sourceType :: Maybe Text
$sel:sourceType:AssociationSummary' :: AssociationSummary -> Maybe Text
sourceType} -> Maybe Text
sourceType) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:sourceType:AssociationSummary' :: Maybe Text
sourceType = Maybe Text
a} :: AssociationSummary)
associationSummary_sourceArn :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_sourceArn :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_sourceArn = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
sourceArn :: Maybe Text
$sel:sourceArn:AssociationSummary' :: AssociationSummary -> Maybe Text
sourceArn} -> Maybe Text
sourceArn) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:sourceArn:AssociationSummary' :: Maybe Text
sourceArn = Maybe Text
a} :: AssociationSummary)
associationSummary_createdBy :: Lens.Lens' AssociationSummary (Prelude.Maybe UserContext)
associationSummary_createdBy :: (Maybe UserContext -> f (Maybe UserContext))
-> AssociationSummary -> f AssociationSummary
associationSummary_createdBy = (AssociationSummary -> Maybe UserContext)
-> (AssociationSummary -> Maybe UserContext -> AssociationSummary)
-> Lens
AssociationSummary
AssociationSummary
(Maybe UserContext)
(Maybe UserContext)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe UserContext
createdBy :: Maybe UserContext
$sel:createdBy:AssociationSummary' :: AssociationSummary -> Maybe UserContext
createdBy} -> Maybe UserContext
createdBy) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe UserContext
a -> AssociationSummary
s {$sel:createdBy:AssociationSummary' :: Maybe UserContext
createdBy = Maybe UserContext
a} :: AssociationSummary)
associationSummary_associationType :: Lens.Lens' AssociationSummary (Prelude.Maybe AssociationEdgeType)
associationSummary_associationType :: (Maybe AssociationEdgeType -> f (Maybe AssociationEdgeType))
-> AssociationSummary -> f AssociationSummary
associationSummary_associationType = (AssociationSummary -> Maybe AssociationEdgeType)
-> (AssociationSummary
-> Maybe AssociationEdgeType -> AssociationSummary)
-> Lens
AssociationSummary
AssociationSummary
(Maybe AssociationEdgeType)
(Maybe AssociationEdgeType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe AssociationEdgeType
associationType :: Maybe AssociationEdgeType
$sel:associationType:AssociationSummary' :: AssociationSummary -> Maybe AssociationEdgeType
associationType} -> Maybe AssociationEdgeType
associationType) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe AssociationEdgeType
a -> AssociationSummary
s {$sel:associationType:AssociationSummary' :: Maybe AssociationEdgeType
associationType = Maybe AssociationEdgeType
a} :: AssociationSummary)
associationSummary_destinationArn :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_destinationArn :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_destinationArn = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
destinationArn :: Maybe Text
$sel:destinationArn:AssociationSummary' :: AssociationSummary -> Maybe Text
destinationArn} -> Maybe Text
destinationArn) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:destinationArn:AssociationSummary' :: Maybe Text
destinationArn = Maybe Text
a} :: AssociationSummary)
associationSummary_destinationType :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_destinationType :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_destinationType = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
destinationType :: Maybe Text
$sel:destinationType:AssociationSummary' :: AssociationSummary -> Maybe Text
destinationType} -> Maybe Text
destinationType) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:destinationType:AssociationSummary' :: Maybe Text
destinationType = Maybe Text
a} :: AssociationSummary)
associationSummary_destinationName :: Lens.Lens' AssociationSummary (Prelude.Maybe Prelude.Text)
associationSummary_destinationName :: (Maybe Text -> f (Maybe Text))
-> AssociationSummary -> f AssociationSummary
associationSummary_destinationName = (AssociationSummary -> Maybe Text)
-> (AssociationSummary -> Maybe Text -> AssociationSummary)
-> Lens
AssociationSummary AssociationSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AssociationSummary' {Maybe Text
destinationName :: Maybe Text
$sel:destinationName:AssociationSummary' :: AssociationSummary -> Maybe Text
destinationName} -> Maybe Text
destinationName) (\s :: AssociationSummary
s@AssociationSummary' {} Maybe Text
a -> AssociationSummary
s {$sel:destinationName:AssociationSummary' :: Maybe Text
destinationName = Maybe Text
a} :: AssociationSummary)
instance Core.FromJSON AssociationSummary where
parseJSON :: Value -> Parser AssociationSummary
parseJSON =
String
-> (Object -> Parser AssociationSummary)
-> Value
-> Parser AssociationSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AssociationSummary"
( \Object
x ->
Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary
AssociationSummary'
(Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CreationTime")
Parser
(Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
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
"SourceName")
Parser
(Maybe Text
-> Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
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
"SourceType")
Parser
(Maybe Text
-> Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
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
"SourceArn")
Parser
(Maybe UserContext
-> Maybe AssociationEdgeType
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> AssociationSummary)
-> Parser (Maybe UserContext)
-> Parser
(Maybe AssociationEdgeType
-> Maybe Text -> Maybe Text -> Maybe Text -> AssociationSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe UserContext)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CreatedBy")
Parser
(Maybe AssociationEdgeType
-> Maybe Text -> Maybe Text -> Maybe Text -> AssociationSummary)
-> Parser (Maybe AssociationEdgeType)
-> Parser
(Maybe Text -> Maybe Text -> Maybe Text -> AssociationSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe AssociationEdgeType)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AssociationType")
Parser
(Maybe Text -> Maybe Text -> Maybe Text -> AssociationSummary)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> AssociationSummary)
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
"DestinationArn")
Parser (Maybe Text -> Maybe Text -> AssociationSummary)
-> Parser (Maybe Text) -> Parser (Maybe Text -> AssociationSummary)
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
"DestinationType")
Parser (Maybe Text -> AssociationSummary)
-> Parser (Maybe Text) -> Parser AssociationSummary
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
"DestinationName")
)
instance Prelude.Hashable AssociationSummary
instance Prelude.NFData AssociationSummary