{-# 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.CompilationJobSummary
-- 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.CompilationJobSummary where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SageMaker.Types.CompilationJobStatus
import Amazonka.SageMaker.Types.TargetDevice
import Amazonka.SageMaker.Types.TargetPlatformAccelerator
import Amazonka.SageMaker.Types.TargetPlatformArch
import Amazonka.SageMaker.Types.TargetPlatformOs

-- | A summary of a model compilation job.
--
-- /See:/ 'newCompilationJobSummary' smart constructor.
data CompilationJobSummary = CompilationJobSummary'
  { -- | The time when the model compilation job started.
    CompilationJobSummary -> Maybe POSIX
compilationStartTime :: Prelude.Maybe Core.POSIX,
    -- | The type of accelerator that the model will run on after the compilation
    -- job has completed.
    CompilationJobSummary -> Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator :: Prelude.Maybe TargetPlatformAccelerator,
    -- | The type of device that the model will run on after the compilation job
    -- has completed.
    CompilationJobSummary -> Maybe TargetDevice
compilationTargetDevice :: Prelude.Maybe TargetDevice,
    -- | The time when the model compilation job was last modified.
    CompilationJobSummary -> Maybe POSIX
lastModifiedTime :: Prelude.Maybe Core.POSIX,
    -- | The type of architecture that the model will run on after the
    -- compilation job has completed.
    CompilationJobSummary -> Maybe TargetPlatformArch
compilationTargetPlatformArch :: Prelude.Maybe TargetPlatformArch,
    -- | The time when the model compilation job completed.
    CompilationJobSummary -> Maybe POSIX
compilationEndTime :: Prelude.Maybe Core.POSIX,
    -- | The type of OS that the model will run on after the compilation job has
    -- completed.
    CompilationJobSummary -> Maybe TargetPlatformOs
compilationTargetPlatformOs :: Prelude.Maybe TargetPlatformOs,
    -- | The name of the model compilation job that you want a summary for.
    CompilationJobSummary -> Text
compilationJobName :: Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the model compilation job.
    CompilationJobSummary -> Text
compilationJobArn :: Prelude.Text,
    -- | The time when the model compilation job was created.
    CompilationJobSummary -> POSIX
creationTime :: Core.POSIX,
    -- | The status of the model compilation job.
    CompilationJobSummary -> CompilationJobStatus
compilationJobStatus :: CompilationJobStatus
  }
  deriving (CompilationJobSummary -> CompilationJobSummary -> Bool
(CompilationJobSummary -> CompilationJobSummary -> Bool)
-> (CompilationJobSummary -> CompilationJobSummary -> Bool)
-> Eq CompilationJobSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CompilationJobSummary -> CompilationJobSummary -> Bool
$c/= :: CompilationJobSummary -> CompilationJobSummary -> Bool
== :: CompilationJobSummary -> CompilationJobSummary -> Bool
$c== :: CompilationJobSummary -> CompilationJobSummary -> Bool
Prelude.Eq, ReadPrec [CompilationJobSummary]
ReadPrec CompilationJobSummary
Int -> ReadS CompilationJobSummary
ReadS [CompilationJobSummary]
(Int -> ReadS CompilationJobSummary)
-> ReadS [CompilationJobSummary]
-> ReadPrec CompilationJobSummary
-> ReadPrec [CompilationJobSummary]
-> Read CompilationJobSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CompilationJobSummary]
$creadListPrec :: ReadPrec [CompilationJobSummary]
readPrec :: ReadPrec CompilationJobSummary
$creadPrec :: ReadPrec CompilationJobSummary
readList :: ReadS [CompilationJobSummary]
$creadList :: ReadS [CompilationJobSummary]
readsPrec :: Int -> ReadS CompilationJobSummary
$creadsPrec :: Int -> ReadS CompilationJobSummary
Prelude.Read, Int -> CompilationJobSummary -> ShowS
[CompilationJobSummary] -> ShowS
CompilationJobSummary -> String
(Int -> CompilationJobSummary -> ShowS)
-> (CompilationJobSummary -> String)
-> ([CompilationJobSummary] -> ShowS)
-> Show CompilationJobSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CompilationJobSummary] -> ShowS
$cshowList :: [CompilationJobSummary] -> ShowS
show :: CompilationJobSummary -> String
$cshow :: CompilationJobSummary -> String
showsPrec :: Int -> CompilationJobSummary -> ShowS
$cshowsPrec :: Int -> CompilationJobSummary -> ShowS
Prelude.Show, (forall x. CompilationJobSummary -> Rep CompilationJobSummary x)
-> (forall x. Rep CompilationJobSummary x -> CompilationJobSummary)
-> Generic CompilationJobSummary
forall x. Rep CompilationJobSummary x -> CompilationJobSummary
forall x. CompilationJobSummary -> Rep CompilationJobSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CompilationJobSummary x -> CompilationJobSummary
$cfrom :: forall x. CompilationJobSummary -> Rep CompilationJobSummary x
Prelude.Generic)

