{-# 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.Backup.Types.RestoreJobsListMember
-- 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.Backup.Types.RestoreJobsListMember where

import Amazonka.Backup.Types.RestoreJobStatus
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Contains metadata about a restore job.
--
-- /See:/ 'newRestoreJobsListMember' smart constructor.
data RestoreJobsListMember = RestoreJobsListMember'
  { -- | A status code specifying the state of the job initiated by Backup to
    -- restore a recovery point.
    RestoreJobsListMember -> Maybe RestoreJobStatus
status :: Prelude.Maybe RestoreJobStatus,
    -- | Specifies the IAM role ARN used to create the target recovery point; for
    -- example, @arn:aws:iam::123456789012:role\/S3Access@.
    RestoreJobsListMember -> Maybe Text
iamRoleArn :: Prelude.Maybe Prelude.Text,
    -- | The amount of time in minutes that a job restoring a recovery point is
    -- expected to take.
    RestoreJobsListMember -> Maybe Integer
expectedCompletionTimeMinutes :: Prelude.Maybe Prelude.Integer,
    -- | Uniquely identifies the job that restores a recovery point.
    RestoreJobsListMember -> Maybe Text
restoreJobId :: Prelude.Maybe Prelude.Text,
    -- | The resource type of the listed restore jobs; for example, an Amazon
    -- Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database
    -- Service (Amazon RDS) database. For Windows Volume Shadow Copy Service
    -- (VSS) backups, the only supported resource type is Amazon EC2.
    RestoreJobsListMember -> Maybe Text
resourceType :: Prelude.Maybe Prelude.Text,
    -- | Contains an estimated percentage complete of a job at the time the job
    -- status was queried.
    RestoreJobsListMember -> Maybe Text
percentDone :: Prelude.Maybe Prelude.Text,
    -- | The account ID that owns the restore job.
    RestoreJobsListMember -> Maybe Text
accountId :: Prelude.Maybe Prelude.Text,
    -- | An Amazon Resource Name (ARN) that uniquely identifies a resource. The
    -- format of the ARN depends on the resource type.
    RestoreJobsListMember -> Maybe Text
createdResourceArn :: Prelude.Maybe Prelude.Text,
    -- | A detailed message explaining the status of the job to restore a
    -- recovery point.
    RestoreJobsListMember -> Maybe Text
statusMessage :: Prelude.Maybe Prelude.Text,
    -- | An ARN that uniquely identifies a recovery point; for example,
    -- @arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45@.
    RestoreJobsListMember -> Maybe Text
recoveryPointArn :: Prelude.Maybe Prelude.Text,
    -- | The size, in bytes, of the restored resource.
    RestoreJobsListMember -> Maybe Integer
backupSizeInBytes :: Prelude.Maybe Prelude.Integer,
    -- | The date and time a restore job is created, in Unix format and
    -- Coordinated Universal Time (UTC). The value of @CreationDate@ is
    -- accurate to milliseconds. For example, the value 1516925490.087
    -- represents Friday, January 26, 2018 12:11:30.087 AM.
    RestoreJobsListMember -> Maybe POSIX
creationDate :: Prelude.Maybe Core.POSIX,
    -- | The date and time a job to restore a recovery point is completed, in
    -- Unix format and Coordinated Universal Time (UTC). The value of
    -- @CompletionDate@ is accurate to milliseconds. For example, the value
    -- 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM.
    RestoreJobsListMember -> Maybe POSIX
completionDate :: Prelude.Maybe Core.POSIX
  }
  deriving (RestoreJobsListMember -> RestoreJobsListMember -> Bool
(RestoreJobsListMember -> RestoreJobsListMember -> Bool)
-> (RestoreJobsListMember -> RestoreJobsListMember -> Bool)
-> Eq RestoreJobsListMember
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: RestoreJobsListMember -> RestoreJobsListMember -> Bool
$c/= :: RestoreJobsListMember -> RestoreJobsListMember -> Bool
== :: RestoreJobsListMember -> RestoreJobsListMember -> Bool
$c== :: RestoreJobsListMember -> RestoreJobsListMember -> Bool
Prelude.Eq, ReadPrec [RestoreJobsListMember]
ReadPrec RestoreJobsListMember
Int -> ReadS RestoreJobsListMember
ReadS [RestoreJobsListMember]
(Int -> ReadS RestoreJobsListMember)
-> ReadS [RestoreJobsListMember]
-> ReadPrec RestoreJobsListMember
-> ReadPrec [RestoreJobsListMember]
-> Read RestoreJobsListMember
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [RestoreJobsListMember]
$creadListPrec :: ReadPrec [RestoreJobsListMember]
readPrec :: ReadPrec RestoreJobsListMember
$creadPrec :: ReadPrec RestoreJobsListMember
readList :: ReadS [RestoreJobsListMember]
$creadList :: ReadS [RestoreJobsListMember]
readsPrec :: Int -> ReadS RestoreJobsListMember
$creadsPrec :: Int -> ReadS RestoreJobsListMember
Prelude.Read, Int -> RestoreJobsListMember -> ShowS
[RestoreJobsListMember] -> ShowS
RestoreJobsListMember -> String
(Int -> RestoreJobsListMember -> ShowS)
-> (RestoreJobsListMember -> String)
-> ([RestoreJobsListMember] -> ShowS)
-> Show RestoreJobsListMember
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [RestoreJobsListMember] -> ShowS
$cshowList :: [RestoreJobsListMember] -> ShowS
show :: RestoreJobsListMember -> String
$cshow :: RestoreJobsListMember -> String
showsPrec :: Int -> RestoreJobsListMember -> ShowS
$cshowsPrec :: Int -> RestoreJobsListMember -> ShowS
Prelude.Show, (forall x. RestoreJobsListMember -> Rep RestoreJobsListMember x)
-> (forall x. Rep RestoreJobsListMember x -> RestoreJobsListMember)
-> Generic RestoreJobsListMember
forall x. Rep RestoreJobsListMember x -> RestoreJobsListMember
forall x. RestoreJobsListMember -> Rep RestoreJobsListMember x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep RestoreJobsListMember x -> RestoreJobsListMember
$cfrom :: forall x. RestoreJobsListMember -> Rep RestoreJobsListMember x
Prelude.Generic)

-- |
-- Create a value of 'RestoreJobsListMember' 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:
--
-- 'status', 'restoreJobsListMember_status' - A status code specifying the state of the job initiated by Backup to
-- restore a recovery point.
--
-- 'iamRoleArn', 'restoreJobsListMember_iamRoleArn' - Specifies the IAM role ARN used to create the target recovery point; for
-- example, @arn:aws:iam::123456789012:role\/S3Access@.
--
-- 'expectedCompletionTimeMinutes', 'restoreJobsListMember_expectedCompletionTimeMinutes' - The amount of time in minutes that a job restoring a recovery point is
-- expected to take.
--
-- 'restoreJobId', 'restoreJobsListMember_restoreJobId' - Uniquely identifies the job that restores a recovery point.
--
-- 'resourceType', 'restoreJobsListMember_resourceType' - The resource type of the listed restore jobs; for example, an Amazon
-- Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database
-- Service (Amazon RDS) database. For Windows Volume Shadow Copy Service
-- (VSS) backups, the only supported resource type is Amazon EC2.
--
-- 'percentDone', 'restoreJobsListMember_percentDone' - Contains an estimated percentage complete of a job at the time the job
-- status was queried.
--
-- 'accountId', 'restoreJobsListMember_accountId' - The account ID that owns the restore job.
--
-- 'createdResourceArn', 'restoreJobsListMember_createdResourceArn' - An Amazon Resource Name (ARN) that uniquely identifies a resource. The
-- format of the ARN depends on the resource type.
--
-- 'statusMessage', 'restoreJobsListMember_statusMessage' - A detailed message explaining the status of the job to restore a
-- recovery point.
--
-- 'recoveryPointArn', 'restoreJobsListMember_recoveryPointArn' - An ARN that uniquely identifies a recovery point; for example,
-- @arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45@.
--
-- 'backupSizeInBytes', 'restoreJobsListMember_backupSizeInBytes' - The size, in bytes, of the restored resource.
--
-- 'creationDate', 'restoreJobsListMember_creationDate' - The date and time a restore job is created, in Unix format and
-- Coordinated Universal Time (UTC). The value of @CreationDate@ is
-- accurate to milliseconds. For example, the value 1516925490.087
-- represents Friday, January 26, 2018 12:11:30.087 AM.
--
-- 'completionDate', 'restoreJobsListMember_completionDate' - The date and time a job to restore a recovery point is completed, in
-- Unix format and Coordinated Universal Time (UTC). The value of
-- @CompletionDate@ is accurate to milliseconds. For example, the value
-- 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM.
newRestoreJobsListMember ::
  RestoreJobsListMember
newRestoreJobsListMember :: RestoreJobsListMember
newRestoreJobsListMember =
  RestoreJobsListMember' :: Maybe RestoreJobStatus
-> Maybe Text
-> Maybe Integer
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Integer
-> Maybe POSIX
-> Maybe POSIX
-> RestoreJobsListMember
RestoreJobsListMember'
    { $sel:status:RestoreJobsListMember' :: Maybe RestoreJobStatus
status = Maybe RestoreJobStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:iamRoleArn:RestoreJobsListMember' :: Maybe Text
iamRoleArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:expectedCompletionTimeMinutes:RestoreJobsListMember' :: Maybe Integer
expectedCompletionTimeMinutes = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
      $sel:restoreJobId:RestoreJobsListMember' :: Maybe Text
restoreJobId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:resourceType:RestoreJobsListMember' :: Maybe Text
resourceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:percentDone:RestoreJobsListMember' :: Maybe Text
percentDone = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:accountId:RestoreJobsListMember' :: Maybe Text
accountId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:createdResourceArn:RestoreJobsListMember' :: Maybe Text
createdResourceArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:statusMessage:RestoreJobsListMember' :: Maybe Text
statusMessage = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:recoveryPointArn:RestoreJobsListMember' :: Maybe Text
recoveryPointArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:backupSizeInBytes:RestoreJobsListMember' :: Maybe Integer
backupSizeInBytes = Maybe Integer
forall a. Maybe a
Prelude.Nothing,
      $sel:creationDate:RestoreJobsListMember' :: Maybe POSIX
creationDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:completionDate:RestoreJobsListMember' :: Maybe POSIX
completionDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing
    }

-- | A status code specifying the state of the job initiated by Backup to
-- restore a recovery point.
restoreJobsListMember_status :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe RestoreJobStatus)
restoreJobsListMember_status :: (Maybe RestoreJobStatus -> f (Maybe RestoreJobStatus))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_status = (RestoreJobsListMember -> Maybe RestoreJobStatus)
-> (RestoreJobsListMember
    -> Maybe RestoreJobStatus -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe RestoreJobStatus)
     (Maybe RestoreJobStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe RestoreJobStatus
status :: Maybe RestoreJobStatus
$sel:status:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe RestoreJobStatus
status} -> Maybe RestoreJobStatus
status) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe RestoreJobStatus
a -> RestoreJobsListMember
s {$sel:status:RestoreJobsListMember' :: Maybe RestoreJobStatus
status = Maybe RestoreJobStatus
a} :: RestoreJobsListMember)

