{-# 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.Route53.DeleteQueryLoggingConfig
(
DeleteQueryLoggingConfig (..),
newDeleteQueryLoggingConfig,
deleteQueryLoggingConfig_id,
DeleteQueryLoggingConfigResponse (..),
newDeleteQueryLoggingConfigResponse,
deleteQueryLoggingConfigResponse_httpStatus,
)
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 qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
import Amazonka.Route53.Types
data DeleteQueryLoggingConfig = DeleteQueryLoggingConfig'
{
DeleteQueryLoggingConfig -> Text
id :: Prelude.Text
}
deriving (DeleteQueryLoggingConfig -> DeleteQueryLoggingConfig -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteQueryLoggingConfig -> DeleteQueryLoggingConfig -> Bool
$c/= :: DeleteQueryLoggingConfig -> DeleteQueryLoggingConfig -> Bool
== :: DeleteQueryLoggingConfig -> DeleteQueryLoggingConfig -> Bool
$c== :: DeleteQueryLoggingConfig -> DeleteQueryLoggingConfig -> Bool
Prelude.Eq, ReadPrec [DeleteQueryLoggingConfig]
ReadPrec DeleteQueryLoggingConfig
Int -> ReadS DeleteQueryLoggingConfig
ReadS [DeleteQueryLoggingConfig]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteQueryLoggingConfig]
$creadListPrec :: ReadPrec [DeleteQueryLoggingConfig]
readPrec :: ReadPrec DeleteQueryLoggingConfig
$creadPrec :: ReadPrec DeleteQueryLoggingConfig
readList :: ReadS [DeleteQueryLoggingConfig]
$creadList :: ReadS [DeleteQueryLoggingConfig]
readsPrec :: Int -> ReadS DeleteQueryLoggingConfig
$creadsPrec :: Int -> ReadS DeleteQueryLoggingConfig
Prelude.Read, Int -> DeleteQueryLoggingConfig -> ShowS
[DeleteQueryLoggingConfig] -> ShowS
DeleteQueryLoggingConfig -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteQueryLoggingConfig] -> ShowS
$cshowList :: [DeleteQueryLoggingConfig] -> ShowS
show :: DeleteQueryLoggingConfig -> String
$cshow :: DeleteQueryLoggingConfig -> String
showsPrec :: Int -> DeleteQueryLoggingConfig -> ShowS
$cshowsPrec :: Int -> DeleteQueryLoggingConfig -> ShowS
Prelude.Show, forall x.
Rep DeleteQueryLoggingConfig x -> DeleteQueryLoggingConfig
forall x.
DeleteQueryLoggingConfig -> Rep DeleteQueryLoggingConfig x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteQueryLoggingConfig x -> DeleteQueryLoggingConfig
$cfrom :: forall x.
DeleteQueryLoggingConfig -> Rep DeleteQueryLoggingConfig x
Prelude.Generic)
newDeleteQueryLoggingConfig ::
Prelude.Text ->
DeleteQueryLoggingConfig
newDeleteQueryLoggingConfig :: Text -> DeleteQueryLoggingConfig
newDeleteQueryLoggingConfig Text
pId_ =
DeleteQueryLoggingConfig' {$sel:id:DeleteQueryLoggingConfig' :: Text
id = Text
pId_}
deleteQueryLoggingConfig_id :: Lens.Lens' DeleteQueryLoggingConfig Prelude.Text
deleteQueryLoggingConfig_id :: Lens' DeleteQueryLoggingConfig Text
deleteQueryLoggingConfig_id = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteQueryLoggingConfig' {Text
id :: Text
$sel:id:DeleteQueryLoggingConfig' :: DeleteQueryLoggingConfig -> Text
id} -> Text
id) (\s :: DeleteQueryLoggingConfig
s@DeleteQueryLoggingConfig' {} Text
a -> DeleteQueryLoggingConfig
s {$sel:id:DeleteQueryLoggingConfig' :: Text
id = Text
a} :: DeleteQueryLoggingConfig)
instance Core.AWSRequest DeleteQueryLoggingConfig where
type
AWSResponse DeleteQueryLoggingConfig =
DeleteQueryLoggingConfigResponse
request :: (Service -> Service)
-> DeleteQueryLoggingConfig -> Request DeleteQueryLoggingConfig
request Service -> Service
overrides =
forall a. ToRequest a => Service -> a -> Request a
Request.delete (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy DeleteQueryLoggingConfig
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteQueryLoggingConfig)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> () -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveEmpty
( \Int
s ResponseHeaders
h ()
x ->
Int -> DeleteQueryLoggingConfigResponse
DeleteQueryLoggingConfigResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable DeleteQueryLoggingConfig where
hashWithSalt :: Int -> DeleteQueryLoggingConfig -> Int
hashWithSalt Int
_salt DeleteQueryLoggingConfig' {Text
id :: Text
$sel:id:DeleteQueryLoggingConfig' :: DeleteQueryLoggingConfig -> Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
id
instance Prelude.NFData DeleteQueryLoggingConfig where
rnf :: DeleteQueryLoggingConfig -> ()
rnf DeleteQueryLoggingConfig' {Text
id :: Text
$sel:id:DeleteQueryLoggingConfig' :: DeleteQueryLoggingConfig -> Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Text
id
instance Data.ToHeaders DeleteQueryLoggingConfig where
toHeaders :: DeleteQueryLoggingConfig -> ResponseHeaders
toHeaders = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
instance Data.ToPath DeleteQueryLoggingConfig where
toPath :: DeleteQueryLoggingConfig -> ByteString
toPath DeleteQueryLoggingConfig' {Text
id :: Text
$sel:id:DeleteQueryLoggingConfig' :: DeleteQueryLoggingConfig -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ByteString
"/2013-04-01/queryloggingconfig/", forall a. ToByteString a => a -> ByteString
Data.toBS Text
id]
instance Data.ToQuery DeleteQueryLoggingConfig where
toQuery :: DeleteQueryLoggingConfig -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DeleteQueryLoggingConfigResponse = DeleteQueryLoggingConfigResponse'
{
DeleteQueryLoggingConfigResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DeleteQueryLoggingConfigResponse
-> DeleteQueryLoggingConfigResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteQueryLoggingConfigResponse
-> DeleteQueryLoggingConfigResponse -> Bool
$c/= :: DeleteQueryLoggingConfigResponse
-> DeleteQueryLoggingConfigResponse -> Bool
== :: DeleteQueryLoggingConfigResponse
-> DeleteQueryLoggingConfigResponse -> Bool
$c== :: DeleteQueryLoggingConfigResponse
-> DeleteQueryLoggingConfigResponse -> Bool
Prelude.Eq, ReadPrec [DeleteQueryLoggingConfigResponse]
ReadPrec DeleteQueryLoggingConfigResponse
Int -> ReadS DeleteQueryLoggingConfigResponse
ReadS [DeleteQueryLoggingConfigResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteQueryLoggingConfigResponse]
$creadListPrec :: ReadPrec [DeleteQueryLoggingConfigResponse]
readPrec :: ReadPrec DeleteQueryLoggingConfigResponse
$creadPrec :: ReadPrec DeleteQueryLoggingConfigResponse
readList :: ReadS [DeleteQueryLoggingConfigResponse]
$creadList :: ReadS [DeleteQueryLoggingConfigResponse]
readsPrec :: Int -> ReadS DeleteQueryLoggingConfigResponse
$creadsPrec :: Int -> ReadS DeleteQueryLoggingConfigResponse
Prelude.Read, Int -> DeleteQueryLoggingConfigResponse -> ShowS
[DeleteQueryLoggingConfigResponse] -> ShowS
DeleteQueryLoggingConfigResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteQueryLoggingConfigResponse] -> ShowS
$cshowList :: [DeleteQueryLoggingConfigResponse] -> ShowS
show :: DeleteQueryLoggingConfigResponse -> String
$cshow :: DeleteQueryLoggingConfigResponse -> String
showsPrec :: Int -> DeleteQueryLoggingConfigResponse -> ShowS
$cshowsPrec :: Int -> DeleteQueryLoggingConfigResponse -> ShowS
Prelude.Show, forall x.
Rep DeleteQueryLoggingConfigResponse x
-> DeleteQueryLoggingConfigResponse
forall x.
DeleteQueryLoggingConfigResponse
-> Rep DeleteQueryLoggingConfigResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteQueryLoggingConfigResponse x
-> DeleteQueryLoggingConfigResponse
$cfrom :: forall x.
DeleteQueryLoggingConfigResponse
-> Rep DeleteQueryLoggingConfigResponse x
Prelude.Generic)
newDeleteQueryLoggingConfigResponse ::
Prelude.Int ->
DeleteQueryLoggingConfigResponse
newDeleteQueryLoggingConfigResponse :: Int -> DeleteQueryLoggingConfigResponse
newDeleteQueryLoggingConfigResponse Int
pHttpStatus_ =
DeleteQueryLoggingConfigResponse'
{ $sel:httpStatus:DeleteQueryLoggingConfigResponse' :: Int
httpStatus =
Int
pHttpStatus_
}
deleteQueryLoggingConfigResponse_httpStatus :: Lens.Lens' DeleteQueryLoggingConfigResponse Prelude.Int
deleteQueryLoggingConfigResponse_httpStatus :: Lens' DeleteQueryLoggingConfigResponse Int
deleteQueryLoggingConfigResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteQueryLoggingConfigResponse' {Int
httpStatus :: Int
$sel:httpStatus:DeleteQueryLoggingConfigResponse' :: DeleteQueryLoggingConfigResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DeleteQueryLoggingConfigResponse
s@DeleteQueryLoggingConfigResponse' {} Int
a -> DeleteQueryLoggingConfigResponse
s {$sel:httpStatus:DeleteQueryLoggingConfigResponse' :: Int
httpStatus = Int
a} :: DeleteQueryLoggingConfigResponse)
instance
Prelude.NFData
DeleteQueryLoggingConfigResponse
where
rnf :: DeleteQueryLoggingConfigResponse -> ()
rnf DeleteQueryLoggingConfigResponse' {Int
httpStatus :: Int
$sel:httpStatus:DeleteQueryLoggingConfigResponse' :: DeleteQueryLoggingConfigResponse -> Int
..} =
forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus