{-# 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.Transcribe.DeleteVocabularyFilter
(
DeleteVocabularyFilter (..),
newDeleteVocabularyFilter,
deleteVocabularyFilter_vocabularyFilterName,
DeleteVocabularyFilterResponse (..),
newDeleteVocabularyFilterResponse,
)
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.Transcribe.Types
data DeleteVocabularyFilter = DeleteVocabularyFilter'
{
DeleteVocabularyFilter -> Text
vocabularyFilterName :: Prelude.Text
}
deriving (DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool
(DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool)
-> (DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool)
-> Eq DeleteVocabularyFilter
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool
$c/= :: DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool
== :: DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool
$c== :: DeleteVocabularyFilter -> DeleteVocabularyFilter -> Bool
Prelude.Eq, ReadPrec [DeleteVocabularyFilter]
ReadPrec DeleteVocabularyFilter
Int -> ReadS DeleteVocabularyFilter
ReadS [DeleteVocabularyFilter]
(Int -> ReadS DeleteVocabularyFilter)
-> ReadS [DeleteVocabularyFilter]
-> ReadPrec DeleteVocabularyFilter
-> ReadPrec [DeleteVocabularyFilter]
-> Read DeleteVocabularyFilter
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteVocabularyFilter]
$creadListPrec :: ReadPrec [DeleteVocabularyFilter]
readPrec :: ReadPrec DeleteVocabularyFilter
$creadPrec :: ReadPrec DeleteVocabularyFilter
readList :: ReadS [DeleteVocabularyFilter]
$creadList :: ReadS [DeleteVocabularyFilter]
readsPrec :: Int -> ReadS DeleteVocabularyFilter
$creadsPrec :: Int -> ReadS DeleteVocabularyFilter
Prelude.Read, Int -> DeleteVocabularyFilter -> ShowS
[DeleteVocabularyFilter] -> ShowS
DeleteVocabularyFilter -> String
(Int -> DeleteVocabularyFilter -> ShowS)
-> (DeleteVocabularyFilter -> String)
-> ([DeleteVocabularyFilter] -> ShowS)
-> Show DeleteVocabularyFilter
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteVocabularyFilter] -> ShowS
$cshowList :: [DeleteVocabularyFilter] -> ShowS
show :: DeleteVocabularyFilter -> String
$cshow :: DeleteVocabularyFilter -> String
showsPrec :: Int -> DeleteVocabularyFilter -> ShowS
$cshowsPrec :: Int -> DeleteVocabularyFilter -> ShowS
Prelude.Show, (forall x. DeleteVocabularyFilter -> Rep DeleteVocabularyFilter x)
-> (forall x.
Rep DeleteVocabularyFilter x -> DeleteVocabularyFilter)
-> Generic DeleteVocabularyFilter
forall x. Rep DeleteVocabularyFilter x -> DeleteVocabularyFilter
forall x. DeleteVocabularyFilter -> Rep DeleteVocabularyFilter x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteVocabularyFilter x -> DeleteVocabularyFilter
$cfrom :: forall x. DeleteVocabularyFilter -> Rep DeleteVocabularyFilter x
Prelude.Generic)
newDeleteVocabularyFilter ::
Prelude.Text ->
DeleteVocabularyFilter
newDeleteVocabularyFilter :: Text -> DeleteVocabularyFilter
newDeleteVocabularyFilter Text
pVocabularyFilterName_ =
DeleteVocabularyFilter' :: Text -> DeleteVocabularyFilter
DeleteVocabularyFilter'
{ $sel:vocabularyFilterName:DeleteVocabularyFilter' :: Text
vocabularyFilterName =
Text
pVocabularyFilterName_
}
deleteVocabularyFilter_vocabularyFilterName :: Lens.Lens' DeleteVocabularyFilter Prelude.Text
deleteVocabularyFilter_vocabularyFilterName :: (Text -> f Text)
-> DeleteVocabularyFilter -> f DeleteVocabularyFilter
deleteVocabularyFilter_vocabularyFilterName = (DeleteVocabularyFilter -> Text)
-> (DeleteVocabularyFilter -> Text -> DeleteVocabularyFilter)
-> Lens DeleteVocabularyFilter DeleteVocabularyFilter Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteVocabularyFilter' {Text
vocabularyFilterName :: Text
$sel:vocabularyFilterName:DeleteVocabularyFilter' :: DeleteVocabularyFilter -> Text
vocabularyFilterName} -> Text
vocabularyFilterName) (\s :: DeleteVocabularyFilter
s@DeleteVocabularyFilter' {} Text
a -> DeleteVocabularyFilter
s {$sel:vocabularyFilterName:DeleteVocabularyFilter' :: Text
vocabularyFilterName = Text
a} :: DeleteVocabularyFilter)
instance Core.AWSRequest DeleteVocabularyFilter where
type
AWSResponse DeleteVocabularyFilter =
DeleteVocabularyFilterResponse
request :: DeleteVocabularyFilter -> Request DeleteVocabularyFilter
request = Service -> DeleteVocabularyFilter -> Request DeleteVocabularyFilter
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteVocabularyFilter
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteVocabularyFilter)))
response =
AWSResponse DeleteVocabularyFilter
-> Logger
-> Service
-> Proxy DeleteVocabularyFilter
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteVocabularyFilter)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
AWSResponse DeleteVocabularyFilter
DeleteVocabularyFilterResponse
DeleteVocabularyFilterResponse'
instance Prelude.Hashable DeleteVocabularyFilter
instance Prelude.NFData DeleteVocabularyFilter
instance Core.ToHeaders DeleteVocabularyFilter where
toHeaders :: DeleteVocabularyFilter -> [Header]
toHeaders =
[Header] -> DeleteVocabularyFilter -> [Header]
forall a b. a -> b -> a
Prelude.const
( [[Header]] -> [Header]
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# ( ByteString
"Transcribe.DeleteVocabularyFilter" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> [Header]
forall a. ToHeader a => HeaderName -> a -> [Header]
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON DeleteVocabularyFilter where
toJSON :: DeleteVocabularyFilter -> Value
toJSON DeleteVocabularyFilter' {Text
vocabularyFilterName :: Text
$sel:vocabularyFilterName:DeleteVocabularyFilter' :: DeleteVocabularyFilter -> Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just
( Text
"VocabularyFilterName"
Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
vocabularyFilterName
)
]
)
instance Core.ToPath DeleteVocabularyFilter where
toPath :: DeleteVocabularyFilter -> ByteString
toPath = ByteString -> DeleteVocabularyFilter -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery DeleteVocabularyFilter where
toQuery :: DeleteVocabularyFilter -> QueryString
toQuery = QueryString -> DeleteVocabularyFilter -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DeleteVocabularyFilterResponse = DeleteVocabularyFilterResponse'
{
}
deriving (DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool
(DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool)
-> (DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool)
-> Eq DeleteVocabularyFilterResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool
$c/= :: DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool
== :: DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool
$c== :: DeleteVocabularyFilterResponse
-> DeleteVocabularyFilterResponse -> Bool
Prelude.Eq, ReadPrec [DeleteVocabularyFilterResponse]
ReadPrec DeleteVocabularyFilterResponse
Int -> ReadS DeleteVocabularyFilterResponse
ReadS [DeleteVocabularyFilterResponse]
(Int -> ReadS DeleteVocabularyFilterResponse)
-> ReadS [DeleteVocabularyFilterResponse]
-> ReadPrec DeleteVocabularyFilterResponse
-> ReadPrec [DeleteVocabularyFilterResponse]
-> Read DeleteVocabularyFilterResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteVocabularyFilterResponse]
$creadListPrec :: ReadPrec [DeleteVocabularyFilterResponse]
readPrec :: ReadPrec DeleteVocabularyFilterResponse
$creadPrec :: ReadPrec DeleteVocabularyFilterResponse
readList :: ReadS [DeleteVocabularyFilterResponse]
$creadList :: ReadS [DeleteVocabularyFilterResponse]
readsPrec :: Int -> ReadS DeleteVocabularyFilterResponse
$creadsPrec :: Int -> ReadS DeleteVocabularyFilterResponse
Prelude.Read, Int -> DeleteVocabularyFilterResponse -> ShowS
[DeleteVocabularyFilterResponse] -> ShowS
DeleteVocabularyFilterResponse -> String
(Int -> DeleteVocabularyFilterResponse -> ShowS)
-> (DeleteVocabularyFilterResponse -> String)
-> ([DeleteVocabularyFilterResponse] -> ShowS)
-> Show DeleteVocabularyFilterResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteVocabularyFilterResponse] -> ShowS
$cshowList :: [DeleteVocabularyFilterResponse] -> ShowS
show :: DeleteVocabularyFilterResponse -> String
$cshow :: DeleteVocabularyFilterResponse -> String
showsPrec :: Int -> DeleteVocabularyFilterResponse -> ShowS
$cshowsPrec :: Int -> DeleteVocabularyFilterResponse -> ShowS
Prelude.Show, (forall x.
DeleteVocabularyFilterResponse
-> Rep DeleteVocabularyFilterResponse x)
-> (forall x.
Rep DeleteVocabularyFilterResponse x
-> DeleteVocabularyFilterResponse)
-> Generic DeleteVocabularyFilterResponse
forall x.
Rep DeleteVocabularyFilterResponse x
-> DeleteVocabularyFilterResponse
forall x.
DeleteVocabularyFilterResponse
-> Rep DeleteVocabularyFilterResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteVocabularyFilterResponse x
-> DeleteVocabularyFilterResponse
$cfrom :: forall x.
DeleteVocabularyFilterResponse
-> Rep DeleteVocabularyFilterResponse x
Prelude.Generic)
newDeleteVocabularyFilterResponse ::
DeleteVocabularyFilterResponse
newDeleteVocabularyFilterResponse :: DeleteVocabularyFilterResponse
newDeleteVocabularyFilterResponse =
DeleteVocabularyFilterResponse
DeleteVocabularyFilterResponse'
instance
Prelude.NFData
DeleteVocabularyFilterResponse