-- | Specifies the IAM role ARN used to create the target recovery point; for
-- example, @arn:aws:iam::123456789012:role\/S3Access@.
restoreJobsListMember_iamRoleArn :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_iamRoleArn :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_iamRoleArn = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
iamRoleArn :: Maybe Text
$sel:iamRoleArn:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
iamRoleArn} -> Maybe Text
iamRoleArn) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:iamRoleArn:RestoreJobsListMember' :: Maybe Text
iamRoleArn = Maybe Text
a} :: RestoreJobsListMember)

-- | The amount of time in minutes that a job restoring a recovery point is
-- expected to take.
restoreJobsListMember_expectedCompletionTimeMinutes :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Integer)
restoreJobsListMember_expectedCompletionTimeMinutes :: (Maybe Integer -> f (Maybe Integer))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_expectedCompletionTimeMinutes = (RestoreJobsListMember -> Maybe Integer)
-> (RestoreJobsListMember
    -> Maybe Integer -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Integer)
     (Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Integer
expectedCompletionTimeMinutes :: Maybe Integer
$sel:expectedCompletionTimeMinutes:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Integer
expectedCompletionTimeMinutes} -> Maybe Integer
expectedCompletionTimeMinutes) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Integer
a -> RestoreJobsListMember
s {$sel:expectedCompletionTimeMinutes:RestoreJobsListMember' :: Maybe Integer
expectedCompletionTimeMinutes = Maybe Integer
a} :: RestoreJobsListMember)

-- | Uniquely identifies the job that restores a recovery point.
restoreJobsListMember_restoreJobId :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_restoreJobId :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_restoreJobId = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
restoreJobId :: Maybe Text
$sel:restoreJobId:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
restoreJobId} -> Maybe Text
restoreJobId) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:restoreJobId:RestoreJobsListMember' :: Maybe Text
restoreJobId = Maybe Text
a} :: RestoreJobsListMember)

-- | The resource type of the listed restore jobs; for example, an Amazon
-- Elastic Block Store (Amazon EBS) volume or an Amazon Relational Database
-- Service (Amazon RDS) database. For Windows Volume Shadow Copy Service
-- (VSS) backups, the only supported resource type is Amazon EC2.
restoreJobsListMember_resourceType :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_resourceType :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_resourceType = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
resourceType :: Maybe Text
$sel:resourceType:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
resourceType} -> Maybe Text
resourceType) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:resourceType:RestoreJobsListMember' :: Maybe Text
resourceType = Maybe Text
a} :: RestoreJobsListMember)

-- | Contains an estimated percentage complete of a job at the time the job
-- status was queried.
restoreJobsListMember_percentDone :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_percentDone :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_percentDone = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
percentDone :: Maybe Text
$sel:percentDone:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
percentDone} -> Maybe Text
percentDone) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:percentDone:RestoreJobsListMember' :: Maybe Text
percentDone = Maybe Text
a} :: RestoreJobsListMember)

