X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/9d6ae5baae9f86acb8e2d9fcb006d8b81167281b..dcad29dad0d29e22ffa0c34a8d9b43cbf5d64f12:/app/models/trace.rb diff --git a/app/models/trace.rb b/app/models/trace.rb index 2d4e9ef8a..92cc39678 100644 --- a/app/models/trace.rb +++ b/app/models/trace.rb @@ -76,6 +76,12 @@ class Trace < ActiveRecord::Base return `file -bi #{trace_name}`.chomp end + def to_xml + doc = OSM::API.new.get_xml_doc + doc.root << to_xml_node() + return doc + end + def to_xml_node el1 = XML::Node.new 'gpx_file' el1['id'] = self.id.to_s