{-# 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.APIGateway.DeleteVpcLink
(
DeleteVpcLink (..),
newDeleteVpcLink,
deleteVpcLink_vpcLinkId,
DeleteVpcLinkResponse (..),
newDeleteVpcLinkResponse,
)
where
import Amazonka.APIGateway.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 DeleteVpcLink = DeleteVpcLink'
{
DeleteVpcLink -> Text
vpcLinkId :: Prelude.Text
}
deriving (DeleteVpcLink -> DeleteVpcLink -> Bool
(DeleteVpcLink -> DeleteVpcLink -> Bool)
-> (DeleteVpcLink -> DeleteVpcLink -> Bool) -> Eq DeleteVpcLink
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteVpcLink -> DeleteVpcLink -> Bool
$c/= :: DeleteVpcLink -> DeleteVpcLink -> Bool
== :: DeleteVpcLink -> DeleteVpcLink -> Bool
$c== :: DeleteVpcLink -> DeleteVpcLink -> Bool
Prelude.Eq, ReadPrec [DeleteVpcLink]
ReadPrec DeleteVpcLink
Int -> ReadS DeleteVpcLink
ReadS [DeleteVpcLink]
(Int -> ReadS DeleteVpcLink)
-> ReadS [DeleteVpcLink]
-> ReadPrec DeleteVpcLink
-> ReadPrec [DeleteVpcLink]
-> Read DeleteVpcLink
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteVpcLink]
$creadListPrec :: ReadPrec [DeleteVpcLink]
readPrec :: ReadPrec DeleteVpcLink
$creadPrec :: ReadPrec DeleteVpcLink
readList :: ReadS [DeleteVpcLink]
$creadList :: ReadS [DeleteVpcLink]
readsPrec :: Int -> ReadS DeleteVpcLink
$creadsPrec :: Int -> ReadS DeleteVpcLink
Prelude.Read, Int -> DeleteVpcLink -> ShowS
[DeleteVpcLink] -> ShowS
DeleteVpcLink -> String
(Int -> DeleteVpcLink -> ShowS)
-> (DeleteVpcLink -> String)
-> ([DeleteVpcLink] -> ShowS)
-> Show DeleteVpcLink
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteVpcLink] -> ShowS
$cshowList :: [DeleteVpcLink] -> ShowS
show :: DeleteVpcLink -> String
$cshow :: DeleteVpcLink -> String
showsPrec :: Int -> DeleteVpcLink -> ShowS
$cshowsPrec :: Int -> DeleteVpcLink -> ShowS
Prelude.Show, (forall x. DeleteVpcLink -> Rep DeleteVpcLink x)
-> (forall x. Rep DeleteVpcLink x -> DeleteVpcLink)
-> Generic DeleteVpcLink
forall x. Rep DeleteVpcLink x -> DeleteVpcLink
forall x. DeleteVpcLink -> Rep DeleteVpcLink x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteVpcLink x -> DeleteVpcLink
$cfrom :: forall x. DeleteVpcLink -> Rep DeleteVpcLink x
Prelude.Generic)
newDeleteVpcLink ::
Prelude.Text ->
DeleteVpcLink
newDeleteVpcLink :: Text -> DeleteVpcLink
newDeleteVpcLink Text
pVpcLinkId_ =
DeleteVpcLink' :: Text -> DeleteVpcLink
DeleteVpcLink' {$sel:vpcLinkId:DeleteVpcLink' :: Text
vpcLinkId = Text
pVpcLinkId_}
deleteVpcLink_vpcLinkId :: Lens.Lens' DeleteVpcLink Prelude.Text
deleteVpcLink_vpcLinkId :: (Text -> f Text) -> DeleteVpcLink -> f DeleteVpcLink
deleteVpcLink_vpcLinkId = (DeleteVpcLink -> Text)
-> (DeleteVpcLink -> Text -> DeleteVpcLink)
-> Lens DeleteVpcLink DeleteVpcLink Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteVpcLink' {Text
vpcLinkId :: Text
$sel:vpcLinkId:DeleteVpcLink' :: DeleteVpcLink -> Text
vpcLinkId} -> Text
vpcLinkId) (\s :: DeleteVpcLink
s@DeleteVpcLink' {} Text
a -> DeleteVpcLink
s {$sel:vpcLinkId:DeleteVpcLink' :: Text
vpcLinkId = Text
a} :: DeleteVpcLink)
instance Core.AWSRequest DeleteVpcLink where
type
AWSResponse DeleteVpcLink =
DeleteVpcLinkResponse
request :: DeleteVpcLink -> Request DeleteVpcLink
request = Service -> DeleteVpcLink -> Request DeleteVpcLink
forall a. ToRequest a => Service -> a -> Request a
Request.delete Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteVpcLink
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse DeleteVpcLink)))
response =
AWSResponse DeleteVpcLink
-> Logger
-> Service
-> Proxy DeleteVpcLink
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse DeleteVpcLink)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull AWSResponse DeleteVpcLink
DeleteVpcLinkResponse
DeleteVpcLinkResponse'
instance Prelude.Hashable DeleteVpcLink
instance Prelude.NFData DeleteVpcLink
instance Core.ToHeaders DeleteVpcLink where
toHeaders :: DeleteVpcLink -> [Header]
toHeaders =
[Header] -> DeleteVpcLink -> [Header]
forall a b. a -> b -> a
Prelude.const
( [[Header]] -> [Header]
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Accept"
HeaderName -> ByteString -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# (ByteString
"application/json" :: Prelude.ByteString)
]
)
instance Core.ToPath DeleteVpcLink where
toPath :: DeleteVpcLink -> ByteString
toPath DeleteVpcLink' {Text
vpcLinkId :: Text
$sel:vpcLinkId:DeleteVpcLink' :: DeleteVpcLink -> Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"/vpclinks/", Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
vpcLinkId]
instance Core.ToQuery DeleteVpcLink where
toQuery :: DeleteVpcLink -> QueryString
toQuery = QueryString -> DeleteVpcLink -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DeleteVpcLinkResponse = DeleteVpcLinkResponse'
{
}
deriving (DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool
(DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool)
-> (DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool)
-> Eq DeleteVpcLinkResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool
$c/= :: DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool
== :: DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool
$c== :: DeleteVpcLinkResponse -> DeleteVpcLinkResponse -> Bool
Prelude.Eq, ReadPrec [DeleteVpcLinkResponse]
ReadPrec DeleteVpcLinkResponse
Int -> ReadS DeleteVpcLinkResponse
ReadS [DeleteVpcLinkResponse]
(Int -> ReadS DeleteVpcLinkResponse)
-> ReadS [DeleteVpcLinkResponse]
-> ReadPrec DeleteVpcLinkResponse
-> ReadPrec [DeleteVpcLinkResponse]
-> Read DeleteVpcLinkResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteVpcLinkResponse]
$creadListPrec :: ReadPrec [DeleteVpcLinkResponse]
readPrec :: ReadPrec DeleteVpcLinkResponse
$creadPrec :: ReadPrec DeleteVpcLinkResponse
readList :: ReadS [DeleteVpcLinkResponse]
$creadList :: ReadS [DeleteVpcLinkResponse]
readsPrec :: Int -> ReadS DeleteVpcLinkResponse
$creadsPrec :: Int -> ReadS DeleteVpcLinkResponse
Prelude.Read, Int -> DeleteVpcLinkResponse -> ShowS
[DeleteVpcLinkResponse] -> ShowS
DeleteVpcLinkResponse -> String
(Int -> DeleteVpcLinkResponse -> ShowS)
-> (DeleteVpcLinkResponse -> String)
-> ([DeleteVpcLinkResponse] -> ShowS)
-> Show DeleteVpcLinkResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteVpcLinkResponse] -> ShowS
$cshowList :: [DeleteVpcLinkResponse] -> ShowS
show :: DeleteVpcLinkResponse -> String
$cshow :: DeleteVpcLinkResponse -> String
showsPrec :: Int -> DeleteVpcLinkResponse -> ShowS
$cshowsPrec :: Int -> DeleteVpcLinkResponse -> ShowS
Prelude.Show, (forall x. DeleteVpcLinkResponse -> Rep DeleteVpcLinkResponse x)
-> (forall x. Rep DeleteVpcLinkResponse x -> DeleteVpcLinkResponse)
-> Generic DeleteVpcLinkResponse
forall x. Rep DeleteVpcLinkResponse x -> DeleteVpcLinkResponse
forall x. DeleteVpcLinkResponse -> Rep DeleteVpcLinkResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteVpcLinkResponse x -> DeleteVpcLinkResponse
$cfrom :: forall x. DeleteVpcLinkResponse -> Rep DeleteVpcLinkResponse x
Prelude.Generic)
newDeleteVpcLinkResponse ::
DeleteVpcLinkResponse
newDeleteVpcLinkResponse :: DeleteVpcLinkResponse
newDeleteVpcLinkResponse = DeleteVpcLinkResponse
DeleteVpcLinkResponse'
instance Prelude.NFData DeleteVpcLinkResponse