-- | The account ID that owns the restore job.
restoreJobsListMember_accountId :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_accountId :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_accountId = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
accountId :: Maybe Text
$sel:accountId:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
accountId} -> Maybe Text
accountId) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:accountId:RestoreJobsListMember' :: Maybe Text
accountId = Maybe Text
a} :: RestoreJobsListMember)

-- | An Amazon Resource Name (ARN) that uniquely identifies a resource. The
-- format of the ARN depends on the resource type.
restoreJobsListMember_createdResourceArn :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_createdResourceArn :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_createdResourceArn = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
createdResourceArn :: Maybe Text
$sel:createdResourceArn:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
createdResourceArn} -> Maybe Text
createdResourceArn) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:createdResourceArn:RestoreJobsListMember' :: Maybe Text
createdResourceArn = Maybe Text
a} :: RestoreJobsListMember)

-- | A detailed message explaining the status of the job to restore a
-- recovery point.
restoreJobsListMember_statusMessage :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_statusMessage :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_statusMessage = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
statusMessage :: Maybe Text
$sel:statusMessage:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
statusMessage} -> Maybe Text
statusMessage) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:statusMessage:RestoreJobsListMember' :: Maybe Text
statusMessage = Maybe Text
a} :: RestoreJobsListMember)

-- | An ARN that uniquely identifies a recovery point; for example,
-- @arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45@.
restoreJobsListMember_recoveryPointArn :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Text)
restoreJobsListMember_recoveryPointArn :: (Maybe Text -> f (Maybe Text))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_recoveryPointArn = (RestoreJobsListMember -> Maybe Text)
-> (RestoreJobsListMember -> Maybe Text -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Text
recoveryPointArn :: Maybe Text
$sel:recoveryPointArn:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Text
recoveryPointArn} -> Maybe Text
recoveryPointArn) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Text
a -> RestoreJobsListMember
s {$sel:recoveryPointArn:RestoreJobsListMember' :: Maybe Text
recoveryPointArn = Maybe Text
a} :: RestoreJobsListMember)

-- | The size, in bytes, of the restored resource.
restoreJobsListMember_backupSizeInBytes :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.Integer)
restoreJobsListMember_backupSizeInBytes :: (Maybe Integer -> f (Maybe Integer))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_backupSizeInBytes = (RestoreJobsListMember -> Maybe Integer)
-> (RestoreJobsListMember
    -> Maybe Integer -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe Integer)
     (Maybe Integer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe Integer
backupSizeInBytes :: Maybe Integer
$sel:backupSizeInBytes:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe Integer
backupSizeInBytes} -> Maybe Integer
backupSizeInBytes) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe Integer
a -> RestoreJobsListMember
s {$sel:backupSizeInBytes:RestoreJobsListMember' :: Maybe Integer
backupSizeInBytes = Maybe Integer
a} :: RestoreJobsListMember)

-- | The date and time a restore job is created, in Unix format and
-- Coordinated Universal Time (UTC). The value of @CreationDate@ is
-- accurate to milliseconds. For example, the value 1516925490.087
-- represents Friday, January 26, 2018 12:11:30.087 AM.
restoreJobsListMember_creationDate :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.UTCTime)
restoreJobsListMember_creationDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_creationDate = (RestoreJobsListMember -> Maybe POSIX)
-> (RestoreJobsListMember -> Maybe POSIX -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe POSIX
creationDate :: Maybe POSIX
$sel:creationDate:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe POSIX
creationDate} -> Maybe POSIX
creationDate) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe POSIX
a -> RestoreJobsListMember
s {$sel:creationDate:RestoreJobsListMember' :: Maybe POSIX
creationDate = Maybe POSIX
a} :: RestoreJobsListMember) ((Maybe POSIX -> f (Maybe POSIX))
 -> RestoreJobsListMember -> f RestoreJobsListMember)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> RestoreJobsListMember
-> f RestoreJobsListMember
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 date and time a job to restore a recovery point is completed, in
-- Unix format and Coordinated Universal Time (UTC). The value of
-- @CompletionDate@ is accurate to milliseconds. For example, the value
-- 1516925490.087 represents Friday, January 26, 2018 12:11:30.087 AM.
restoreJobsListMember_completionDate :: Lens.Lens' RestoreJobsListMember (Prelude.Maybe Prelude.UTCTime)
restoreJobsListMember_completionDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> RestoreJobsListMember -> f RestoreJobsListMember
restoreJobsListMember_completionDate = (RestoreJobsListMember -> Maybe POSIX)
-> (RestoreJobsListMember -> Maybe POSIX -> RestoreJobsListMember)
-> Lens
     RestoreJobsListMember
     RestoreJobsListMember
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\RestoreJobsListMember' {Maybe POSIX
completionDate :: Maybe POSIX
$sel:completionDate:RestoreJobsListMember' :: RestoreJobsListMember -> Maybe POSIX
completionDate} -> Maybe POSIX
completionDate) (\s :: RestoreJobsListMember
s@RestoreJobsListMember' {} Maybe POSIX
a -> RestoreJobsListMember
s {$sel:completionDate:RestoreJobsListMember' :: Maybe POSIX
completionDate = Maybe POSIX
a} :: RestoreJobsListMember) ((Maybe POSIX -> f (Maybe POSIX))
 -> RestoreJobsListMember -> f RestoreJobsListMember)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> RestoreJobsListMember
-> f RestoreJobsListMember
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

instance Core.FromJSON RestoreJobsListMember where
  parseJSON :: Value -> Parser RestoreJobsListMember
parseJSON =
    String
-> (Object -> Parser RestoreJobsListMember)
-> Value
-> Parser RestoreJobsListMember
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"RestoreJobsListMember"
      ( \Object
x ->
          Maybe RestoreJobStatus
-> Maybe Text
-> Maybe Integer
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Integer
-> Maybe POSIX
-> Maybe POSIX
-> RestoreJobsListMember
RestoreJobsListMember'
            (Maybe RestoreJobStatus
 -> Maybe Text
 -> Maybe Integer
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Integer
 -> Maybe POSIX
 -> Maybe POSIX
 -> RestoreJobsListMember)
-> Parser (Maybe RestoreJobStatus)
-> Parser
     (Maybe Text
      -> Maybe Integer
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe RestoreJobStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Status")
            Parser
  (Maybe Text
   -> Maybe Integer
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Integer
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"IamRoleArn")
            Parser
  (Maybe Integer
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Integer)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExpectedCompletionTimeMinutes")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"RestoreJobId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"ResourceType")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"PercentDone")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"AccountId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"CreatedResourceArn")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Integer
      -> Maybe POSIX
      -> Maybe POSIX
      -> RestoreJobsListMember)
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
"StatusMessage")
            Parser
  (Maybe Text
   -> Maybe Integer
   -> Maybe POSIX
   -> Maybe POSIX
   -> RestoreJobsListMember)
-> Parser (Maybe Text)
-> Parser
     (Maybe Integer
      -> Maybe POSIX -> Maybe POSIX -> RestoreJobsListMember)
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
"RecoveryPointArn")
            Parser
  (Maybe Integer
   -> Maybe POSIX -> Maybe POSIX -> RestoreJobsListMember)
-> Parser (Maybe Integer)
-> Parser (Maybe POSIX -> Maybe POSIX -> RestoreJobsListMember)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Integer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"BackupSizeInBytes")
            Parser (Maybe POSIX -> Maybe POSIX -> RestoreJobsListMember)
-> Parser (Maybe POSIX)
-> Parser (Maybe POSIX -> RestoreJobsListMember)
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
"CreationDate")
            Parser (Maybe POSIX -> RestoreJobsListMember)
-> Parser (Maybe POSIX) -> Parser RestoreJobsListMember
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
"CompletionDate")
      )

instance Prelude.Hashable RestoreJobsListMember

instance Prelude.NFData RestoreJobsListMember