Last active
August 29, 2015 14:24
-
-
Save wcandillon/cbd86b0606da20088de2 to your computer and use it in GitHub Desktop.
XML processing from S3
This file contains 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
import module namespace s3 = "http://www.28msec.com/modules/s3"; | |
import module namespace p = "http://zorba.io/modules/xml"; | |
import schema namespace opt = "http://zorba.io/modules/xml-options"; | |
(: In this example the XML files contains DTD declarations :) | |
let $parse-options := <opt:options> | |
<opt:DTD-validate/> | |
</opt:options> | |
let $manifest := s3:read-text({ | |
"key": $id || "/manifest.xml", | |
"bucket": "asups" | |
}) | |
let $manifest := p:parse(string($manifest), $parse-options) | |
return $manifest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment