{-# 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.LexModels.DeleteSlotTypeVersion
(
DeleteSlotTypeVersion (..),
newDeleteSlotTypeVersion,
deleteSlotTypeVersion_name,
deleteSlotTypeVersion_version,
DeleteSlotTypeVersionResponse (..),
newDeleteSlotTypeVersionResponse,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.LexModels.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DeleteSlotTypeVersion = DeleteSlotTypeVersion'
{
DeleteSlotTypeVersion -> Text
name :: Prelude.Text,
DeleteSlotTypeVersion -> Text
version :: Prelude.Text
}
deriving (DeleteSlotTypeVersion -> DeleteSlotTypeVersion -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteSlotTypeVersion -> DeleteSlotTypeVersion -> Bool
$c/= :: DeleteSlotTypeVersion -> DeleteSlotTypeVersion -> Bool
== :: DeleteSlotTypeVersion -> DeleteSlotTypeVersion -> Bool
$c== :: DeleteSlotTypeVersion -> DeleteSlotTypeVersion -> Bool
Prelude.Eq, ReadPrec [DeleteSlotTypeVersion]
ReadPrec DeleteSlotTypeVersion
Int -> ReadS DeleteSlotTypeVersion
ReadS [DeleteSlotTypeVersion]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteSlotTypeVersion]
$creadListPrec :: ReadPrec [DeleteSlotTypeVersion]
readPrec :: ReadPrec DeleteSlotTypeVersion
$creadPrec :: ReadPrec DeleteSlotTypeVersion
readList :: ReadS [DeleteSlotTypeVersion]
$creadList :: ReadS [DeleteSlotTypeVersion]
readsPrec :: Int -> ReadS DeleteSlotTypeVersion
$creadsPrec :: Int -> ReadS DeleteSlotTypeVersion
Prelude.Read, Int -> DeleteSlotTypeVersion -> ShowS
[DeleteSlotTypeVersion] -> ShowS
DeleteSlotTypeVersion -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteSlotTypeVersion] -> ShowS
$cshowList :: [DeleteSlotTypeVersion] -> ShowS
show :: DeleteSlotTypeVersion -> String
$cshow :: DeleteSlotTypeVersion -> String
showsPrec :: Int -> DeleteSlotTypeVersion -> ShowS
$cshowsPrec :: Int -> DeleteSlotTypeVersion -> ShowS
Prelude.Show, forall x. Rep DeleteSlotTypeVersion x -> DeleteSlotTypeVersion
forall x. DeleteSlotTypeVersion -> Rep DeleteSlotTypeVersion x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteSlotTypeVersion x -> DeleteSlotTypeVersion
$cfrom :: forall x. DeleteSlotTypeVersion -> Rep DeleteSlotTypeVersion x
Prelude.Generic)
newDeleteSlotTypeVersion ::
Prelude.Text ->
Prelude.Text ->
DeleteSlotTypeVersion
newDeleteSlotTypeVersion :: Text -> Text -> DeleteSlotTypeVersion
newDeleteSlotTypeVersion Text
pName_ Text
pVersion_ =
DeleteSlotTypeVersion'
{ $sel:name:DeleteSlotTypeVersion' :: Text
name = Text
pName_,
$sel:version:DeleteSlotTypeVersion' :: Text
version = Text
pVersion_
}
deleteSlotTypeVersion_name :: Lens.Lens' DeleteSlotTypeVersion Prelude.Text
deleteSlotTypeVersion_name :: Lens' DeleteSlotTypeVersion Text
deleteSlotTypeVersion_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteSlotTypeVersion' {Text
name :: Text
$sel:name:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
name} -> Text
name) (\s :: DeleteSlotTypeVersion
s@DeleteSlotTypeVersion' {} Text
a -> DeleteSlotTypeVersion
s {$sel:name:DeleteSlotTypeVersion' :: Text
name = Text
a} :: DeleteSlotTypeVersion)
deleteSlotTypeVersion_version :: Lens.Lens' DeleteSlotTypeVersion Prelude.Text
deleteSlotTypeVersion_version :: Lens' DeleteSlotTypeVersion Text
deleteSlotTypeVersion_version = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteSlotTypeVersion' {Text
version :: Text
$sel:version:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
version} -> Text
version) (\s :: DeleteSlotTypeVersion
s@DeleteSlotTypeVersion' {} Text
a -> DeleteSlotTypeVersion
s {$sel:version:DeleteSlotTypeVersion' :: Text
version = Text
a} :: DeleteSlotTypeVersion)
instance Core.AWSRequest DeleteSlotTypeVersion where
type
AWSResponse DeleteSlotTypeVersion =
DeleteSlotTypeVersionResponse
request :: (Service -> Service)
-> DeleteSlotTypeVersion -> Request DeleteSlotTypeVersion
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 DeleteSlotTypeVersion
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteSlotTypeVersion)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull DeleteSlotTypeVersionResponse
DeleteSlotTypeVersionResponse'
instance Prelude.Hashable DeleteSlotTypeVersion where
hashWithSalt :: Int -> DeleteSlotTypeVersion -> Int
hashWithSalt Int
_salt DeleteSlotTypeVersion' {Text
version :: Text
name :: Text
$sel:version:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
$sel:name:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
version
instance Prelude.NFData DeleteSlotTypeVersion where
rnf :: DeleteSlotTypeVersion -> ()
rnf DeleteSlotTypeVersion' {Text
version :: Text
name :: Text
$sel:version:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
$sel:name:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
name seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
version
instance Data.ToHeaders DeleteSlotTypeVersion where
toHeaders :: DeleteSlotTypeVersion -> [Header]
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToPath DeleteSlotTypeVersion where
toPath :: DeleteSlotTypeVersion -> ByteString
toPath DeleteSlotTypeVersion' {Text
version :: Text
name :: Text
$sel:version:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
$sel:name:DeleteSlotTypeVersion' :: DeleteSlotTypeVersion -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/slottypes/",
forall a. ToByteString a => a -> ByteString
Data.toBS Text
name,
ByteString
"/version/",
forall a. ToByteString a => a -> ByteString
Data.toBS Text
version
]
instance Data.ToQuery DeleteSlotTypeVersion where
toQuery :: DeleteSlotTypeVersion -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DeleteSlotTypeVersionResponse = DeleteSlotTypeVersionResponse'
{
}
deriving (DeleteSlotTypeVersionResponse
-> DeleteSlotTypeVersionResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteSlotTypeVersionResponse
-> DeleteSlotTypeVersionResponse -> Bool
$c/= :: DeleteSlotTypeVersionResponse
-> DeleteSlotTypeVersionResponse -> Bool
== :: DeleteSlotTypeVersionResponse
-> DeleteSlotTypeVersionResponse -> Bool
$c== :: DeleteSlotTypeVersionResponse
-> DeleteSlotTypeVersionResponse -> Bool
Prelude.Eq, ReadPrec [DeleteSlotTypeVersionResponse]
ReadPrec DeleteSlotTypeVersionResponse
Int -> ReadS DeleteSlotTypeVersionResponse
ReadS [DeleteSlotTypeVersionResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteSlotTypeVersionResponse]
$creadListPrec :: ReadPrec [DeleteSlotTypeVersionResponse]
readPrec :: ReadPrec DeleteSlotTypeVersionResponse
$creadPrec :: ReadPrec DeleteSlotTypeVersionResponse
readList :: ReadS [DeleteSlotTypeVersionResponse]
$creadList :: ReadS [DeleteSlotTypeVersionResponse]
readsPrec :: Int -> ReadS DeleteSlotTypeVersionResponse
$creadsPrec :: Int -> ReadS DeleteSlotTypeVersionResponse
Prelude.Read, Int -> DeleteSlotTypeVersionResponse -> ShowS
[DeleteSlotTypeVersionResponse] -> ShowS
DeleteSlotTypeVersionResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteSlotTypeVersionResponse] -> ShowS
$cshowList :: [DeleteSlotTypeVersionResponse] -> ShowS
show :: DeleteSlotTypeVersionResponse -> String
$cshow :: DeleteSlotTypeVersionResponse -> String
showsPrec :: Int -> DeleteSlotTypeVersionResponse -> ShowS
$cshowsPrec :: Int -> DeleteSlotTypeVersionResponse -> ShowS
Prelude.Show, forall x.
Rep DeleteSlotTypeVersionResponse x
-> DeleteSlotTypeVersionResponse
forall x.
DeleteSlotTypeVersionResponse
-> Rep DeleteSlotTypeVersionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteSlotTypeVersionResponse x
-> DeleteSlotTypeVersionResponse
$cfrom :: forall x.
DeleteSlotTypeVersionResponse
-> Rep DeleteSlotTypeVersionResponse x
Prelude.Generic)
newDeleteSlotTypeVersionResponse ::
DeleteSlotTypeVersionResponse
newDeleteSlotTypeVersionResponse :: DeleteSlotTypeVersionResponse
newDeleteSlotTypeVersionResponse =
DeleteSlotTypeVersionResponse
DeleteSlotTypeVersionResponse'
instance Prelude.NFData DeleteSlotTypeVersionResponse where
rnf :: DeleteSlotTypeVersionResponse -> ()
rnf DeleteSlotTypeVersionResponse
_ = ()