{-# 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.WellArchitected.DeleteLens
(
DeleteLens (..),
newDeleteLens,
deleteLens_lensAlias,
deleteLens_clientRequestToken,
deleteLens_lensStatus,
DeleteLensResponse (..),
newDeleteLensResponse,
)
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.WellArchitected.Types
data DeleteLens = DeleteLens'
{ DeleteLens -> Text
lensAlias :: Prelude.Text,
DeleteLens -> Text
clientRequestToken :: Prelude.Text,
DeleteLens -> LensStatusType
lensStatus :: LensStatusType
}
deriving (DeleteLens -> DeleteLens -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteLens -> DeleteLens -> Bool
$c/= :: DeleteLens -> DeleteLens -> Bool
== :: DeleteLens -> DeleteLens -> Bool
$c== :: DeleteLens -> DeleteLens -> Bool
Prelude.Eq, ReadPrec [DeleteLens]
ReadPrec DeleteLens
Int -> ReadS DeleteLens
ReadS [DeleteLens]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteLens]
$creadListPrec :: ReadPrec [DeleteLens]
readPrec :: ReadPrec DeleteLens
$creadPrec :: ReadPrec DeleteLens
readList :: ReadS [DeleteLens]
$creadList :: ReadS [DeleteLens]
readsPrec :: Int -> ReadS DeleteLens
$creadsPrec :: Int -> ReadS DeleteLens
Prelude.Read, Int -> DeleteLens -> ShowS
[DeleteLens] -> ShowS
DeleteLens -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteLens] -> ShowS
$cshowList :: [DeleteLens] -> ShowS
show :: DeleteLens -> String
$cshow :: DeleteLens -> String
showsPrec :: Int -> DeleteLens -> ShowS
$cshowsPrec :: Int -> DeleteLens -> ShowS
Prelude.Show, forall x. Rep DeleteLens x -> DeleteLens
forall x. DeleteLens -> Rep DeleteLens x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteLens x -> DeleteLens
$cfrom :: forall x. DeleteLens -> Rep DeleteLens x
Prelude.Generic)
newDeleteLens ::
Prelude.Text ->
Prelude.Text ->
LensStatusType ->
DeleteLens
newDeleteLens :: Text -> Text -> LensStatusType -> DeleteLens
newDeleteLens
Text
pLensAlias_
Text
pClientRequestToken_
LensStatusType
pLensStatus_ =
DeleteLens'
{ $sel:lensAlias:DeleteLens' :: Text
lensAlias = Text
pLensAlias_,
$sel:clientRequestToken:DeleteLens' :: Text
clientRequestToken = Text
pClientRequestToken_,
$sel:lensStatus:DeleteLens' :: LensStatusType
lensStatus = LensStatusType
pLensStatus_
}
deleteLens_lensAlias :: Lens.Lens' DeleteLens Prelude.Text
deleteLens_lensAlias :: Lens' DeleteLens Text
deleteLens_lensAlias = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteLens' {Text
lensAlias :: Text
$sel:lensAlias:DeleteLens' :: DeleteLens -> Text
lensAlias} -> Text
lensAlias) (\s :: DeleteLens
s@DeleteLens' {} Text
a -> DeleteLens
s {$sel:lensAlias:DeleteLens' :: Text
lensAlias = Text
a} :: DeleteLens)
deleteLens_clientRequestToken :: Lens.Lens' DeleteLens Prelude.Text
deleteLens_clientRequestToken :: Lens' DeleteLens Text
deleteLens_clientRequestToken = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteLens' {Text
clientRequestToken :: Text
$sel:clientRequestToken:DeleteLens' :: DeleteLens -> Text
clientRequestToken} -> Text
clientRequestToken) (\s :: DeleteLens
s@DeleteLens' {} Text
a -> DeleteLens
s {$sel:clientRequestToken:DeleteLens' :: Text
clientRequestToken = Text
a} :: DeleteLens)
deleteLens_lensStatus :: Lens.Lens' DeleteLens LensStatusType
deleteLens_lensStatus :: Lens' DeleteLens LensStatusType
deleteLens_lensStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteLens' {LensStatusType
lensStatus :: LensStatusType
$sel:lensStatus:DeleteLens' :: DeleteLens -> LensStatusType
lensStatus} -> LensStatusType
lensStatus) (\s :: DeleteLens
s@DeleteLens' {} LensStatusType
a -> DeleteLens
s {$sel:lensStatus:DeleteLens' :: LensStatusType
lensStatus = LensStatusType
a} :: DeleteLens)
instance Core.AWSRequest DeleteLens where
type AWSResponse DeleteLens = DeleteLensResponse
request :: (Service -> Service) -> DeleteLens -> Request DeleteLens
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 DeleteLens
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse DeleteLens)))
response = forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull DeleteLensResponse
DeleteLensResponse'
instance Prelude.Hashable DeleteLens where
hashWithSalt :: Int -> DeleteLens -> Int
hashWithSalt Int
_salt DeleteLens' {Text
LensStatusType
lensStatus :: LensStatusType
clientRequestToken :: Text
lensAlias :: Text
$sel:lensStatus:DeleteLens' :: DeleteLens -> LensStatusType
$sel:clientRequestToken:DeleteLens' :: DeleteLens -> Text
$sel:lensAlias:DeleteLens' :: DeleteLens -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
lensAlias
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
clientRequestToken
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` LensStatusType
lensStatus
instance Prelude.NFData DeleteLens where
rnf :: DeleteLens -> ()
rnf DeleteLens' {Text
LensStatusType
lensStatus :: LensStatusType
clientRequestToken :: Text
lensAlias :: Text
$sel:lensStatus:DeleteLens' :: DeleteLens -> LensStatusType
$sel:clientRequestToken:DeleteLens' :: DeleteLens -> Text
$sel:lensAlias:DeleteLens' :: DeleteLens -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
lensAlias
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
clientRequestToken
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf LensStatusType
lensStatus
instance Data.ToHeaders DeleteLens where
toHeaders :: DeleteLens -> [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 DeleteLens where
toPath :: DeleteLens -> ByteString
toPath DeleteLens' {Text
LensStatusType
lensStatus :: LensStatusType
clientRequestToken :: Text
lensAlias :: Text
$sel:lensStatus:DeleteLens' :: DeleteLens -> LensStatusType
$sel:clientRequestToken:DeleteLens' :: DeleteLens -> Text
$sel:lensAlias:DeleteLens' :: DeleteLens -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"/lenses/", forall a. ToByteString a => a -> ByteString
Data.toBS Text
lensAlias]
instance Data.ToQuery DeleteLens where
toQuery :: DeleteLens -> QueryString
toQuery DeleteLens' {Text
LensStatusType
lensStatus :: LensStatusType
clientRequestToken :: Text
lensAlias :: Text
$sel:lensStatus:DeleteLens' :: DeleteLens -> LensStatusType
$sel:clientRequestToken:DeleteLens' :: DeleteLens -> Text
$sel:lensAlias:DeleteLens' :: DeleteLens -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"ClientRequestToken" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Text
clientRequestToken,
ByteString
"LensStatus" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: LensStatusType
lensStatus
]
data DeleteLensResponse = DeleteLensResponse'
{
}
deriving (DeleteLensResponse -> DeleteLensResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteLensResponse -> DeleteLensResponse -> Bool
$c/= :: DeleteLensResponse -> DeleteLensResponse -> Bool
== :: DeleteLensResponse -> DeleteLensResponse -> Bool
$c== :: DeleteLensResponse -> DeleteLensResponse -> Bool
Prelude.Eq, ReadPrec [DeleteLensResponse]
ReadPrec DeleteLensResponse
Int -> ReadS DeleteLensResponse
ReadS [DeleteLensResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteLensResponse]
$creadListPrec :: ReadPrec [DeleteLensResponse]
readPrec :: ReadPrec DeleteLensResponse
$creadPrec :: ReadPrec DeleteLensResponse
readList :: ReadS [DeleteLensResponse]
$creadList :: ReadS [DeleteLensResponse]
readsPrec :: Int -> ReadS DeleteLensResponse
$creadsPrec :: Int -> ReadS DeleteLensResponse
Prelude.Read, Int -> DeleteLensResponse -> ShowS
[DeleteLensResponse] -> ShowS
DeleteLensResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteLensResponse] -> ShowS
$cshowList :: [DeleteLensResponse] -> ShowS
show :: DeleteLensResponse -> String
$cshow :: DeleteLensResponse -> String
showsPrec :: Int -> DeleteLensResponse -> ShowS
$cshowsPrec :: Int -> DeleteLensResponse -> ShowS
Prelude.Show, forall x. Rep DeleteLensResponse x -> DeleteLensResponse
forall x. DeleteLensResponse -> Rep DeleteLensResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteLensResponse x -> DeleteLensResponse
$cfrom :: forall x. DeleteLensResponse -> Rep DeleteLensResponse x
Prelude.Generic)
newDeleteLensResponse ::
DeleteLensResponse
newDeleteLensResponse :: DeleteLensResponse
newDeleteLensResponse = DeleteLensResponse
DeleteLensResponse'
instance Prelude.NFData DeleteLensResponse where
rnf :: DeleteLensResponse -> ()
rnf DeleteLensResponse
_ = ()