{-# 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.CloudFront.DeleteFieldLevelEncryptionProfile
(
DeleteFieldLevelEncryptionProfile (..),
newDeleteFieldLevelEncryptionProfile,
deleteFieldLevelEncryptionProfile_ifMatch,
deleteFieldLevelEncryptionProfile_id,
DeleteFieldLevelEncryptionProfileResponse (..),
newDeleteFieldLevelEncryptionProfileResponse,
)
where
import Amazonka.CloudFront.Types
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
data DeleteFieldLevelEncryptionProfile = DeleteFieldLevelEncryptionProfile'
{
DeleteFieldLevelEncryptionProfile -> Maybe Text
ifMatch :: Prelude.Maybe Prelude.Text,
DeleteFieldLevelEncryptionProfile -> Text
id :: Prelude.Text
}
deriving (DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool
(DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool)
-> (DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool)
-> Eq DeleteFieldLevelEncryptionProfile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool
$c/= :: DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool
== :: DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool
$c== :: DeleteFieldLevelEncryptionProfile
-> DeleteFieldLevelEncryptionProfile -> Bool
Prelude.Eq, ReadPrec [DeleteFieldLevelEncryptionProfile]
ReadPrec DeleteFieldLevelEncryptionProfile
Int -> ReadS DeleteFieldLevelEncryptionProfile
ReadS [DeleteFieldLevelEncryptionProfile]
(Int -> ReadS DeleteFieldLevelEncryptionProfile)
-> ReadS [DeleteFieldLevelEncryptionProfile]
-> ReadPrec DeleteFieldLevelEncryptionProfile
-> ReadPrec [DeleteFieldLevelEncryptionProfile]
-> Read DeleteFieldLevelEncryptionProfile
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteFieldLevelEncryptionProfile]
$creadListPrec :: ReadPrec [DeleteFieldLevelEncryptionProfile]
readPrec :: ReadPrec DeleteFieldLevelEncryptionProfile
$creadPrec :: ReadPrec DeleteFieldLevelEncryptionProfile
readList :: ReadS [DeleteFieldLevelEncryptionProfile]
$creadList :: ReadS [DeleteFieldLevelEncryptionProfile]
readsPrec :: Int -> ReadS DeleteFieldLevelEncryptionProfile
$creadsPrec :: Int -> ReadS DeleteFieldLevelEncryptionProfile
Prelude.Read, Int -> DeleteFieldLevelEncryptionProfile -> ShowS
[DeleteFieldLevelEncryptionProfile] -> ShowS
DeleteFieldLevelEncryptionProfile -> String
(Int -> DeleteFieldLevelEncryptionProfile -> ShowS)
-> (DeleteFieldLevelEncryptionProfile -> String)
-> ([DeleteFieldLevelEncryptionProfile] -> ShowS)
-> Show DeleteFieldLevelEncryptionProfile
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteFieldLevelEncryptionProfile] -> ShowS
$cshowList :: [DeleteFieldLevelEncryptionProfile] -> ShowS
show :: DeleteFieldLevelEncryptionProfile -> String
$cshow :: DeleteFieldLevelEncryptionProfile -> String
showsPrec :: Int -> DeleteFieldLevelEncryptionProfile -> ShowS
$cshowsPrec :: Int -> DeleteFieldLevelEncryptionProfile -> ShowS
Prelude.Show, (forall x.
DeleteFieldLevelEncryptionProfile
-> Rep DeleteFieldLevelEncryptionProfile x)
-> (forall x.
Rep DeleteFieldLevelEncryptionProfile x
-> DeleteFieldLevelEncryptionProfile)
-> Generic DeleteFieldLevelEncryptionProfile
forall x.
Rep DeleteFieldLevelEncryptionProfile x
-> DeleteFieldLevelEncryptionProfile
forall x.
DeleteFieldLevelEncryptionProfile
-> Rep DeleteFieldLevelEncryptionProfile x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteFieldLevelEncryptionProfile x
-> DeleteFieldLevelEncryptionProfile
$cfrom :: forall x.
DeleteFieldLevelEncryptionProfile
-> Rep DeleteFieldLevelEncryptionProfile x
Prelude.Generic)
newDeleteFieldLevelEncryptionProfile ::
Prelude.Text ->
DeleteFieldLevelEncryptionProfile
newDeleteFieldLevelEncryptionProfile :: Text -> DeleteFieldLevelEncryptionProfile
newDeleteFieldLevelEncryptionProfile Text
pId_ =
DeleteFieldLevelEncryptionProfile' :: Maybe Text -> Text -> DeleteFieldLevelEncryptionProfile
DeleteFieldLevelEncryptionProfile'
{ $sel:ifMatch:DeleteFieldLevelEncryptionProfile' :: Maybe Text
ifMatch =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:id:DeleteFieldLevelEncryptionProfile' :: Text
id = Text
pId_
}
deleteFieldLevelEncryptionProfile_ifMatch :: Lens.Lens' DeleteFieldLevelEncryptionProfile (Prelude.Maybe Prelude.Text)
deleteFieldLevelEncryptionProfile_ifMatch :: (Maybe Text -> f (Maybe Text))
-> DeleteFieldLevelEncryptionProfile
-> f DeleteFieldLevelEncryptionProfile
deleteFieldLevelEncryptionProfile_ifMatch = (DeleteFieldLevelEncryptionProfile -> Maybe Text)
-> (DeleteFieldLevelEncryptionProfile
-> Maybe Text -> DeleteFieldLevelEncryptionProfile)
-> Lens
DeleteFieldLevelEncryptionProfile
DeleteFieldLevelEncryptionProfile
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteFieldLevelEncryptionProfile' {Maybe Text
ifMatch :: Maybe Text
$sel:ifMatch:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Maybe Text
ifMatch} -> Maybe Text
ifMatch) (\s :: DeleteFieldLevelEncryptionProfile
s@DeleteFieldLevelEncryptionProfile' {} Maybe Text
a -> DeleteFieldLevelEncryptionProfile
s {$sel:ifMatch:DeleteFieldLevelEncryptionProfile' :: Maybe Text
ifMatch = Maybe Text
a} :: DeleteFieldLevelEncryptionProfile)
deleteFieldLevelEncryptionProfile_id :: Lens.Lens' DeleteFieldLevelEncryptionProfile Prelude.Text
deleteFieldLevelEncryptionProfile_id :: (Text -> f Text)
-> DeleteFieldLevelEncryptionProfile
-> f DeleteFieldLevelEncryptionProfile
deleteFieldLevelEncryptionProfile_id = (DeleteFieldLevelEncryptionProfile -> Text)
-> (DeleteFieldLevelEncryptionProfile
-> Text -> DeleteFieldLevelEncryptionProfile)
-> Lens
DeleteFieldLevelEncryptionProfile
DeleteFieldLevelEncryptionProfile
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteFieldLevelEncryptionProfile' {Text
id :: Text
$sel:id:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Text
id} -> Text
id) (\s :: DeleteFieldLevelEncryptionProfile
s@DeleteFieldLevelEncryptionProfile' {} Text
a -> DeleteFieldLevelEncryptionProfile
s {$sel:id:DeleteFieldLevelEncryptionProfile' :: Text
id = Text
a} :: DeleteFieldLevelEncryptionProfile)
instance
Core.AWSRequest
DeleteFieldLevelEncryptionProfile
where
type
AWSResponse DeleteFieldLevelEncryptionProfile =
DeleteFieldLevelEncryptionProfileResponse
request :: DeleteFieldLevelEncryptionProfile
-> Request DeleteFieldLevelEncryptionProfile
request = Service
-> DeleteFieldLevelEncryptionProfile
-> Request DeleteFieldLevelEncryptionProfile
forall a. ToRequest a => Service -> a -> Request a
Request.delete Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteFieldLevelEncryptionProfile
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse DeleteFieldLevelEncryptionProfile)))
response =
AWSResponse DeleteFieldLevelEncryptionProfile
-> Logger
-> Service
-> Proxy DeleteFieldLevelEncryptionProfile
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse DeleteFieldLevelEncryptionProfile)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
AWSResponse DeleteFieldLevelEncryptionProfile
DeleteFieldLevelEncryptionProfileResponse
DeleteFieldLevelEncryptionProfileResponse'
instance
Prelude.Hashable
DeleteFieldLevelEncryptionProfile
instance
Prelude.NFData
DeleteFieldLevelEncryptionProfile
instance
Core.ToHeaders
DeleteFieldLevelEncryptionProfile
where
toHeaders :: DeleteFieldLevelEncryptionProfile -> [Header]
toHeaders DeleteFieldLevelEncryptionProfile' {Maybe Text
Text
id :: Text
ifMatch :: Maybe Text
$sel:id:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Text
$sel:ifMatch:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Maybe Text
..} =
[[Header]] -> [Header]
forall a. Monoid a => [a] -> a
Prelude.mconcat [HeaderName
"If-Match" HeaderName -> Maybe Text -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# Maybe Text
ifMatch]
instance
Core.ToPath
DeleteFieldLevelEncryptionProfile
where
toPath :: DeleteFieldLevelEncryptionProfile -> ByteString
toPath DeleteFieldLevelEncryptionProfile' {Maybe Text
Text
id :: Text
ifMatch :: Maybe Text
$sel:id:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Text
$sel:ifMatch:DeleteFieldLevelEncryptionProfile' :: DeleteFieldLevelEncryptionProfile -> Maybe Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/2020-05-31/field-level-encryption-profile/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
id
]
instance
Core.ToQuery
DeleteFieldLevelEncryptionProfile
where
toQuery :: DeleteFieldLevelEncryptionProfile -> QueryString
toQuery = QueryString -> DeleteFieldLevelEncryptionProfile -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DeleteFieldLevelEncryptionProfileResponse = DeleteFieldLevelEncryptionProfileResponse'
{
}
deriving (DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool
(DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool)
-> (DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool)
-> Eq DeleteFieldLevelEncryptionProfileResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool
$c/= :: DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool
== :: DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool
$c== :: DeleteFieldLevelEncryptionProfileResponse
-> DeleteFieldLevelEncryptionProfileResponse -> Bool
Prelude.Eq, ReadPrec [DeleteFieldLevelEncryptionProfileResponse]
ReadPrec DeleteFieldLevelEncryptionProfileResponse
Int -> ReadS DeleteFieldLevelEncryptionProfileResponse
ReadS [DeleteFieldLevelEncryptionProfileResponse]
(Int -> ReadS DeleteFieldLevelEncryptionProfileResponse)
-> ReadS [DeleteFieldLevelEncryptionProfileResponse]
-> ReadPrec DeleteFieldLevelEncryptionProfileResponse
-> ReadPrec [DeleteFieldLevelEncryptionProfileResponse]
-> Read DeleteFieldLevelEncryptionProfileResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteFieldLevelEncryptionProfileResponse]
$creadListPrec :: ReadPrec [DeleteFieldLevelEncryptionProfileResponse]
readPrec :: ReadPrec DeleteFieldLevelEncryptionProfileResponse
$creadPrec :: ReadPrec DeleteFieldLevelEncryptionProfileResponse
readList :: ReadS [DeleteFieldLevelEncryptionProfileResponse]
$creadList :: ReadS [DeleteFieldLevelEncryptionProfileResponse]
readsPrec :: Int -> ReadS DeleteFieldLevelEncryptionProfileResponse
$creadsPrec :: Int -> ReadS DeleteFieldLevelEncryptionProfileResponse
Prelude.Read, Int -> DeleteFieldLevelEncryptionProfileResponse -> ShowS
[DeleteFieldLevelEncryptionProfileResponse] -> ShowS
DeleteFieldLevelEncryptionProfileResponse -> String
(Int -> DeleteFieldLevelEncryptionProfileResponse -> ShowS)
-> (DeleteFieldLevelEncryptionProfileResponse -> String)
-> ([DeleteFieldLevelEncryptionProfileResponse] -> ShowS)
-> Show DeleteFieldLevelEncryptionProfileResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteFieldLevelEncryptionProfileResponse] -> ShowS
$cshowList :: [DeleteFieldLevelEncryptionProfileResponse] -> ShowS
show :: DeleteFieldLevelEncryptionProfileResponse -> String
$cshow :: DeleteFieldLevelEncryptionProfileResponse -> String
showsPrec :: Int -> DeleteFieldLevelEncryptionProfileResponse -> ShowS
$cshowsPrec :: Int -> DeleteFieldLevelEncryptionProfileResponse -> ShowS
Prelude.Show, (forall x.
DeleteFieldLevelEncryptionProfileResponse
-> Rep DeleteFieldLevelEncryptionProfileResponse x)
-> (forall x.
Rep DeleteFieldLevelEncryptionProfileResponse x
-> DeleteFieldLevelEncryptionProfileResponse)
-> Generic DeleteFieldLevelEncryptionProfileResponse
forall x.
Rep DeleteFieldLevelEncryptionProfileResponse x
-> DeleteFieldLevelEncryptionProfileResponse
forall x.
DeleteFieldLevelEncryptionProfileResponse
-> Rep DeleteFieldLevelEncryptionProfileResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteFieldLevelEncryptionProfileResponse x
-> DeleteFieldLevelEncryptionProfileResponse
$cfrom :: forall x.
DeleteFieldLevelEncryptionProfileResponse
-> Rep DeleteFieldLevelEncryptionProfileResponse x
Prelude.Generic)
newDeleteFieldLevelEncryptionProfileResponse ::
DeleteFieldLevelEncryptionProfileResponse
newDeleteFieldLevelEncryptionProfileResponse :: DeleteFieldLevelEncryptionProfileResponse
newDeleteFieldLevelEncryptionProfileResponse =
DeleteFieldLevelEncryptionProfileResponse
DeleteFieldLevelEncryptionProfileResponse'
instance
Prelude.NFData
DeleteFieldLevelEncryptionProfileResponse