-- |
-- Create a value of 'CompilationJobSummary' 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:
--
-- 'compilationStartTime', 'compilationJobSummary_compilationStartTime' - The time when the model compilation job started.
--
-- 'compilationTargetPlatformAccelerator', 'compilationJobSummary_compilationTargetPlatformAccelerator' - The type of accelerator that the model will run on after the compilation
-- job has completed.
--
-- 'compilationTargetDevice', 'compilationJobSummary_compilationTargetDevice' - The type of device that the model will run on after the compilation job
-- has completed.
--
-- 'lastModifiedTime', 'compilationJobSummary_lastModifiedTime' - The time when the model compilation job was last modified.
--
-- 'compilationTargetPlatformArch', 'compilationJobSummary_compilationTargetPlatformArch' - The type of architecture that the model will run on after the
-- compilation job has completed.
--
-- 'compilationEndTime', 'compilationJobSummary_compilationEndTime' - The time when the model compilation job completed.
--
-- 'compilationTargetPlatformOs', 'compilationJobSummary_compilationTargetPlatformOs' - The type of OS that the model will run on after the compilation job has
-- completed.
--
-- 'compilationJobName', 'compilationJobSummary_compilationJobName' - The name of the model compilation job that you want a summary for.
--
-- 'compilationJobArn', 'compilationJobSummary_compilationJobArn' - The Amazon Resource Name (ARN) of the model compilation job.
--
-- 'creationTime', 'compilationJobSummary_creationTime' - The time when the model compilation job was created.
--
-- 'compilationJobStatus', 'compilationJobSummary_compilationJobStatus' - The status of the model compilation job.
newCompilationJobSummary ::
  -- | 'compilationJobName'
  Prelude.Text ->
  -- | 'compilationJobArn'
  Prelude.Text ->
  -- | 'creationTime'
  Prelude.UTCTime ->
  -- | 'compilationJobStatus'
  CompilationJobStatus ->
  CompilationJobSummary
newCompilationJobSummary :: Text
-> Text -> UTCTime -> CompilationJobStatus -> CompilationJobSummary
newCompilationJobSummary
  Text
pCompilationJobName_
  Text
pCompilationJobArn_
  UTCTime
pCreationTime_
  CompilationJobStatus
pCompilationJobStatus_ =
    CompilationJobSummary' :: Maybe POSIX
-> Maybe TargetPlatformAccelerator
-> Maybe TargetDevice
-> Maybe POSIX
-> Maybe TargetPlatformArch
-> Maybe POSIX
-> Maybe TargetPlatformOs
-> Text
-> Text
-> POSIX
-> CompilationJobStatus
-> CompilationJobSummary
CompilationJobSummary'
      { $sel:compilationStartTime:CompilationJobSummary' :: Maybe POSIX
compilationStartTime =
          Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationTargetPlatformAccelerator:CompilationJobSummary' :: Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator =
          Maybe TargetPlatformAccelerator
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationTargetDevice:CompilationJobSummary' :: Maybe TargetDevice
compilationTargetDevice = Maybe TargetDevice
forall a. Maybe a
Prelude.Nothing,
        $sel:lastModifiedTime:CompilationJobSummary' :: Maybe POSIX
lastModifiedTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationTargetPlatformArch:CompilationJobSummary' :: Maybe TargetPlatformArch
compilationTargetPlatformArch = Maybe TargetPlatformArch
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationEndTime:CompilationJobSummary' :: Maybe POSIX
compilationEndTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationTargetPlatformOs:CompilationJobSummary' :: Maybe TargetPlatformOs
compilationTargetPlatformOs = Maybe TargetPlatformOs
forall a. Maybe a
Prelude.Nothing,
        $sel:compilationJobName:CompilationJobSummary' :: Text
compilationJobName = Text
pCompilationJobName_,
        $sel:compilationJobArn:CompilationJobSummary' :: Text
compilationJobArn = Text
pCompilationJobArn_,
        $sel:creationTime:CompilationJobSummary' :: POSIX
creationTime = Tagged UTCTime (Identity UTCTime) -> Tagged POSIX (Identity POSIX)
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time (Tagged UTCTime (Identity UTCTime)
 -> Tagged POSIX (Identity POSIX))
-> UTCTime -> POSIX
forall t b. AReview t b -> b -> t
Lens.# UTCTime
pCreationTime_,
        $sel:compilationJobStatus:CompilationJobSummary' :: CompilationJobStatus
compilationJobStatus = CompilationJobStatus
pCompilationJobStatus_
      }

-- | The time when the model compilation job started.
compilationJobSummary_compilationStartTime :: Lens.Lens' CompilationJobSummary (Prelude.Maybe Prelude.UTCTime)
compilationJobSummary_compilationStartTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationStartTime = (CompilationJobSummary -> Maybe POSIX)
-> (CompilationJobSummary -> Maybe POSIX -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe POSIX
compilationStartTime :: Maybe POSIX
$sel:compilationStartTime:CompilationJobSummary' :: CompilationJobSummary -> Maybe POSIX
compilationStartTime} -> Maybe POSIX
compilationStartTime) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe POSIX
a -> CompilationJobSummary
s {$sel:compilationStartTime:CompilationJobSummary' :: Maybe POSIX
compilationStartTime = Maybe POSIX
a} :: CompilationJobSummary) ((Maybe POSIX -> f (Maybe POSIX))
 -> CompilationJobSummary -> f CompilationJobSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary
-> f CompilationJobSummary
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

-- | The type of accelerator that the model will run on after the compilation
-- job has completed.
compilationJobSummary_compilationTargetPlatformAccelerator :: Lens.Lens' CompilationJobSummary (Prelude.Maybe TargetPlatformAccelerator)
compilationJobSummary_compilationTargetPlatformAccelerator :: (Maybe TargetPlatformAccelerator
 -> f (Maybe TargetPlatformAccelerator))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationTargetPlatformAccelerator = (CompilationJobSummary -> Maybe TargetPlatformAccelerator)
-> (CompilationJobSummary
    -> Maybe TargetPlatformAccelerator -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe TargetPlatformAccelerator)
     (Maybe TargetPlatformAccelerator)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator :: Maybe TargetPlatformAccelerator
$sel:compilationTargetPlatformAccelerator:CompilationJobSummary' :: CompilationJobSummary -> Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator} -> Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe TargetPlatformAccelerator
a -> CompilationJobSummary
s {$sel:compilationTargetPlatformAccelerator:CompilationJobSummary' :: Maybe TargetPlatformAccelerator
compilationTargetPlatformAccelerator = Maybe TargetPlatformAccelerator
a} :: CompilationJobSummary)

-- | The type of device that the model will run on after the compilation job
-- has completed.
compilationJobSummary_compilationTargetDevice :: Lens.Lens' CompilationJobSummary (Prelude.Maybe TargetDevice)
compilationJobSummary_compilationTargetDevice :: (Maybe TargetDevice -> f (Maybe TargetDevice))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationTargetDevice = (CompilationJobSummary -> Maybe TargetDevice)
-> (CompilationJobSummary
    -> Maybe TargetDevice -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe TargetDevice)
     (Maybe TargetDevice)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe TargetDevice
compilationTargetDevice :: Maybe TargetDevice
$sel:compilationTargetDevice:CompilationJobSummary' :: CompilationJobSummary -> Maybe TargetDevice
compilationTargetDevice} -> Maybe TargetDevice
compilationTargetDevice) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe TargetDevice
a -> CompilationJobSummary
s {$sel:compilationTargetDevice:CompilationJobSummary' :: Maybe TargetDevice
compilationTargetDevice = Maybe TargetDevice
a} :: CompilationJobSummary)

