module Network.AWS.EC2.ReplaceNetworkACLEntry
(
replaceNetworkACLEntry
, ReplaceNetworkACLEntry
, rnaeICMPTypeCode
, rnaePortRange
, rnaeDryRun
, rnaeNetworkACLId
, rnaeRuleNumber
, rnaeProtocol
, rnaeRuleAction
, rnaeEgress
, rnaeCIdRBlock
, replaceNetworkACLEntryResponse
, ReplaceNetworkACLEntryResponse
) where
import Network.AWS.EC2.Types
import Network.AWS.EC2.Types.Product
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
data ReplaceNetworkACLEntry = ReplaceNetworkACLEntry'
{ _rnaeICMPTypeCode :: !(Maybe ICMPTypeCode)
, _rnaePortRange :: !(Maybe PortRange)
, _rnaeDryRun :: !(Maybe Bool)
, _rnaeNetworkACLId :: !Text
, _rnaeRuleNumber :: !Int
, _rnaeProtocol :: !Text
, _rnaeRuleAction :: !RuleAction
, _rnaeEgress :: !Bool
, _rnaeCIdRBlock :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
replaceNetworkACLEntry
:: Text
-> Int
-> Text
-> RuleAction
-> Bool
-> Text
-> ReplaceNetworkACLEntry
replaceNetworkACLEntry pNetworkACLId_ pRuleNumber_ pProtocol_ pRuleAction_ pEgress_ pCIdRBlock_ =
ReplaceNetworkACLEntry'
{ _rnaeICMPTypeCode = Nothing
, _rnaePortRange = Nothing
, _rnaeDryRun = Nothing
, _rnaeNetworkACLId = pNetworkACLId_
, _rnaeRuleNumber = pRuleNumber_
, _rnaeProtocol = pProtocol_
, _rnaeRuleAction = pRuleAction_
, _rnaeEgress = pEgress_
, _rnaeCIdRBlock = pCIdRBlock_
}
rnaeICMPTypeCode :: Lens' ReplaceNetworkACLEntry (Maybe ICMPTypeCode)
rnaeICMPTypeCode = lens _rnaeICMPTypeCode (\ s a -> s{_rnaeICMPTypeCode = a});
rnaePortRange :: Lens' ReplaceNetworkACLEntry (Maybe PortRange)
rnaePortRange = lens _rnaePortRange (\ s a -> s{_rnaePortRange = a});
rnaeDryRun :: Lens' ReplaceNetworkACLEntry (Maybe Bool)
rnaeDryRun = lens _rnaeDryRun (\ s a -> s{_rnaeDryRun = a});
rnaeNetworkACLId :: Lens' ReplaceNetworkACLEntry Text
rnaeNetworkACLId = lens _rnaeNetworkACLId (\ s a -> s{_rnaeNetworkACLId = a});
rnaeRuleNumber :: Lens' ReplaceNetworkACLEntry Int
rnaeRuleNumber = lens _rnaeRuleNumber (\ s a -> s{_rnaeRuleNumber = a});
rnaeProtocol :: Lens' ReplaceNetworkACLEntry Text
rnaeProtocol = lens _rnaeProtocol (\ s a -> s{_rnaeProtocol = a});
rnaeRuleAction :: Lens' ReplaceNetworkACLEntry RuleAction
rnaeRuleAction = lens _rnaeRuleAction (\ s a -> s{_rnaeRuleAction = a});
rnaeEgress :: Lens' ReplaceNetworkACLEntry Bool
rnaeEgress = lens _rnaeEgress (\ s a -> s{_rnaeEgress = a});
rnaeCIdRBlock :: Lens' ReplaceNetworkACLEntry Text
rnaeCIdRBlock = lens _rnaeCIdRBlock (\ s a -> s{_rnaeCIdRBlock = a});
instance AWSRequest ReplaceNetworkACLEntry where
type Rs ReplaceNetworkACLEntry =
ReplaceNetworkACLEntryResponse
request = postQuery eC2
response
= receiveNull ReplaceNetworkACLEntryResponse'
instance ToHeaders ReplaceNetworkACLEntry where
toHeaders = const mempty
instance ToPath ReplaceNetworkACLEntry where
toPath = const "/"
instance ToQuery ReplaceNetworkACLEntry where
toQuery ReplaceNetworkACLEntry'{..}
= mconcat
["Action" =:
("ReplaceNetworkAclEntry" :: ByteString),
"Version" =: ("2015-10-01" :: ByteString),
"Icmp" =: _rnaeICMPTypeCode,
"PortRange" =: _rnaePortRange,
"DryRun" =: _rnaeDryRun,
"NetworkAclId" =: _rnaeNetworkACLId,
"RuleNumber" =: _rnaeRuleNumber,
"Protocol" =: _rnaeProtocol,
"RuleAction" =: _rnaeRuleAction,
"Egress" =: _rnaeEgress,
"CidrBlock" =: _rnaeCIdRBlock]
data ReplaceNetworkACLEntryResponse =
ReplaceNetworkACLEntryResponse'
deriving (Eq,Read,Show,Data,Typeable,Generic)
replaceNetworkACLEntryResponse
:: ReplaceNetworkACLEntryResponse
replaceNetworkACLEntryResponse = ReplaceNetworkACLEntryResponse'