{-# 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.Redshift.DeleteSnapshotCopyGrant
(
DeleteSnapshotCopyGrant (..),
newDeleteSnapshotCopyGrant,
deleteSnapshotCopyGrant_snapshotCopyGrantName,
DeleteSnapshotCopyGrantResponse (..),
newDeleteSnapshotCopyGrantResponse,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import Amazonka.Redshift.Types
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DeleteSnapshotCopyGrant = DeleteSnapshotCopyGrant'
{
DeleteSnapshotCopyGrant -> Text
snapshotCopyGrantName :: Prelude.Text
}
deriving (DeleteSnapshotCopyGrant -> DeleteSnapshotCopyGrant -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteSnapshotCopyGrant -> DeleteSnapshotCopyGrant -> Bool
$c/= :: DeleteSnapshotCopyGrant -> DeleteSnapshotCopyGrant -> Bool
== :: DeleteSnapshotCopyGrant -> DeleteSnapshotCopyGrant -> Bool
$c== :: DeleteSnapshotCopyGrant -> DeleteSnapshotCopyGrant -> Bool
Prelude.Eq, ReadPrec [DeleteSnapshotCopyGrant]
ReadPrec DeleteSnapshotCopyGrant
Int -> ReadS DeleteSnapshotCopyGrant
ReadS [DeleteSnapshotCopyGrant]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteSnapshotCopyGrant]
$creadListPrec :: ReadPrec [DeleteSnapshotCopyGrant]
readPrec :: ReadPrec DeleteSnapshotCopyGrant
$creadPrec :: ReadPrec DeleteSnapshotCopyGrant
readList :: ReadS [DeleteSnapshotCopyGrant]
$creadList :: ReadS [DeleteSnapshotCopyGrant]
readsPrec :: Int -> ReadS DeleteSnapshotCopyGrant
$creadsPrec :: Int -> ReadS DeleteSnapshotCopyGrant
Prelude.Read, Int -> DeleteSnapshotCopyGrant -> ShowS
[DeleteSnapshotCopyGrant] -> ShowS
DeleteSnapshotCopyGrant -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteSnapshotCopyGrant] -> ShowS
$cshowList :: [DeleteSnapshotCopyGrant] -> ShowS
show :: DeleteSnapshotCopyGrant -> String
$cshow :: DeleteSnapshotCopyGrant -> String
showsPrec :: Int -> DeleteSnapshotCopyGrant -> ShowS
$cshowsPrec :: Int -> DeleteSnapshotCopyGrant -> ShowS
Prelude.Show, forall x. Rep DeleteSnapshotCopyGrant x -> DeleteSnapshotCopyGrant
forall x. DeleteSnapshotCopyGrant -> Rep DeleteSnapshotCopyGrant x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteSnapshotCopyGrant x -> DeleteSnapshotCopyGrant
$cfrom :: forall x. DeleteSnapshotCopyGrant -> Rep DeleteSnapshotCopyGrant x
Prelude.Generic)
newDeleteSnapshotCopyGrant ::
Prelude.Text ->
DeleteSnapshotCopyGrant
newDeleteSnapshotCopyGrant :: Text -> DeleteSnapshotCopyGrant
newDeleteSnapshotCopyGrant Text
pSnapshotCopyGrantName_ =
DeleteSnapshotCopyGrant'
{ $sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: Text
snapshotCopyGrantName =
Text
pSnapshotCopyGrantName_
}
deleteSnapshotCopyGrant_snapshotCopyGrantName :: Lens.Lens' DeleteSnapshotCopyGrant Prelude.Text
deleteSnapshotCopyGrant_snapshotCopyGrantName :: Lens' DeleteSnapshotCopyGrant Text
deleteSnapshotCopyGrant_snapshotCopyGrantName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteSnapshotCopyGrant' {Text
snapshotCopyGrantName :: Text
$sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: DeleteSnapshotCopyGrant -> Text
snapshotCopyGrantName} -> Text
snapshotCopyGrantName) (\s :: DeleteSnapshotCopyGrant
s@DeleteSnapshotCopyGrant' {} Text
a -> DeleteSnapshotCopyGrant
s {$sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: Text
snapshotCopyGrantName = Text
a} :: DeleteSnapshotCopyGrant)
instance Core.AWSRequest DeleteSnapshotCopyGrant where
type
AWSResponse DeleteSnapshotCopyGrant =
DeleteSnapshotCopyGrantResponse
request :: (Service -> Service)
-> DeleteSnapshotCopyGrant -> Request DeleteSnapshotCopyGrant
request Service -> Service
overrides =
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy DeleteSnapshotCopyGrant
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteSnapshotCopyGrant)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
DeleteSnapshotCopyGrantResponse
DeleteSnapshotCopyGrantResponse'
instance Prelude.Hashable DeleteSnapshotCopyGrant where
hashWithSalt :: Int -> DeleteSnapshotCopyGrant -> Int
hashWithSalt Int
_salt DeleteSnapshotCopyGrant' {Text
snapshotCopyGrantName :: Text
$sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: DeleteSnapshotCopyGrant -> Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
snapshotCopyGrantName
instance Prelude.NFData DeleteSnapshotCopyGrant where
rnf :: DeleteSnapshotCopyGrant -> ()
rnf DeleteSnapshotCopyGrant' {Text
snapshotCopyGrantName :: Text
$sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: DeleteSnapshotCopyGrant -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
snapshotCopyGrantName
instance Data.ToHeaders DeleteSnapshotCopyGrant where
toHeaders :: DeleteSnapshotCopyGrant -> [Header]
toHeaders = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
instance Data.ToPath DeleteSnapshotCopyGrant where
toPath :: DeleteSnapshotCopyGrant -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery DeleteSnapshotCopyGrant where
toQuery :: DeleteSnapshotCopyGrant -> QueryString
toQuery DeleteSnapshotCopyGrant' {Text
snapshotCopyGrantName :: Text
$sel:snapshotCopyGrantName:DeleteSnapshotCopyGrant' :: DeleteSnapshotCopyGrant -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: (ByteString
"DeleteSnapshotCopyGrant" :: Prelude.ByteString),
ByteString
"Version"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: (ByteString
"2012-12-01" :: Prelude.ByteString),
ByteString
"SnapshotCopyGrantName"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Text
snapshotCopyGrantName
]
data DeleteSnapshotCopyGrantResponse = DeleteSnapshotCopyGrantResponse'
{
}
deriving (DeleteSnapshotCopyGrantResponse
-> DeleteSnapshotCopyGrantResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteSnapshotCopyGrantResponse
-> DeleteSnapshotCopyGrantResponse -> Bool
$c/= :: DeleteSnapshotCopyGrantResponse
-> DeleteSnapshotCopyGrantResponse -> Bool
== :: DeleteSnapshotCopyGrantResponse
-> DeleteSnapshotCopyGrantResponse -> Bool
$c== :: DeleteSnapshotCopyGrantResponse
-> DeleteSnapshotCopyGrantResponse -> Bool
Prelude.Eq, ReadPrec [DeleteSnapshotCopyGrantResponse]
ReadPrec DeleteSnapshotCopyGrantResponse
Int -> ReadS DeleteSnapshotCopyGrantResponse
ReadS [DeleteSnapshotCopyGrantResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteSnapshotCopyGrantResponse]
$creadListPrec :: ReadPrec [DeleteSnapshotCopyGrantResponse]
readPrec :: ReadPrec DeleteSnapshotCopyGrantResponse
$creadPrec :: ReadPrec DeleteSnapshotCopyGrantResponse
readList :: ReadS [DeleteSnapshotCopyGrantResponse]
$creadList :: ReadS [DeleteSnapshotCopyGrantResponse]
readsPrec :: Int -> ReadS DeleteSnapshotCopyGrantResponse
$creadsPrec :: Int -> ReadS DeleteSnapshotCopyGrantResponse
Prelude.Read, Int -> DeleteSnapshotCopyGrantResponse -> ShowS
[DeleteSnapshotCopyGrantResponse] -> ShowS
DeleteSnapshotCopyGrantResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteSnapshotCopyGrantResponse] -> ShowS
$cshowList :: [DeleteSnapshotCopyGrantResponse] -> ShowS
show :: DeleteSnapshotCopyGrantResponse -> String
$cshow :: DeleteSnapshotCopyGrantResponse -> String
showsPrec :: Int -> DeleteSnapshotCopyGrantResponse -> ShowS
$cshowsPrec :: Int -> DeleteSnapshotCopyGrantResponse -> ShowS
Prelude.Show, forall x.
Rep DeleteSnapshotCopyGrantResponse x
-> DeleteSnapshotCopyGrantResponse
forall x.
DeleteSnapshotCopyGrantResponse
-> Rep DeleteSnapshotCopyGrantResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteSnapshotCopyGrantResponse x
-> DeleteSnapshotCopyGrantResponse
$cfrom :: forall x.
DeleteSnapshotCopyGrantResponse
-> Rep DeleteSnapshotCopyGrantResponse x
Prelude.Generic)
newDeleteSnapshotCopyGrantResponse ::
DeleteSnapshotCopyGrantResponse
newDeleteSnapshotCopyGrantResponse :: DeleteSnapshotCopyGrantResponse
newDeleteSnapshotCopyGrantResponse =
DeleteSnapshotCopyGrantResponse
DeleteSnapshotCopyGrantResponse'
instance
Prelude.NFData
DeleteSnapshotCopyGrantResponse
where
rnf :: DeleteSnapshotCopyGrantResponse -> ()
rnf DeleteSnapshotCopyGrantResponse
_ = ()