{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Network.AWS.EC2.DeletePlacementGroup
(
deletePlacementGroup
, DeletePlacementGroup
, dpgDryRun
, dpgGroupName
, deletePlacementGroupResponse
, DeletePlacementGroupResponse
) where
import Network.AWS.EC2.Types
import Network.AWS.EC2.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
data DeletePlacementGroup = DeletePlacementGroup'
{ _dpgDryRun :: !(Maybe Bool)
, _dpgGroupName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
deletePlacementGroup
:: Text
-> DeletePlacementGroup
deletePlacementGroup pGroupName_ =
DeletePlacementGroup'
{ _dpgDryRun = Nothing
, _dpgGroupName = pGroupName_
}
dpgDryRun :: Lens' DeletePlacementGroup (Maybe Bool)
dpgDryRun = lens _dpgDryRun (\ s a -> s{_dpgDryRun = a});
dpgGroupName :: Lens' DeletePlacementGroup Text
dpgGroupName = lens _dpgGroupName (\ s a -> s{_dpgGroupName = a});
instance AWSRequest DeletePlacementGroup where
type Rs DeletePlacementGroup =
DeletePlacementGroupResponse
request = postQuery ec2
response = receiveNull DeletePlacementGroupResponse'
instance Hashable DeletePlacementGroup
instance NFData DeletePlacementGroup
instance ToHeaders DeletePlacementGroup where
toHeaders = const mempty
instance ToPath DeletePlacementGroup where
toPath = const "/"
instance ToQuery DeletePlacementGroup where
toQuery DeletePlacementGroup'{..}
= mconcat
["Action" =: ("DeletePlacementGroup" :: ByteString),
"Version" =: ("2016-04-01" :: ByteString),
"DryRun" =: _dpgDryRun, "GroupName" =: _dpgGroupName]
data DeletePlacementGroupResponse =
DeletePlacementGroupResponse'
deriving (Eq,Read,Show,Data,Typeable,Generic)
deletePlacementGroupResponse
:: DeletePlacementGroupResponse
deletePlacementGroupResponse = DeletePlacementGroupResponse'
instance NFData DeletePlacementGroupResponse