Created
March 3, 2015 01:03
-
-
Save trevorrowe/df78dd1f92cf02f19f76 to your computer and use it in GitHub Desktop.
XML parsing logic
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
shape = sqs.config.api.operation(:receive_message).output | |
shape = Seahorse::Model::Shapes::Structure.new({ | |
'members' => { | |
shape.metadata('resultWrapper') => shape.definition, | |
'ResponseMetadata' => { | |
'type' => 'structure', | |
'members' => { | |
'RequestId' => { 'type' => 'string' } | |
} | |
} | |
} | |
}, shape_map: shape.shape_map) | |
xml = "<ReceiveMessageResponse>\n <ReceiveMessageResult>\n </ReceiveMessageResult>\n <ResponseMetadata>\n <RequestId>19643011-2310-45d0-8611-e8eaaccc550e</RequestId>\n </ResponseMetadata>\n</ReceiveMessageResponse>\n" | |
Aws::Xml::Parser.new(shape).parse(xml) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment