{-# 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.CodePipeline.DeleteCustomActionType
(
DeleteCustomActionType (..),
newDeleteCustomActionType,
deleteCustomActionType_category,
deleteCustomActionType_provider,
deleteCustomActionType_version,
DeleteCustomActionTypeResponse (..),
newDeleteCustomActionTypeResponse,
)
where
import Amazonka.CodePipeline.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 DeleteCustomActionType = DeleteCustomActionType'
{
DeleteCustomActionType -> ActionCategory
category :: ActionCategory,
DeleteCustomActionType -> Text
provider :: Prelude.Text,
DeleteCustomActionType -> Text
version :: Prelude.Text
}
deriving (DeleteCustomActionType -> DeleteCustomActionType -> Bool
(DeleteCustomActionType -> DeleteCustomActionType -> Bool)
-> (DeleteCustomActionType -> DeleteCustomActionType -> Bool)
-> Eq DeleteCustomActionType
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteCustomActionType -> DeleteCustomActionType -> Bool
$c/= :: DeleteCustomActionType -> DeleteCustomActionType -> Bool
== :: DeleteCustomActionType -> DeleteCustomActionType -> Bool
$c== :: DeleteCustomActionType -> DeleteCustomActionType -> Bool
Prelude.Eq, ReadPrec [DeleteCustomActionType]
ReadPrec DeleteCustomActionType
Int -> ReadS DeleteCustomActionType
ReadS [DeleteCustomActionType]
(Int -> ReadS DeleteCustomActionType)
-> ReadS [DeleteCustomActionType]
-> ReadPrec DeleteCustomActionType
-> ReadPrec [DeleteCustomActionType]
-> Read DeleteCustomActionType
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteCustomActionType]
$creadListPrec :: ReadPrec [DeleteCustomActionType]
readPrec :: ReadPrec DeleteCustomActionType
$creadPrec :: ReadPrec DeleteCustomActionType
readList :: ReadS [DeleteCustomActionType]
$creadList :: ReadS [DeleteCustomActionType]
readsPrec :: Int -> ReadS DeleteCustomActionType
$creadsPrec :: Int -> ReadS DeleteCustomActionType
Prelude.Read, Int -> DeleteCustomActionType -> ShowS
[DeleteCustomActionType] -> ShowS
DeleteCustomActionType -> String
(Int -> DeleteCustomActionType -> ShowS)
-> (DeleteCustomActionType -> String)
-> ([DeleteCustomActionType] -> ShowS)
-> Show DeleteCustomActionType
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteCustomActionType] -> ShowS
$cshowList :: [DeleteCustomActionType] -> ShowS
show :: DeleteCustomActionType -> String
$cshow :: DeleteCustomActionType -> String
showsPrec :: Int -> DeleteCustomActionType -> ShowS
$cshowsPrec :: Int -> DeleteCustomActionType -> ShowS
Prelude.Show, (forall x. DeleteCustomActionType -> Rep DeleteCustomActionType x)
-> (forall x.
Rep DeleteCustomActionType x -> DeleteCustomActionType)
-> Generic DeleteCustomActionType
forall x. Rep DeleteCustomActionType x -> DeleteCustomActionType
forall x. DeleteCustomActionType -> Rep DeleteCustomActionType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteCustomActionType x -> DeleteCustomActionType
$cfrom :: forall x. DeleteCustomActionType -> Rep DeleteCustomActionType x
Prelude.Generic)
newDeleteCustomActionType ::
ActionCategory ->
Prelude.Text ->
Prelude.Text ->
DeleteCustomActionType
newDeleteCustomActionType :: ActionCategory -> Text -> Text -> DeleteCustomActionType
newDeleteCustomActionType
ActionCategory
pCategory_
Text
pProvider_
Text
pVersion_ =
DeleteCustomActionType' :: ActionCategory -> Text -> Text -> DeleteCustomActionType
DeleteCustomActionType'
{ $sel:category:DeleteCustomActionType' :: ActionCategory
category = ActionCategory
pCategory_,
$sel:provider:DeleteCustomActionType' :: Text
provider = Text
pProvider_,
$sel:version:DeleteCustomActionType' :: Text
version = Text
pVersion_
}
deleteCustomActionType_category :: Lens.Lens' DeleteCustomActionType ActionCategory
deleteCustomActionType_category :: (ActionCategory -> f ActionCategory)
-> DeleteCustomActionType -> f DeleteCustomActionType
deleteCustomActionType_category = (DeleteCustomActionType -> ActionCategory)
-> (DeleteCustomActionType
-> ActionCategory -> DeleteCustomActionType)
-> Lens
DeleteCustomActionType
DeleteCustomActionType
ActionCategory
ActionCategory
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteCustomActionType' {ActionCategory
category :: ActionCategory
$sel:category:DeleteCustomActionType' :: DeleteCustomActionType -> ActionCategory
category} -> ActionCategory
category) (\s :: DeleteCustomActionType
s@DeleteCustomActionType' {} ActionCategory
a -> DeleteCustomActionType
s {$sel:category:DeleteCustomActionType' :: ActionCategory
category = ActionCategory
a} :: DeleteCustomActionType)
deleteCustomActionType_provider :: Lens.Lens' DeleteCustomActionType Prelude.Text
deleteCustomActionType_provider :: (Text -> f Text)
-> DeleteCustomActionType -> f DeleteCustomActionType
deleteCustomActionType_provider = (DeleteCustomActionType -> Text)
-> (DeleteCustomActionType -> Text -> DeleteCustomActionType)
-> Lens DeleteCustomActionType DeleteCustomActionType Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteCustomActionType' {Text
provider :: Text
$sel:provider:DeleteCustomActionType' :: DeleteCustomActionType -> Text
provider} -> Text
provider) (\s :: DeleteCustomActionType
s@DeleteCustomActionType' {} Text
a -> DeleteCustomActionType
s {$sel:provider:DeleteCustomActionType' :: Text
provider = Text
a} :: DeleteCustomActionType)
deleteCustomActionType_version :: Lens.Lens' DeleteCustomActionType Prelude.Text
deleteCustomActionType_version :: (Text -> f Text)
-> DeleteCustomActionType -> f DeleteCustomActionType
deleteCustomActionType_version = (DeleteCustomActionType -> Text)
-> (DeleteCustomActionType -> Text -> DeleteCustomActionType)
-> Lens DeleteCustomActionType DeleteCustomActionType Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteCustomActionType' {Text
version :: Text
$sel:version:DeleteCustomActionType' :: DeleteCustomActionType -> Text
version} -> Text
version) (\s :: DeleteCustomActionType
s@DeleteCustomActionType' {} Text
a -> DeleteCustomActionType
s {$sel:version:DeleteCustomActionType' :: Text
version = Text
a} :: DeleteCustomActionType)
instance Core.AWSRequest DeleteCustomActionType where
type
AWSResponse DeleteCustomActionType =
DeleteCustomActionTypeResponse
request :: DeleteCustomActionType -> Request DeleteCustomActionType
request = Service -> DeleteCustomActionType -> Request DeleteCustomActionType
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteCustomActionType
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteCustomActionType)))
response =
AWSResponse DeleteCustomActionType
-> Logger
-> Service
-> Proxy DeleteCustomActionType
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteCustomActionType)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
AWSResponse DeleteCustomActionType
DeleteCustomActionTypeResponse
DeleteCustomActionTypeResponse'
instance Prelude.Hashable DeleteCustomActionType
instance Prelude.NFData DeleteCustomActionType
instance Core.ToHeaders DeleteCustomActionType where
toHeaders :: DeleteCustomActionType -> [Header]
toHeaders =
[Header] -> DeleteCustomActionType -> [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
"CodePipeline_20150709.DeleteCustomActionType" ::
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 DeleteCustomActionType where
toJSON :: DeleteCustomActionType -> Value
toJSON DeleteCustomActionType' {Text
ActionCategory
version :: Text
provider :: Text
category :: ActionCategory
$sel:version:DeleteCustomActionType' :: DeleteCustomActionType -> Text
$sel:provider:DeleteCustomActionType' :: DeleteCustomActionType -> Text
$sel:category:DeleteCustomActionType' :: DeleteCustomActionType -> ActionCategory
..} =
[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
"category" Text -> ActionCategory -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= ActionCategory
category),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"provider" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
provider),
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"version" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
version)
]
)
instance Core.ToPath DeleteCustomActionType where
toPath :: DeleteCustomActionType -> ByteString
toPath = ByteString -> DeleteCustomActionType -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery DeleteCustomActionType where
toQuery :: DeleteCustomActionType -> QueryString
toQuery = QueryString -> DeleteCustomActionType -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DeleteCustomActionTypeResponse = DeleteCustomActionTypeResponse'
{
}
deriving (DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool
(DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool)
-> (DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool)
-> Eq DeleteCustomActionTypeResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool
$c/= :: DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool
== :: DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool
$c== :: DeleteCustomActionTypeResponse
-> DeleteCustomActionTypeResponse -> Bool
Prelude.Eq, ReadPrec [DeleteCustomActionTypeResponse]
ReadPrec DeleteCustomActionTypeResponse
Int -> ReadS DeleteCustomActionTypeResponse
ReadS [DeleteCustomActionTypeResponse]
(Int -> ReadS DeleteCustomActionTypeResponse)
-> ReadS [DeleteCustomActionTypeResponse]
-> ReadPrec DeleteCustomActionTypeResponse
-> ReadPrec [DeleteCustomActionTypeResponse]
-> Read DeleteCustomActionTypeResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteCustomActionTypeResponse]
$creadListPrec :: ReadPrec [DeleteCustomActionTypeResponse]
readPrec :: ReadPrec DeleteCustomActionTypeResponse
$creadPrec :: ReadPrec DeleteCustomActionTypeResponse
readList :: ReadS [DeleteCustomActionTypeResponse]
$creadList :: ReadS [DeleteCustomActionTypeResponse]
readsPrec :: Int -> ReadS DeleteCustomActionTypeResponse
$creadsPrec :: Int -> ReadS DeleteCustomActionTypeResponse
Prelude.Read, Int -> DeleteCustomActionTypeResponse -> ShowS
[DeleteCustomActionTypeResponse] -> ShowS
DeleteCustomActionTypeResponse -> String
(Int -> DeleteCustomActionTypeResponse -> ShowS)
-> (DeleteCustomActionTypeResponse -> String)
-> ([DeleteCustomActionTypeResponse] -> ShowS)
-> Show DeleteCustomActionTypeResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteCustomActionTypeResponse] -> ShowS
$cshowList :: [DeleteCustomActionTypeResponse] -> ShowS
show :: DeleteCustomActionTypeResponse -> String
$cshow :: DeleteCustomActionTypeResponse -> String
showsPrec :: Int -> DeleteCustomActionTypeResponse -> ShowS
$cshowsPrec :: Int -> DeleteCustomActionTypeResponse -> ShowS
Prelude.Show, (forall x.
DeleteCustomActionTypeResponse
-> Rep DeleteCustomActionTypeResponse x)
-> (forall x.
Rep DeleteCustomActionTypeResponse x
-> DeleteCustomActionTypeResponse)
-> Generic DeleteCustomActionTypeResponse
forall x.
Rep DeleteCustomActionTypeResponse x
-> DeleteCustomActionTypeResponse
forall x.
DeleteCustomActionTypeResponse
-> Rep DeleteCustomActionTypeResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteCustomActionTypeResponse x
-> DeleteCustomActionTypeResponse
$cfrom :: forall x.
DeleteCustomActionTypeResponse
-> Rep DeleteCustomActionTypeResponse x
Prelude.Generic)
newDeleteCustomActionTypeResponse ::
DeleteCustomActionTypeResponse
newDeleteCustomActionTypeResponse :: DeleteCustomActionTypeResponse
newDeleteCustomActionTypeResponse =
DeleteCustomActionTypeResponse
DeleteCustomActionTypeResponse'
instance
Prelude.NFData
DeleteCustomActionTypeResponse