add to_xml method for oldnode

This commit is contained in:
Christopher Schmidt 2008-05-11 22:26:46 +00:00
parent 604f9ddd46
commit e9b86e914d

View file

@ -1,4 +1,5 @@
class OldNode < GeoRecord
set_primary_keys :id, :version
set_table_name 'nodes'
validates_presence_of :user_id, :timestamp
@ -30,6 +31,12 @@ class OldNode < GeoRecord
old_node.version = node.version
return old_node
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 'node'