-- | The time when the model compilation job was last modified.
compilationJobSummary_lastModifiedTime :: Lens.Lens' CompilationJobSummary (Prelude.Maybe Prelude.UTCTime)
compilationJobSummary_lastModifiedTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_lastModifiedTime = (CompilationJobSummary -> Maybe POSIX)
-> (CompilationJobSummary -> Maybe POSIX -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe POSIX
lastModifiedTime :: Maybe POSIX
$sel:lastModifiedTime:CompilationJobSummary' :: CompilationJobSummary -> Maybe POSIX
lastModifiedTime} -> Maybe POSIX
lastModifiedTime) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe POSIX
a -> CompilationJobSummary
s {$sel:lastModifiedTime:CompilationJobSummary' :: Maybe POSIX
lastModifiedTime = Maybe POSIX
a} :: CompilationJobSummary) ((Maybe POSIX -> f (Maybe POSIX))
 -> CompilationJobSummary -> f CompilationJobSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary
-> f CompilationJobSummary
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

-- | The type of architecture that the model will run on after the
-- compilation job has completed.
compilationJobSummary_compilationTargetPlatformArch :: Lens.Lens' CompilationJobSummary (Prelude.Maybe TargetPlatformArch)
compilationJobSummary_compilationTargetPlatformArch :: (Maybe TargetPlatformArch -> f (Maybe TargetPlatformArch))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationTargetPlatformArch = (CompilationJobSummary -> Maybe TargetPlatformArch)
-> (CompilationJobSummary
    -> Maybe TargetPlatformArch -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe TargetPlatformArch)
     (Maybe TargetPlatformArch)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe TargetPlatformArch
compilationTargetPlatformArch :: Maybe TargetPlatformArch
$sel:compilationTargetPlatformArch:CompilationJobSummary' :: CompilationJobSummary -> Maybe TargetPlatformArch
compilationTargetPlatformArch} -> Maybe TargetPlatformArch
compilationTargetPlatformArch) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe TargetPlatformArch
a -> CompilationJobSummary
s {$sel:compilationTargetPlatformArch:CompilationJobSummary' :: Maybe TargetPlatformArch
compilationTargetPlatformArch = Maybe TargetPlatformArch
a} :: CompilationJobSummary)

-- | The time when the model compilation job completed.
compilationJobSummary_compilationEndTime :: Lens.Lens' CompilationJobSummary (Prelude.Maybe Prelude.UTCTime)
compilationJobSummary_compilationEndTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationEndTime = (CompilationJobSummary -> Maybe POSIX)
-> (CompilationJobSummary -> Maybe POSIX -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe POSIX
compilationEndTime :: Maybe POSIX
$sel:compilationEndTime:CompilationJobSummary' :: CompilationJobSummary -> Maybe POSIX
compilationEndTime} -> Maybe POSIX
compilationEndTime) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe POSIX
a -> CompilationJobSummary
s {$sel:compilationEndTime:CompilationJobSummary' :: Maybe POSIX
compilationEndTime = Maybe POSIX
a} :: CompilationJobSummary) ((Maybe POSIX -> f (Maybe POSIX))
 -> CompilationJobSummary -> f CompilationJobSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> CompilationJobSummary
-> f CompilationJobSummary
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

-- | The type of OS that the model will run on after the compilation job has
-- completed.
compilationJobSummary_compilationTargetPlatformOs :: Lens.Lens' CompilationJobSummary (Prelude.Maybe TargetPlatformOs)
compilationJobSummary_compilationTargetPlatformOs :: (Maybe TargetPlatformOs -> f (Maybe TargetPlatformOs))
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationTargetPlatformOs = (CompilationJobSummary -> Maybe TargetPlatformOs)
-> (CompilationJobSummary
    -> Maybe TargetPlatformOs -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     (Maybe TargetPlatformOs)
     (Maybe TargetPlatformOs)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Maybe TargetPlatformOs
compilationTargetPlatformOs :: Maybe TargetPlatformOs
$sel:compilationTargetPlatformOs:CompilationJobSummary' :: CompilationJobSummary -> Maybe TargetPlatformOs
compilationTargetPlatformOs} -> Maybe TargetPlatformOs
compilationTargetPlatformOs) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Maybe TargetPlatformOs
a -> CompilationJobSummary
s {$sel:compilationTargetPlatformOs:CompilationJobSummary' :: Maybe TargetPlatformOs
compilationTargetPlatformOs = Maybe TargetPlatformOs
a} :: CompilationJobSummary)

-- | The name of the model compilation job that you want a summary for.
compilationJobSummary_compilationJobName :: Lens.Lens' CompilationJobSummary Prelude.Text
compilationJobSummary_compilationJobName :: (Text -> f Text)
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationJobName = (CompilationJobSummary -> Text)
-> (CompilationJobSummary -> Text -> CompilationJobSummary)
-> Lens CompilationJobSummary CompilationJobSummary Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Text
compilationJobName :: Text
$sel:compilationJobName:CompilationJobSummary' :: CompilationJobSummary -> Text
compilationJobName} -> Text
compilationJobName) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Text
a -> CompilationJobSummary
s {$sel:compilationJobName:CompilationJobSummary' :: Text
compilationJobName = Text
a} :: CompilationJobSummary)

-- | The Amazon Resource Name (ARN) of the model compilation job.
compilationJobSummary_compilationJobArn :: Lens.Lens' CompilationJobSummary Prelude.Text
compilationJobSummary_compilationJobArn :: (Text -> f Text)
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationJobArn = (CompilationJobSummary -> Text)
-> (CompilationJobSummary -> Text -> CompilationJobSummary)
-> Lens CompilationJobSummary CompilationJobSummary Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {Text
compilationJobArn :: Text
$sel:compilationJobArn:CompilationJobSummary' :: CompilationJobSummary -> Text
compilationJobArn} -> Text
compilationJobArn) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} Text
a -> CompilationJobSummary
s {$sel:compilationJobArn:CompilationJobSummary' :: Text
compilationJobArn = Text
a} :: CompilationJobSummary)

-- | The time when the model compilation job was created.
compilationJobSummary_creationTime :: Lens.Lens' CompilationJobSummary Prelude.UTCTime
compilationJobSummary_creationTime :: (UTCTime -> f UTCTime)
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_creationTime = (CompilationJobSummary -> POSIX)
-> (CompilationJobSummary -> POSIX -> CompilationJobSummary)
-> Lens CompilationJobSummary CompilationJobSummary POSIX POSIX
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {POSIX
creationTime :: POSIX
$sel:creationTime:CompilationJobSummary' :: CompilationJobSummary -> POSIX
creationTime} -> POSIX
creationTime) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} POSIX
a -> CompilationJobSummary
s {$sel:creationTime:CompilationJobSummary' :: POSIX
creationTime = POSIX
a} :: CompilationJobSummary) ((POSIX -> f POSIX)
 -> CompilationJobSummary -> f CompilationJobSummary)
-> ((UTCTime -> f UTCTime) -> POSIX -> f POSIX)
-> (UTCTime -> f UTCTime)
-> CompilationJobSummary
-> f CompilationJobSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (UTCTime -> f UTCTime) -> POSIX -> f POSIX
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The status of the model compilation job.
compilationJobSummary_compilationJobStatus :: Lens.Lens' CompilationJobSummary CompilationJobStatus
compilationJobSummary_compilationJobStatus :: (CompilationJobStatus -> f CompilationJobStatus)
-> CompilationJobSummary -> f CompilationJobSummary
compilationJobSummary_compilationJobStatus = (CompilationJobSummary -> CompilationJobStatus)
-> (CompilationJobSummary
    -> CompilationJobStatus -> CompilationJobSummary)
-> Lens
     CompilationJobSummary
     CompilationJobSummary
     CompilationJobStatus
     CompilationJobStatus
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CompilationJobSummary' {CompilationJobStatus
compilationJobStatus :: CompilationJobStatus
$sel:compilationJobStatus:CompilationJobSummary' :: CompilationJobSummary -> CompilationJobStatus
compilationJobStatus} -> CompilationJobStatus
compilationJobStatus) (\s :: CompilationJobSummary
s@CompilationJobSummary' {} CompilationJobStatus
a -> CompilationJobSummary
s {$sel:compilationJobStatus:CompilationJobSummary' :: CompilationJobStatus
compilationJobStatus = CompilationJobStatus
a} :: CompilationJobSummary)

instance Core.FromJSON CompilationJobSummary where
  parseJSON :: Value -> Parser CompilationJobSummary
parseJSON =
    String
-> (Object -> Parser CompilationJobSummary)
-> Value
-> Parser CompilationJobSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"CompilationJobSummary"
      ( \Object
x ->
          Maybe POSIX
-> Maybe TargetPlatformAccelerator
-> Maybe TargetDevice
-> Maybe POSIX
-> Maybe TargetPlatformArch
-> Maybe POSIX
-> Maybe TargetPlatformOs
-> Text
-> Text
-> POSIX
-> CompilationJobStatus
-> CompilationJobSummary
CompilationJobSummary'
            (Maybe POSIX
 -> Maybe TargetPlatformAccelerator
 -> Maybe TargetDevice
 -> Maybe POSIX
 -> Maybe TargetPlatformArch
 -> Maybe POSIX
 -> Maybe TargetPlatformOs
 -> Text
 -> Text
 -> POSIX
 -> CompilationJobStatus
 -> CompilationJobSummary)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe TargetPlatformAccelerator
      -> Maybe TargetDevice
      -> Maybe POSIX
      -> Maybe TargetPlatformArch
      -> Maybe POSIX
      -> Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
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
"CompilationStartTime")
            Parser
  (Maybe TargetPlatformAccelerator
   -> Maybe TargetDevice
   -> Maybe POSIX
   -> Maybe TargetPlatformArch
   -> Maybe POSIX
   -> Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe TargetPlatformAccelerator)
-> Parser
     (Maybe TargetDevice
      -> Maybe POSIX
      -> Maybe TargetPlatformArch
      -> Maybe POSIX
      -> Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe TargetPlatformAccelerator)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompilationTargetPlatformAccelerator")
            Parser
  (Maybe TargetDevice
   -> Maybe POSIX
   -> Maybe TargetPlatformArch
   -> Maybe POSIX
   -> Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe TargetDevice)
-> Parser
     (Maybe POSIX
      -> Maybe TargetPlatformArch
      -> Maybe POSIX
      -> Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe TargetDevice)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompilationTargetDevice")
            Parser
  (Maybe POSIX
   -> Maybe TargetPlatformArch
   -> Maybe POSIX
   -> Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe TargetPlatformArch
      -> Maybe POSIX
      -> Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => 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
"LastModifiedTime")
            Parser
  (Maybe TargetPlatformArch
   -> Maybe POSIX
   -> Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe TargetPlatformArch)
-> Parser
     (Maybe POSIX
      -> Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe TargetPlatformArch)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompilationTargetPlatformArch")
            Parser
  (Maybe POSIX
   -> Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe TargetPlatformOs
      -> Text
      -> Text
      -> POSIX
      -> CompilationJobStatus
      -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => 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
"CompilationEndTime")
            Parser
  (Maybe TargetPlatformOs
   -> Text
   -> Text
   -> POSIX
   -> CompilationJobStatus
   -> CompilationJobSummary)
-> Parser (Maybe TargetPlatformOs)
-> Parser
     (Text
      -> Text -> POSIX -> CompilationJobStatus -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe TargetPlatformOs)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CompilationTargetPlatformOs")
            Parser
  (Text
   -> Text -> POSIX -> CompilationJobStatus -> CompilationJobSummary)
-> Parser Text
-> Parser
     (Text -> POSIX -> CompilationJobStatus -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CompilationJobName")
            Parser
  (Text -> POSIX -> CompilationJobStatus -> CompilationJobSummary)
-> Parser Text
-> Parser (POSIX -> CompilationJobStatus -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CompilationJobArn")
            Parser (POSIX -> CompilationJobStatus -> CompilationJobSummary)
-> Parser POSIX
-> Parser (CompilationJobStatus -> CompilationJobSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser POSIX
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CreationTime")
            Parser (CompilationJobStatus -> CompilationJobSummary)
-> Parser CompilationJobStatus -> Parser CompilationJobSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser CompilationJobStatus
forall a. FromJSON a => Object -> Text -> Parser a
Core..: Text
"CompilationJobStatus")
      )

instance Prelude.Hashable CompilationJobSummary

instance Prelude.NFData CompilationJobSummary