{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Lightsail.CopySnapshot
(
CopySnapshot (..),
newCopySnapshot,
copySnapshot_useLatestRestorableAutoSnapshot,
copySnapshot_restoreDate,
copySnapshot_sourceResourceName,
copySnapshot_sourceSnapshotName,
copySnapshot_targetSnapshotName,
copySnapshot_sourceRegion,
CopySnapshotResponse (..),
newCopySnapshotResponse,
copySnapshotResponse_operations,
copySnapshotResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.Lightsail.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CopySnapshot = CopySnapshot'
{
CopySnapshot -> Maybe Bool
useLatestRestorableAutoSnapshot :: Prelude.Maybe Prelude.Bool,
CopySnapshot -> Maybe Text
restoreDate :: Prelude.Maybe Prelude.Text,
CopySnapshot -> Maybe Text
sourceResourceName :: Prelude.Maybe Prelude.Text,
CopySnapshot -> Maybe Text
sourceSnapshotName :: Prelude.Maybe Prelude.Text,
CopySnapshot -> Text
targetSnapshotName :: Prelude.Text,
CopySnapshot -> RegionName
sourceRegion :: RegionName
}
deriving (CopySnapshot -> CopySnapshot -> Bool
(CopySnapshot -> CopySnapshot -> Bool)
-> (CopySnapshot -> CopySnapshot -> Bool) -> Eq CopySnapshot
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CopySnapshot -> CopySnapshot -> Bool
$c/= :: CopySnapshot -> CopySnapshot -> Bool
== :: CopySnapshot -> CopySnapshot -> Bool
$c== :: CopySnapshot -> CopySnapshot -> Bool
Prelude.Eq, ReadPrec [CopySnapshot]
ReadPrec CopySnapshot
Int -> ReadS CopySnapshot
ReadS [CopySnapshot]
(Int -> ReadS CopySnapshot)
-> ReadS [CopySnapshot]
-> ReadPrec CopySnapshot
-> ReadPrec [CopySnapshot]
-> Read CopySnapshot
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CopySnapshot]
$creadListPrec :: ReadPrec [CopySnapshot]
readPrec :: ReadPrec CopySnapshot
$creadPrec :: ReadPrec CopySnapshot
readList :: ReadS [CopySnapshot]
$creadList :: ReadS [CopySnapshot]
readsPrec :: Int -> ReadS CopySnapshot
$creadsPrec :: Int -> ReadS CopySnapshot
Prelude.Read, Int -> CopySnapshot -> ShowS
[CopySnapshot] -> ShowS
CopySnapshot -> String
(Int -> CopySnapshot -> ShowS)
-> (CopySnapshot -> String)
-> ([CopySnapshot] -> ShowS)
-> Show CopySnapshot
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CopySnapshot] -> ShowS
$cshowList :: [CopySnapshot] -> ShowS
show :: CopySnapshot -> String
$cshow :: CopySnapshot -> String
showsPrec :: Int -> CopySnapshot -> ShowS
$cshowsPrec :: Int -> CopySnapshot -> ShowS
Prelude.Show, (forall x. CopySnapshot -> Rep CopySnapshot x)
-> (forall x. Rep CopySnapshot x -> CopySnapshot)
-> Generic CopySnapshot
forall x. Rep CopySnapshot x -> CopySnapshot
forall x. CopySnapshot -> Rep CopySnapshot x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CopySnapshot x -> CopySnapshot
$cfrom :: forall x. CopySnapshot -> Rep CopySnapshot x
Prelude.Generic)
newCopySnapshot ::
Prelude.Text ->
RegionName ->
CopySnapshot
newCopySnapshot :: Text -> RegionName -> CopySnapshot
newCopySnapshot Text
pTargetSnapshotName_ RegionName
pSourceRegion_ =
CopySnapshot' :: Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Text
-> RegionName
-> CopySnapshot
CopySnapshot'
{ $sel:useLatestRestorableAutoSnapshot:CopySnapshot' :: Maybe Bool
useLatestRestorableAutoSnapshot =
Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:restoreDate:CopySnapshot' :: Maybe Text
restoreDate = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sourceResourceName:CopySnapshot' :: Maybe Text
sourceResourceName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:sourceSnapshotName:CopySnapshot' :: Maybe Text
sourceSnapshotName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:targetSnapshotName:CopySnapshot' :: Text
targetSnapshotName = Text
pTargetSnapshotName_,
$sel:sourceRegion:CopySnapshot' :: RegionName
sourceRegion = RegionName
pSourceRegion_
}
copySnapshot_useLatestRestorableAutoSnapshot :: Lens.Lens' CopySnapshot (Prelude.Maybe Prelude.Bool)
copySnapshot_useLatestRestorableAutoSnapshot :: (Maybe Bool -> f (Maybe Bool)) -> CopySnapshot -> f CopySnapshot
copySnapshot_useLatestRestorableAutoSnapshot = (CopySnapshot -> Maybe Bool)
-> (CopySnapshot -> Maybe Bool -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {Maybe Bool
useLatestRestorableAutoSnapshot :: Maybe Bool
$sel:useLatestRestorableAutoSnapshot:CopySnapshot' :: CopySnapshot -> Maybe Bool
useLatestRestorableAutoSnapshot} -> Maybe Bool
useLatestRestorableAutoSnapshot) (\s :: CopySnapshot
s@CopySnapshot' {} Maybe Bool
a -> CopySnapshot
s {$sel:useLatestRestorableAutoSnapshot:CopySnapshot' :: Maybe Bool
useLatestRestorableAutoSnapshot = Maybe Bool
a} :: CopySnapshot)
copySnapshot_restoreDate :: Lens.Lens' CopySnapshot (Prelude.Maybe Prelude.Text)
copySnapshot_restoreDate :: (Maybe Text -> f (Maybe Text)) -> CopySnapshot -> f CopySnapshot
copySnapshot_restoreDate = (CopySnapshot -> Maybe Text)
-> (CopySnapshot -> Maybe Text -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {Maybe Text
restoreDate :: Maybe Text
$sel:restoreDate:CopySnapshot' :: CopySnapshot -> Maybe Text
restoreDate} -> Maybe Text
restoreDate) (\s :: CopySnapshot
s@CopySnapshot' {} Maybe Text
a -> CopySnapshot
s {$sel:restoreDate:CopySnapshot' :: Maybe Text
restoreDate = Maybe Text
a} :: CopySnapshot)
copySnapshot_sourceResourceName :: Lens.Lens' CopySnapshot (Prelude.Maybe Prelude.Text)
copySnapshot_sourceResourceName :: (Maybe Text -> f (Maybe Text)) -> CopySnapshot -> f CopySnapshot
copySnapshot_sourceResourceName = (CopySnapshot -> Maybe Text)
-> (CopySnapshot -> Maybe Text -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {Maybe Text
sourceResourceName :: Maybe Text
$sel:sourceResourceName:CopySnapshot' :: CopySnapshot -> Maybe Text
sourceResourceName} -> Maybe Text
sourceResourceName) (\s :: CopySnapshot
s@CopySnapshot' {} Maybe Text
a -> CopySnapshot
s {$sel:sourceResourceName:CopySnapshot' :: Maybe Text
sourceResourceName = Maybe Text
a} :: CopySnapshot)
copySnapshot_sourceSnapshotName :: Lens.Lens' CopySnapshot (Prelude.Maybe Prelude.Text)
copySnapshot_sourceSnapshotName :: (Maybe Text -> f (Maybe Text)) -> CopySnapshot -> f CopySnapshot
copySnapshot_sourceSnapshotName = (CopySnapshot -> Maybe Text)
-> (CopySnapshot -> Maybe Text -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {Maybe Text
sourceSnapshotName :: Maybe Text
$sel:sourceSnapshotName:CopySnapshot' :: CopySnapshot -> Maybe Text
sourceSnapshotName} -> Maybe Text
sourceSnapshotName) (\s :: CopySnapshot
s@CopySnapshot' {} Maybe Text
a -> CopySnapshot
s {$sel:sourceSnapshotName:CopySnapshot' :: Maybe Text
sourceSnapshotName = Maybe Text
a} :: CopySnapshot)
copySnapshot_targetSnapshotName :: Lens.Lens' CopySnapshot Prelude.Text
copySnapshot_targetSnapshotName :: (Text -> f Text) -> CopySnapshot -> f CopySnapshot
copySnapshot_targetSnapshotName = (CopySnapshot -> Text)
-> (CopySnapshot -> Text -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {Text
targetSnapshotName :: Text
$sel:targetSnapshotName:CopySnapshot' :: CopySnapshot -> Text
targetSnapshotName} -> Text
targetSnapshotName) (\s :: CopySnapshot
s@CopySnapshot' {} Text
a -> CopySnapshot
s {$sel:targetSnapshotName:CopySnapshot' :: Text
targetSnapshotName = Text
a} :: CopySnapshot)
copySnapshot_sourceRegion :: Lens.Lens' CopySnapshot RegionName
copySnapshot_sourceRegion :: (RegionName -> f RegionName) -> CopySnapshot -> f CopySnapshot
copySnapshot_sourceRegion = (CopySnapshot -> RegionName)
-> (CopySnapshot -> RegionName -> CopySnapshot)
-> Lens CopySnapshot CopySnapshot RegionName RegionName
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshot' {RegionName
sourceRegion :: RegionName
$sel:sourceRegion:CopySnapshot' :: CopySnapshot -> RegionName
sourceRegion} -> RegionName
sourceRegion) (\s :: CopySnapshot
s@CopySnapshot' {} RegionName
a -> CopySnapshot
s {$sel:sourceRegion:CopySnapshot' :: RegionName
sourceRegion = RegionName
a} :: CopySnapshot)
instance Core.AWSRequest CopySnapshot where
type AWSResponse CopySnapshot = CopySnapshotResponse
request :: CopySnapshot -> Request CopySnapshot
request = Service -> CopySnapshot -> Request CopySnapshot
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy CopySnapshot
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CopySnapshot)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse CopySnapshot))
-> Logger
-> Service
-> Proxy CopySnapshot
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CopySnapshot)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe [Operation] -> Int -> CopySnapshotResponse
CopySnapshotResponse'
(Maybe [Operation] -> Int -> CopySnapshotResponse)
-> Either String (Maybe [Operation])
-> Either String (Int -> CopySnapshotResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe (Maybe [Operation]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"operations" Either String (Maybe (Maybe [Operation]))
-> Maybe [Operation] -> Either String (Maybe [Operation])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [Operation]
forall a. Monoid a => a
Prelude.mempty)
Either String (Int -> CopySnapshotResponse)
-> Either String Int -> Either String CopySnapshotResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable CopySnapshot
instance Prelude.NFData CopySnapshot
instance Core.ToHeaders CopySnapshot where
toHeaders :: CopySnapshot -> ResponseHeaders
toHeaders =
ResponseHeaders -> CopySnapshot -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"Lightsail_20161128.CopySnapshot" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON CopySnapshot where
toJSON :: CopySnapshot -> Value
toJSON CopySnapshot' {Maybe Bool
Maybe Text
Text
RegionName
sourceRegion :: RegionName
targetSnapshotName :: Text
sourceSnapshotName :: Maybe Text
sourceResourceName :: Maybe Text
restoreDate :: Maybe Text
useLatestRestorableAutoSnapshot :: Maybe Bool
$sel:sourceRegion:CopySnapshot' :: CopySnapshot -> RegionName
$sel:targetSnapshotName:CopySnapshot' :: CopySnapshot -> Text
$sel:sourceSnapshotName:CopySnapshot' :: CopySnapshot -> Maybe Text
$sel:sourceResourceName:CopySnapshot' :: CopySnapshot -> Maybe Text
$sel:restoreDate:CopySnapshot' :: CopySnapshot -> Maybe Text
$sel:useLatestRestorableAutoSnapshot:CopySnapshot' :: CopySnapshot -> Maybe Bool
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"useLatestRestorableAutoSnapshot" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
useLatestRestorableAutoSnapshot,
(Text
"restoreDate" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
restoreDate,
(Text
"sourceResourceName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sourceResourceName,
(Text
"sourceSnapshotName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sourceSnapshotName,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
(Text
"targetSnapshotName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
targetSnapshotName),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"sourceRegion" Text -> RegionName -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= RegionName
sourceRegion)
]
)
instance Core.ToPath CopySnapshot where
toPath :: CopySnapshot -> ByteString
toPath = ByteString -> CopySnapshot -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery CopySnapshot where
toQuery :: CopySnapshot -> QueryString
toQuery = QueryString -> CopySnapshot -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data CopySnapshotResponse = CopySnapshotResponse'
{
CopySnapshotResponse -> Maybe [Operation]
operations :: Prelude.Maybe [Operation],
CopySnapshotResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CopySnapshotResponse -> CopySnapshotResponse -> Bool
(CopySnapshotResponse -> CopySnapshotResponse -> Bool)
-> (CopySnapshotResponse -> CopySnapshotResponse -> Bool)
-> Eq CopySnapshotResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CopySnapshotResponse -> CopySnapshotResponse -> Bool
$c/= :: CopySnapshotResponse -> CopySnapshotResponse -> Bool
== :: CopySnapshotResponse -> CopySnapshotResponse -> Bool
$c== :: CopySnapshotResponse -> CopySnapshotResponse -> Bool
Prelude.Eq, ReadPrec [CopySnapshotResponse]
ReadPrec CopySnapshotResponse
Int -> ReadS CopySnapshotResponse
ReadS [CopySnapshotResponse]
(Int -> ReadS CopySnapshotResponse)
-> ReadS [CopySnapshotResponse]
-> ReadPrec CopySnapshotResponse
-> ReadPrec [CopySnapshotResponse]
-> Read CopySnapshotResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CopySnapshotResponse]
$creadListPrec :: ReadPrec [CopySnapshotResponse]
readPrec :: ReadPrec CopySnapshotResponse
$creadPrec :: ReadPrec CopySnapshotResponse
readList :: ReadS [CopySnapshotResponse]
$creadList :: ReadS [CopySnapshotResponse]
readsPrec :: Int -> ReadS CopySnapshotResponse
$creadsPrec :: Int -> ReadS CopySnapshotResponse
Prelude.Read, Int -> CopySnapshotResponse -> ShowS
[CopySnapshotResponse] -> ShowS
CopySnapshotResponse -> String
(Int -> CopySnapshotResponse -> ShowS)
-> (CopySnapshotResponse -> String)
-> ([CopySnapshotResponse] -> ShowS)
-> Show CopySnapshotResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CopySnapshotResponse] -> ShowS
$cshowList :: [CopySnapshotResponse] -> ShowS
show :: CopySnapshotResponse -> String
$cshow :: CopySnapshotResponse -> String
showsPrec :: Int -> CopySnapshotResponse -> ShowS
$cshowsPrec :: Int -> CopySnapshotResponse -> ShowS
Prelude.Show, (forall x. CopySnapshotResponse -> Rep CopySnapshotResponse x)
-> (forall x. Rep CopySnapshotResponse x -> CopySnapshotResponse)
-> Generic CopySnapshotResponse
forall x. Rep CopySnapshotResponse x -> CopySnapshotResponse
forall x. CopySnapshotResponse -> Rep CopySnapshotResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CopySnapshotResponse x -> CopySnapshotResponse
$cfrom :: forall x. CopySnapshotResponse -> Rep CopySnapshotResponse x
Prelude.Generic)
newCopySnapshotResponse ::
Prelude.Int ->
CopySnapshotResponse
newCopySnapshotResponse :: Int -> CopySnapshotResponse
newCopySnapshotResponse Int
pHttpStatus_ =
CopySnapshotResponse' :: Maybe [Operation] -> Int -> CopySnapshotResponse
CopySnapshotResponse'
{ $sel:operations:CopySnapshotResponse' :: Maybe [Operation]
operations = Maybe [Operation]
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CopySnapshotResponse' :: Int
httpStatus = Int
pHttpStatus_
}
copySnapshotResponse_operations :: Lens.Lens' CopySnapshotResponse (Prelude.Maybe [Operation])
copySnapshotResponse_operations :: (Maybe [Operation] -> f (Maybe [Operation]))
-> CopySnapshotResponse -> f CopySnapshotResponse
copySnapshotResponse_operations = (CopySnapshotResponse -> Maybe [Operation])
-> (CopySnapshotResponse
-> Maybe [Operation] -> CopySnapshotResponse)
-> Lens
CopySnapshotResponse
CopySnapshotResponse
(Maybe [Operation])
(Maybe [Operation])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshotResponse' {Maybe [Operation]
operations :: Maybe [Operation]
$sel:operations:CopySnapshotResponse' :: CopySnapshotResponse -> Maybe [Operation]
operations} -> Maybe [Operation]
operations) (\s :: CopySnapshotResponse
s@CopySnapshotResponse' {} Maybe [Operation]
a -> CopySnapshotResponse
s {$sel:operations:CopySnapshotResponse' :: Maybe [Operation]
operations = Maybe [Operation]
a} :: CopySnapshotResponse) ((Maybe [Operation] -> f (Maybe [Operation]))
-> CopySnapshotResponse -> f CopySnapshotResponse)
-> ((Maybe [Operation] -> f (Maybe [Operation]))
-> Maybe [Operation] -> f (Maybe [Operation]))
-> (Maybe [Operation] -> f (Maybe [Operation]))
-> CopySnapshotResponse
-> f CopySnapshotResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Operation] [Operation] [Operation] [Operation]
-> Iso
(Maybe [Operation])
(Maybe [Operation])
(Maybe [Operation])
(Maybe [Operation])
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 [Operation] [Operation] [Operation] [Operation]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
copySnapshotResponse_httpStatus :: Lens.Lens' CopySnapshotResponse Prelude.Int
copySnapshotResponse_httpStatus :: (Int -> f Int) -> CopySnapshotResponse -> f CopySnapshotResponse
copySnapshotResponse_httpStatus = (CopySnapshotResponse -> Int)
-> (CopySnapshotResponse -> Int -> CopySnapshotResponse)
-> Lens CopySnapshotResponse CopySnapshotResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CopySnapshotResponse' {Int
httpStatus :: Int
$sel:httpStatus:CopySnapshotResponse' :: CopySnapshotResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CopySnapshotResponse
s@CopySnapshotResponse' {} Int
a -> CopySnapshotResponse
s {$sel:httpStatus:CopySnapshotResponse' :: Int
httpStatus = Int
a} :: CopySnapshotResponse)
instance Prelude.NFData CopySnapshotResponse