{-# 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.SWF.UndeprecateDomain
(
UndeprecateDomain (..),
newUndeprecateDomain,
undeprecateDomain_name,
UndeprecateDomainResponse (..),
newUndeprecateDomainResponse,
)
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.SWF.Types
data UndeprecateDomain = UndeprecateDomain'
{
UndeprecateDomain -> Text
name :: Prelude.Text
}
deriving (UndeprecateDomain -> UndeprecateDomain -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UndeprecateDomain -> UndeprecateDomain -> Bool
$c/= :: UndeprecateDomain -> UndeprecateDomain -> Bool
== :: UndeprecateDomain -> UndeprecateDomain -> Bool
$c== :: UndeprecateDomain -> UndeprecateDomain -> Bool
Prelude.Eq, ReadPrec [UndeprecateDomain]
ReadPrec UndeprecateDomain
Int -> ReadS UndeprecateDomain
ReadS [UndeprecateDomain]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UndeprecateDomain]
$creadListPrec :: ReadPrec [UndeprecateDomain]
readPrec :: ReadPrec UndeprecateDomain
$creadPrec :: ReadPrec UndeprecateDomain
readList :: ReadS [UndeprecateDomain]
$creadList :: ReadS [UndeprecateDomain]
readsPrec :: Int -> ReadS UndeprecateDomain
$creadsPrec :: Int -> ReadS UndeprecateDomain
Prelude.Read, Int -> UndeprecateDomain -> ShowS
[UndeprecateDomain] -> ShowS
UndeprecateDomain -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UndeprecateDomain] -> ShowS
$cshowList :: [UndeprecateDomain] -> ShowS
show :: UndeprecateDomain -> String
$cshow :: UndeprecateDomain -> String
showsPrec :: Int -> UndeprecateDomain -> ShowS
$cshowsPrec :: Int -> UndeprecateDomain -> ShowS
Prelude.Show, forall x. Rep UndeprecateDomain x -> UndeprecateDomain
forall x. UndeprecateDomain -> Rep UndeprecateDomain x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UndeprecateDomain x -> UndeprecateDomain
$cfrom :: forall x. UndeprecateDomain -> Rep UndeprecateDomain x
Prelude.Generic)
newUndeprecateDomain ::
Prelude.Text ->
UndeprecateDomain
newUndeprecateDomain :: Text -> UndeprecateDomain
newUndeprecateDomain Text
pName_ =
UndeprecateDomain' {$sel:name:UndeprecateDomain' :: Text
name = Text
pName_}
undeprecateDomain_name :: Lens.Lens' UndeprecateDomain Prelude.Text
undeprecateDomain_name :: Lens' UndeprecateDomain Text
undeprecateDomain_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UndeprecateDomain' {Text
name :: Text
$sel:name:UndeprecateDomain' :: UndeprecateDomain -> Text
name} -> Text
name) (\s :: UndeprecateDomain
s@UndeprecateDomain' {} Text
a -> UndeprecateDomain
s {$sel:name:UndeprecateDomain' :: Text
name = Text
a} :: UndeprecateDomain)
instance Core.AWSRequest UndeprecateDomain where
type
AWSResponse UndeprecateDomain =
UndeprecateDomainResponse
request :: (Service -> Service)
-> UndeprecateDomain -> Request UndeprecateDomain
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy UndeprecateDomain
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UndeprecateDomain)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull UndeprecateDomainResponse
UndeprecateDomainResponse'
instance Prelude.Hashable UndeprecateDomain where
hashWithSalt :: Int -> UndeprecateDomain -> Int
hashWithSalt Int
_salt UndeprecateDomain' {Text
name :: Text
$sel:name:UndeprecateDomain' :: UndeprecateDomain -> Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
instance Prelude.NFData UndeprecateDomain where
rnf :: UndeprecateDomain -> ()
rnf UndeprecateDomain' {Text
name :: Text
$sel:name:UndeprecateDomain' :: UndeprecateDomain -> Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Text
name
instance Data.ToHeaders UndeprecateDomain where
toHeaders :: UndeprecateDomain -> [Header]
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# ( ByteString
"SimpleWorkflowService.UndeprecateDomain" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# ( ByteString
"application/x-amz-json-1.0" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON UndeprecateDomain where
toJSON :: UndeprecateDomain -> Value
toJSON UndeprecateDomain' {Text
name :: Text
$sel:name:UndeprecateDomain' :: UndeprecateDomain -> Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[forall a. a -> Maybe a
Prelude.Just (Key
"name" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
name)]
)
instance Data.ToPath UndeprecateDomain where
toPath :: UndeprecateDomain -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery UndeprecateDomain where
toQuery :: UndeprecateDomain -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data UndeprecateDomainResponse = UndeprecateDomainResponse'
{
}
deriving (UndeprecateDomainResponse -> UndeprecateDomainResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UndeprecateDomainResponse -> UndeprecateDomainResponse -> Bool
$c/= :: UndeprecateDomainResponse -> UndeprecateDomainResponse -> Bool
== :: UndeprecateDomainResponse -> UndeprecateDomainResponse -> Bool
$c== :: UndeprecateDomainResponse -> UndeprecateDomainResponse -> Bool
Prelude.Eq, ReadPrec [UndeprecateDomainResponse]
ReadPrec UndeprecateDomainResponse
Int -> ReadS UndeprecateDomainResponse
ReadS [UndeprecateDomainResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UndeprecateDomainResponse]
$creadListPrec :: ReadPrec [UndeprecateDomainResponse]
readPrec :: ReadPrec UndeprecateDomainResponse
$creadPrec :: ReadPrec UndeprecateDomainResponse
readList :: ReadS [UndeprecateDomainResponse]
$creadList :: ReadS [UndeprecateDomainResponse]
readsPrec :: Int -> ReadS UndeprecateDomainResponse
$creadsPrec :: Int -> ReadS UndeprecateDomainResponse
Prelude.Read, Int -> UndeprecateDomainResponse -> ShowS
[UndeprecateDomainResponse] -> ShowS
UndeprecateDomainResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UndeprecateDomainResponse] -> ShowS
$cshowList :: [UndeprecateDomainResponse] -> ShowS
show :: UndeprecateDomainResponse -> String
$cshow :: UndeprecateDomainResponse -> String
showsPrec :: Int -> UndeprecateDomainResponse -> ShowS
$cshowsPrec :: Int -> UndeprecateDomainResponse -> ShowS
Prelude.Show, forall x.
Rep UndeprecateDomainResponse x -> UndeprecateDomainResponse
forall x.
UndeprecateDomainResponse -> Rep UndeprecateDomainResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UndeprecateDomainResponse x -> UndeprecateDomainResponse
$cfrom :: forall x.
UndeprecateDomainResponse -> Rep UndeprecateDomainResponse x
Prelude.Generic)
newUndeprecateDomainResponse ::
UndeprecateDomainResponse
newUndeprecateDomainResponse :: UndeprecateDomainResponse
newUndeprecateDomainResponse =
UndeprecateDomainResponse
UndeprecateDomainResponse'
instance Prelude.NFData UndeprecateDomainResponse where
rnf :: UndeprecateDomainResponse -> ()
rnf UndeprecateDomainResponse
_ = ()