{-# 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.S3.DeleteObject
(
DeleteObject (..),
newDeleteObject,
deleteObject_versionId,
deleteObject_mfa,
deleteObject_requestPayer,
deleteObject_bypassGovernanceRetention,
deleteObject_expectedBucketOwner,
deleteObject_bucket,
deleteObject_key,
DeleteObjectResponse (..),
newDeleteObjectResponse,
deleteObjectResponse_requestCharged,
deleteObjectResponse_versionId,
deleteObjectResponse_deleteMarker,
deleteObjectResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.S3.Types
data DeleteObject = DeleteObject'
{
DeleteObject -> Maybe ObjectVersionId
versionId :: Prelude.Maybe ObjectVersionId,
DeleteObject -> Maybe Text
mfa :: Prelude.Maybe Prelude.Text,
DeleteObject -> Maybe RequestPayer
requestPayer :: Prelude.Maybe RequestPayer,
DeleteObject -> Maybe Bool
bypassGovernanceRetention :: Prelude.Maybe Prelude.Bool,
DeleteObject -> Maybe Text
expectedBucketOwner :: Prelude.Maybe Prelude.Text,
DeleteObject -> BucketName
bucket :: BucketName,
DeleteObject -> ObjectKey
key :: ObjectKey
}
deriving (DeleteObject -> DeleteObject -> Bool
(DeleteObject -> DeleteObject -> Bool)
-> (DeleteObject -> DeleteObject -> Bool) -> Eq DeleteObject
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteObject -> DeleteObject -> Bool
$c/= :: DeleteObject -> DeleteObject -> Bool
== :: DeleteObject -> DeleteObject -> Bool
$c== :: DeleteObject -> DeleteObject -> Bool
Prelude.Eq, ReadPrec [DeleteObject]
ReadPrec DeleteObject
Int -> ReadS DeleteObject
ReadS [DeleteObject]
(Int -> ReadS DeleteObject)
-> ReadS [DeleteObject]
-> ReadPrec DeleteObject
-> ReadPrec [DeleteObject]
-> Read DeleteObject
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteObject]
$creadListPrec :: ReadPrec [DeleteObject]
readPrec :: ReadPrec DeleteObject
$creadPrec :: ReadPrec DeleteObject
readList :: ReadS [DeleteObject]
$creadList :: ReadS [DeleteObject]
readsPrec :: Int -> ReadS DeleteObject
$creadsPrec :: Int -> ReadS DeleteObject
Prelude.Read, Int -> DeleteObject -> ShowS
[DeleteObject] -> ShowS
DeleteObject -> String
(Int -> DeleteObject -> ShowS)
-> (DeleteObject -> String)
-> ([DeleteObject] -> ShowS)
-> Show DeleteObject
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteObject] -> ShowS
$cshowList :: [DeleteObject] -> ShowS
show :: DeleteObject -> String
$cshow :: DeleteObject -> String
showsPrec :: Int -> DeleteObject -> ShowS
$cshowsPrec :: Int -> DeleteObject -> ShowS
Prelude.Show, (forall x. DeleteObject -> Rep DeleteObject x)
-> (forall x. Rep DeleteObject x -> DeleteObject)
-> Generic DeleteObject
forall x. Rep DeleteObject x -> DeleteObject
forall x. DeleteObject -> Rep DeleteObject x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteObject x -> DeleteObject
$cfrom :: forall x. DeleteObject -> Rep DeleteObject x
Prelude.Generic)
newDeleteObject ::
BucketName ->
ObjectKey ->
DeleteObject
newDeleteObject :: BucketName -> ObjectKey -> DeleteObject
newDeleteObject BucketName
pBucket_ ObjectKey
pKey_ =
DeleteObject' :: Maybe ObjectVersionId
-> Maybe Text
-> Maybe RequestPayer
-> Maybe Bool
-> Maybe Text
-> BucketName
-> ObjectKey
-> DeleteObject
DeleteObject'
{ $sel:versionId:DeleteObject' :: Maybe ObjectVersionId
versionId = Maybe ObjectVersionId
forall a. Maybe a
Prelude.Nothing,
$sel:mfa:DeleteObject' :: Maybe Text
mfa = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:requestPayer:DeleteObject' :: Maybe RequestPayer
requestPayer = Maybe RequestPayer
forall a. Maybe a
Prelude.Nothing,
$sel:bypassGovernanceRetention:DeleteObject' :: Maybe Bool
bypassGovernanceRetention = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:expectedBucketOwner:DeleteObject' :: Maybe Text
expectedBucketOwner = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:bucket:DeleteObject' :: BucketName
bucket = BucketName
pBucket_,
$sel:key:DeleteObject' :: ObjectKey
key = ObjectKey
pKey_
}
deleteObject_versionId :: Lens.Lens' DeleteObject (Prelude.Maybe ObjectVersionId)
deleteObject_versionId :: (Maybe ObjectVersionId -> f (Maybe ObjectVersionId))
-> DeleteObject -> f DeleteObject
deleteObject_versionId = (DeleteObject -> Maybe ObjectVersionId)
-> (DeleteObject -> Maybe ObjectVersionId -> DeleteObject)
-> Lens
DeleteObject
DeleteObject
(Maybe ObjectVersionId)
(Maybe ObjectVersionId)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {Maybe ObjectVersionId
versionId :: Maybe ObjectVersionId
$sel:versionId:DeleteObject' :: DeleteObject -> Maybe ObjectVersionId
versionId} -> Maybe ObjectVersionId
versionId) (\s :: DeleteObject
s@DeleteObject' {} Maybe ObjectVersionId
a -> DeleteObject
s {$sel:versionId:DeleteObject' :: Maybe ObjectVersionId
versionId = Maybe ObjectVersionId
a} :: DeleteObject)
deleteObject_mfa :: Lens.Lens' DeleteObject (Prelude.Maybe Prelude.Text)
deleteObject_mfa :: (Maybe Text -> f (Maybe Text)) -> DeleteObject -> f DeleteObject
deleteObject_mfa = (DeleteObject -> Maybe Text)
-> (DeleteObject -> Maybe Text -> DeleteObject)
-> Lens DeleteObject DeleteObject (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {Maybe Text
mfa :: Maybe Text
$sel:mfa:DeleteObject' :: DeleteObject -> Maybe Text
mfa} -> Maybe Text
mfa) (\s :: DeleteObject
s@DeleteObject' {} Maybe Text
a -> DeleteObject
s {$sel:mfa:DeleteObject' :: Maybe Text
mfa = Maybe Text
a} :: DeleteObject)
deleteObject_requestPayer :: Lens.Lens' DeleteObject (Prelude.Maybe RequestPayer)
deleteObject_requestPayer :: (Maybe RequestPayer -> f (Maybe RequestPayer))
-> DeleteObject -> f DeleteObject
deleteObject_requestPayer = (DeleteObject -> Maybe RequestPayer)
-> (DeleteObject -> Maybe RequestPayer -> DeleteObject)
-> Lens
DeleteObject DeleteObject (Maybe RequestPayer) (Maybe RequestPayer)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {Maybe RequestPayer
requestPayer :: Maybe RequestPayer
$sel:requestPayer:DeleteObject' :: DeleteObject -> Maybe RequestPayer
requestPayer} -> Maybe RequestPayer
requestPayer) (\s :: DeleteObject
s@DeleteObject' {} Maybe RequestPayer
a -> DeleteObject
s {$sel:requestPayer:DeleteObject' :: Maybe RequestPayer
requestPayer = Maybe RequestPayer
a} :: DeleteObject)
deleteObject_bypassGovernanceRetention :: Lens.Lens' DeleteObject (Prelude.Maybe Prelude.Bool)
deleteObject_bypassGovernanceRetention :: (Maybe Bool -> f (Maybe Bool)) -> DeleteObject -> f DeleteObject
deleteObject_bypassGovernanceRetention = (DeleteObject -> Maybe Bool)
-> (DeleteObject -> Maybe Bool -> DeleteObject)
-> Lens DeleteObject DeleteObject (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {Maybe Bool
bypassGovernanceRetention :: Maybe Bool
$sel:bypassGovernanceRetention:DeleteObject' :: DeleteObject -> Maybe Bool
bypassGovernanceRetention} -> Maybe Bool
bypassGovernanceRetention) (\s :: DeleteObject
s@DeleteObject' {} Maybe Bool
a -> DeleteObject
s {$sel:bypassGovernanceRetention:DeleteObject' :: Maybe Bool
bypassGovernanceRetention = Maybe Bool
a} :: DeleteObject)
deleteObject_expectedBucketOwner :: Lens.Lens' DeleteObject (Prelude.Maybe Prelude.Text)
deleteObject_expectedBucketOwner :: (Maybe Text -> f (Maybe Text)) -> DeleteObject -> f DeleteObject
deleteObject_expectedBucketOwner = (DeleteObject -> Maybe Text)
-> (DeleteObject -> Maybe Text -> DeleteObject)
-> Lens DeleteObject DeleteObject (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {Maybe Text
expectedBucketOwner :: Maybe Text
$sel:expectedBucketOwner:DeleteObject' :: DeleteObject -> Maybe Text
expectedBucketOwner} -> Maybe Text
expectedBucketOwner) (\s :: DeleteObject
s@DeleteObject' {} Maybe Text
a -> DeleteObject
s {$sel:expectedBucketOwner:DeleteObject' :: Maybe Text
expectedBucketOwner = Maybe Text
a} :: DeleteObject)
deleteObject_bucket :: Lens.Lens' DeleteObject BucketName
deleteObject_bucket :: (BucketName -> f BucketName) -> DeleteObject -> f DeleteObject
deleteObject_bucket = (DeleteObject -> BucketName)
-> (DeleteObject -> BucketName -> DeleteObject)
-> Lens DeleteObject DeleteObject BucketName BucketName
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {BucketName
bucket :: BucketName
$sel:bucket:DeleteObject' :: DeleteObject -> BucketName
bucket} -> BucketName
bucket) (\s :: DeleteObject
s@DeleteObject' {} BucketName
a -> DeleteObject
s {$sel:bucket:DeleteObject' :: BucketName
bucket = BucketName
a} :: DeleteObject)
deleteObject_key :: Lens.Lens' DeleteObject ObjectKey
deleteObject_key :: (ObjectKey -> f ObjectKey) -> DeleteObject -> f DeleteObject
deleteObject_key = (DeleteObject -> ObjectKey)
-> (DeleteObject -> ObjectKey -> DeleteObject)
-> Lens DeleteObject DeleteObject ObjectKey ObjectKey
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObject' {ObjectKey
key :: ObjectKey
$sel:key:DeleteObject' :: DeleteObject -> ObjectKey
key} -> ObjectKey
key) (\s :: DeleteObject
s@DeleteObject' {} ObjectKey
a -> DeleteObject
s {$sel:key:DeleteObject' :: ObjectKey
key = ObjectKey
a} :: DeleteObject)
instance Core.AWSRequest DeleteObject where
type AWSResponse DeleteObject = DeleteObjectResponse
request :: DeleteObject -> Request DeleteObject
request =
Request DeleteObject -> Request DeleteObject
forall a. Request a -> Request a
Request.s3vhost
(Request DeleteObject -> Request DeleteObject)
-> (DeleteObject -> Request DeleteObject)
-> DeleteObject
-> Request DeleteObject
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. Service -> DeleteObject -> Request DeleteObject
forall a. ToRequest a => Service -> a -> Request a
Request.delete Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteObject
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse DeleteObject)))
response =
(Int
-> ResponseHeaders
-> ()
-> Either String (AWSResponse DeleteObject))
-> Logger
-> Service
-> Proxy DeleteObject
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse DeleteObject)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> () -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveEmpty
( \Int
s ResponseHeaders
h ()
x ->
Maybe RequestCharged
-> Maybe ObjectVersionId
-> Maybe Bool
-> Int
-> DeleteObjectResponse
DeleteObjectResponse'
(Maybe RequestCharged
-> Maybe ObjectVersionId
-> Maybe Bool
-> Int
-> DeleteObjectResponse)
-> Either String (Maybe RequestCharged)
-> Either
String
(Maybe ObjectVersionId
-> Maybe Bool -> Int -> DeleteObjectResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (ResponseHeaders
h ResponseHeaders
-> HeaderName -> Either String (Maybe RequestCharged)
forall a.
FromText a =>
ResponseHeaders -> HeaderName -> Either String (Maybe a)
Core..#? HeaderName
"x-amz-request-charged")
Either
String
(Maybe ObjectVersionId
-> Maybe Bool -> Int -> DeleteObjectResponse)
-> Either String (Maybe ObjectVersionId)
-> Either String (Maybe Bool -> Int -> DeleteObjectResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (ResponseHeaders
h ResponseHeaders
-> HeaderName -> Either String (Maybe ObjectVersionId)
forall a.
FromText a =>
ResponseHeaders -> HeaderName -> Either String (Maybe a)
Core..#? HeaderName
"x-amz-version-id")
Either String (Maybe Bool -> Int -> DeleteObjectResponse)
-> Either String (Maybe Bool)
-> Either String (Int -> DeleteObjectResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (ResponseHeaders
h ResponseHeaders -> HeaderName -> Either String (Maybe Bool)
forall a.
FromText a =>
ResponseHeaders -> HeaderName -> Either String (Maybe a)
Core..#? HeaderName
"x-amz-delete-marker")
Either String (Int -> DeleteObjectResponse)
-> Either String Int -> Either String DeleteObjectResponse
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 DeleteObject
instance Prelude.NFData DeleteObject
instance Core.ToHeaders DeleteObject where
toHeaders :: DeleteObject -> ResponseHeaders
toHeaders DeleteObject' {Maybe Bool
Maybe Text
Maybe ObjectVersionId
Maybe RequestPayer
ObjectKey
BucketName
key :: ObjectKey
bucket :: BucketName
expectedBucketOwner :: Maybe Text
bypassGovernanceRetention :: Maybe Bool
requestPayer :: Maybe RequestPayer
mfa :: Maybe Text
versionId :: Maybe ObjectVersionId
$sel:key:DeleteObject' :: DeleteObject -> ObjectKey
$sel:bucket:DeleteObject' :: DeleteObject -> BucketName
$sel:expectedBucketOwner:DeleteObject' :: DeleteObject -> Maybe Text
$sel:bypassGovernanceRetention:DeleteObject' :: DeleteObject -> Maybe Bool
$sel:requestPayer:DeleteObject' :: DeleteObject -> Maybe RequestPayer
$sel:mfa:DeleteObject' :: DeleteObject -> Maybe Text
$sel:versionId:DeleteObject' :: DeleteObject -> Maybe ObjectVersionId
..} =
[ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"x-amz-mfa" HeaderName -> Maybe Text -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe Text
mfa,
HeaderName
"x-amz-request-payer" HeaderName -> Maybe RequestPayer -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe RequestPayer
requestPayer,
HeaderName
"x-amz-bypass-governance-retention"
HeaderName -> Maybe Bool -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe Bool
bypassGovernanceRetention,
HeaderName
"x-amz-expected-bucket-owner"
HeaderName -> Maybe Text -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# Maybe Text
expectedBucketOwner
]
instance Core.ToPath DeleteObject where
toPath :: DeleteObject -> ByteString
toPath DeleteObject' {Maybe Bool
Maybe Text
Maybe ObjectVersionId
Maybe RequestPayer
ObjectKey
BucketName
key :: ObjectKey
bucket :: BucketName
expectedBucketOwner :: Maybe Text
bypassGovernanceRetention :: Maybe Bool
requestPayer :: Maybe RequestPayer
mfa :: Maybe Text
versionId :: Maybe ObjectVersionId
$sel:key:DeleteObject' :: DeleteObject -> ObjectKey
$sel:bucket:DeleteObject' :: DeleteObject -> BucketName
$sel:expectedBucketOwner:DeleteObject' :: DeleteObject -> Maybe Text
$sel:bypassGovernanceRetention:DeleteObject' :: DeleteObject -> Maybe Bool
$sel:requestPayer:DeleteObject' :: DeleteObject -> Maybe RequestPayer
$sel:mfa:DeleteObject' :: DeleteObject -> Maybe Text
$sel:versionId:DeleteObject' :: DeleteObject -> Maybe ObjectVersionId
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ByteString
"/", BucketName -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS BucketName
bucket, ByteString
"/", ObjectKey -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS ObjectKey
key]
instance Core.ToQuery DeleteObject where
toQuery :: DeleteObject -> QueryString
toQuery DeleteObject' {Maybe Bool
Maybe Text
Maybe ObjectVersionId
Maybe RequestPayer
ObjectKey
BucketName
key :: ObjectKey
bucket :: BucketName
expectedBucketOwner :: Maybe Text
bypassGovernanceRetention :: Maybe Bool
requestPayer :: Maybe RequestPayer
mfa :: Maybe Text
versionId :: Maybe ObjectVersionId
$sel:key:DeleteObject' :: DeleteObject -> ObjectKey
$sel:bucket:DeleteObject' :: DeleteObject -> BucketName
$sel:expectedBucketOwner:DeleteObject' :: DeleteObject -> Maybe Text
$sel:bypassGovernanceRetention:DeleteObject' :: DeleteObject -> Maybe Bool
$sel:requestPayer:DeleteObject' :: DeleteObject -> Maybe RequestPayer
$sel:mfa:DeleteObject' :: DeleteObject -> Maybe Text
$sel:versionId:DeleteObject' :: DeleteObject -> Maybe ObjectVersionId
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"versionId" ByteString -> Maybe ObjectVersionId -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe ObjectVersionId
versionId]
data DeleteObjectResponse = DeleteObjectResponse'
{ DeleteObjectResponse -> Maybe RequestCharged
requestCharged :: Prelude.Maybe RequestCharged,
DeleteObjectResponse -> Maybe ObjectVersionId
versionId :: Prelude.Maybe ObjectVersionId,
DeleteObjectResponse -> Maybe Bool
deleteMarker :: Prelude.Maybe Prelude.Bool,
DeleteObjectResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DeleteObjectResponse -> DeleteObjectResponse -> Bool
(DeleteObjectResponse -> DeleteObjectResponse -> Bool)
-> (DeleteObjectResponse -> DeleteObjectResponse -> Bool)
-> Eq DeleteObjectResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteObjectResponse -> DeleteObjectResponse -> Bool
$c/= :: DeleteObjectResponse -> DeleteObjectResponse -> Bool
== :: DeleteObjectResponse -> DeleteObjectResponse -> Bool
$c== :: DeleteObjectResponse -> DeleteObjectResponse -> Bool
Prelude.Eq, ReadPrec [DeleteObjectResponse]
ReadPrec DeleteObjectResponse
Int -> ReadS DeleteObjectResponse
ReadS [DeleteObjectResponse]
(Int -> ReadS DeleteObjectResponse)
-> ReadS [DeleteObjectResponse]
-> ReadPrec DeleteObjectResponse
-> ReadPrec [DeleteObjectResponse]
-> Read DeleteObjectResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteObjectResponse]
$creadListPrec :: ReadPrec [DeleteObjectResponse]
readPrec :: ReadPrec DeleteObjectResponse
$creadPrec :: ReadPrec DeleteObjectResponse
readList :: ReadS [DeleteObjectResponse]
$creadList :: ReadS [DeleteObjectResponse]
readsPrec :: Int -> ReadS DeleteObjectResponse
$creadsPrec :: Int -> ReadS DeleteObjectResponse
Prelude.Read, Int -> DeleteObjectResponse -> ShowS
[DeleteObjectResponse] -> ShowS
DeleteObjectResponse -> String
(Int -> DeleteObjectResponse -> ShowS)
-> (DeleteObjectResponse -> String)
-> ([DeleteObjectResponse] -> ShowS)
-> Show DeleteObjectResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteObjectResponse] -> ShowS
$cshowList :: [DeleteObjectResponse] -> ShowS
show :: DeleteObjectResponse -> String
$cshow :: DeleteObjectResponse -> String
showsPrec :: Int -> DeleteObjectResponse -> ShowS
$cshowsPrec :: Int -> DeleteObjectResponse -> ShowS
Prelude.Show, (forall x. DeleteObjectResponse -> Rep DeleteObjectResponse x)
-> (forall x. Rep DeleteObjectResponse x -> DeleteObjectResponse)
-> Generic DeleteObjectResponse
forall x. Rep DeleteObjectResponse x -> DeleteObjectResponse
forall x. DeleteObjectResponse -> Rep DeleteObjectResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteObjectResponse x -> DeleteObjectResponse
$cfrom :: forall x. DeleteObjectResponse -> Rep DeleteObjectResponse x
Prelude.Generic)
newDeleteObjectResponse ::
Prelude.Int ->
DeleteObjectResponse
newDeleteObjectResponse :: Int -> DeleteObjectResponse
newDeleteObjectResponse Int
pHttpStatus_ =
DeleteObjectResponse' :: Maybe RequestCharged
-> Maybe ObjectVersionId
-> Maybe Bool
-> Int
-> DeleteObjectResponse
DeleteObjectResponse'
{ $sel:requestCharged:DeleteObjectResponse' :: Maybe RequestCharged
requestCharged =
Maybe RequestCharged
forall a. Maybe a
Prelude.Nothing,
$sel:versionId:DeleteObjectResponse' :: Maybe ObjectVersionId
versionId = Maybe ObjectVersionId
forall a. Maybe a
Prelude.Nothing,
$sel:deleteMarker:DeleteObjectResponse' :: Maybe Bool
deleteMarker = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DeleteObjectResponse' :: Int
httpStatus = Int
pHttpStatus_
}
deleteObjectResponse_requestCharged :: Lens.Lens' DeleteObjectResponse (Prelude.Maybe RequestCharged)
deleteObjectResponse_requestCharged :: (Maybe RequestCharged -> f (Maybe RequestCharged))
-> DeleteObjectResponse -> f DeleteObjectResponse
deleteObjectResponse_requestCharged = (DeleteObjectResponse -> Maybe RequestCharged)
-> (DeleteObjectResponse
-> Maybe RequestCharged -> DeleteObjectResponse)
-> Lens
DeleteObjectResponse
DeleteObjectResponse
(Maybe RequestCharged)
(Maybe RequestCharged)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObjectResponse' {Maybe RequestCharged
requestCharged :: Maybe RequestCharged
$sel:requestCharged:DeleteObjectResponse' :: DeleteObjectResponse -> Maybe RequestCharged
requestCharged} -> Maybe RequestCharged
requestCharged) (\s :: DeleteObjectResponse
s@DeleteObjectResponse' {} Maybe RequestCharged
a -> DeleteObjectResponse
s {$sel:requestCharged:DeleteObjectResponse' :: Maybe RequestCharged
requestCharged = Maybe RequestCharged
a} :: DeleteObjectResponse)
deleteObjectResponse_versionId :: Lens.Lens' DeleteObjectResponse (Prelude.Maybe ObjectVersionId)
deleteObjectResponse_versionId :: (Maybe ObjectVersionId -> f (Maybe ObjectVersionId))
-> DeleteObjectResponse -> f DeleteObjectResponse
deleteObjectResponse_versionId = (DeleteObjectResponse -> Maybe ObjectVersionId)
-> (DeleteObjectResponse
-> Maybe ObjectVersionId -> DeleteObjectResponse)
-> Lens
DeleteObjectResponse
DeleteObjectResponse
(Maybe ObjectVersionId)
(Maybe ObjectVersionId)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObjectResponse' {Maybe ObjectVersionId
versionId :: Maybe ObjectVersionId
$sel:versionId:DeleteObjectResponse' :: DeleteObjectResponse -> Maybe ObjectVersionId
versionId} -> Maybe ObjectVersionId
versionId) (\s :: DeleteObjectResponse
s@DeleteObjectResponse' {} Maybe ObjectVersionId
a -> DeleteObjectResponse
s {$sel:versionId:DeleteObjectResponse' :: Maybe ObjectVersionId
versionId = Maybe ObjectVersionId
a} :: DeleteObjectResponse)
deleteObjectResponse_deleteMarker :: Lens.Lens' DeleteObjectResponse (Prelude.Maybe Prelude.Bool)
deleteObjectResponse_deleteMarker :: (Maybe Bool -> f (Maybe Bool))
-> DeleteObjectResponse -> f DeleteObjectResponse
deleteObjectResponse_deleteMarker = (DeleteObjectResponse -> Maybe Bool)
-> (DeleteObjectResponse -> Maybe Bool -> DeleteObjectResponse)
-> Lens
DeleteObjectResponse DeleteObjectResponse (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObjectResponse' {Maybe Bool
deleteMarker :: Maybe Bool
$sel:deleteMarker:DeleteObjectResponse' :: DeleteObjectResponse -> Maybe Bool
deleteMarker} -> Maybe Bool
deleteMarker) (\s :: DeleteObjectResponse
s@DeleteObjectResponse' {} Maybe Bool
a -> DeleteObjectResponse
s {$sel:deleteMarker:DeleteObjectResponse' :: Maybe Bool
deleteMarker = Maybe Bool
a} :: DeleteObjectResponse)
deleteObjectResponse_httpStatus :: Lens.Lens' DeleteObjectResponse Prelude.Int
deleteObjectResponse_httpStatus :: (Int -> f Int) -> DeleteObjectResponse -> f DeleteObjectResponse
deleteObjectResponse_httpStatus = (DeleteObjectResponse -> Int)
-> (DeleteObjectResponse -> Int -> DeleteObjectResponse)
-> Lens DeleteObjectResponse DeleteObjectResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteObjectResponse' {Int
httpStatus :: Int
$sel:httpStatus:DeleteObjectResponse' :: DeleteObjectResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DeleteObjectResponse
s@DeleteObjectResponse' {} Int
a -> DeleteObjectResponse
s {$sel:httpStatus:DeleteObjectResponse' :: Int
httpStatus = Int
a} :: DeleteObjectResponse)
instance Prelude.NFData DeleteObjectResponse