module Network.AWS.CloudFormation.DescribeStackSet
(
describeStackSet
, DescribeStackSet
, desStackSetName
, describeStackSetResponse
, DescribeStackSetResponse
, drsStackSet
, drsResponseStatus
) where
import Network.AWS.CloudFormation.Types
import Network.AWS.CloudFormation.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
newtype DescribeStackSet = DescribeStackSet'
{ _desStackSetName :: Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
describeStackSet
:: Text
-> DescribeStackSet
describeStackSet pStackSetName_ =
DescribeStackSet' {_desStackSetName = pStackSetName_}
desStackSetName :: Lens' DescribeStackSet Text
desStackSetName = lens _desStackSetName (\ s a -> s{_desStackSetName = a});
instance AWSRequest DescribeStackSet where
type Rs DescribeStackSet = DescribeStackSetResponse
request = postQuery cloudFormation
response
= receiveXMLWrapper "DescribeStackSetResult"
(\ s h x ->
DescribeStackSetResponse' <$>
(x .@? "StackSet") <*> (pure (fromEnum s)))
instance Hashable DescribeStackSet where
instance NFData DescribeStackSet where
instance ToHeaders DescribeStackSet where
toHeaders = const mempty
instance ToPath DescribeStackSet where
toPath = const "/"
instance ToQuery DescribeStackSet where
toQuery DescribeStackSet'{..}
= mconcat
["Action" =: ("DescribeStackSet" :: ByteString),
"Version" =: ("2010-05-15" :: ByteString),
"StackSetName" =: _desStackSetName]
data DescribeStackSetResponse = DescribeStackSetResponse'
{ _drsStackSet :: !(Maybe StackSet)
, _drsResponseStatus :: !Int
} deriving (Eq, Read, Show, Data, Typeable, Generic)
describeStackSetResponse
:: Int
-> DescribeStackSetResponse
describeStackSetResponse pResponseStatus_ =
DescribeStackSetResponse'
{_drsStackSet = Nothing, _drsResponseStatus = pResponseStatus_}
drsStackSet :: Lens' DescribeStackSetResponse (Maybe StackSet)
drsStackSet = lens _drsStackSet (\ s a -> s{_drsStackSet = a});
drsResponseStatus :: Lens' DescribeStackSetResponse Int
drsResponseStatus = lens _drsResponseStatus (\ s a -> s{_drsResponseStatus = a});
instance NFData DescribeStackSetResponse where