You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
497 B

  1. class ExportOSMXML {
  2. constructor (conf) {
  3. this.conf = conf
  4. this.parentNode = document.createElement('osm')
  5. }
  6. each (ob, callback) {
  7. ob.object.exportOSMXML(this.conf, this.parentNode, callback)
  8. }
  9. finish (list) {
  10. return {
  11. content: '<?xml version="1.0" encoding="UTF-8"?><osm version="0.6" generator="OpenStreetBrowser">' + this.parentNode.innerHTML + '</osm>',
  12. fileType: 'application/xml',
  13. extension: 'osm.xml'
  14. }
  15. }
  16. }
  17. module.exports = ExportOSMXML