Method: OpenStreetMap::Relation#to_xml
- Defined in:
- lib/open_street_map/relation.rb
#to_xml(option = {}) ⇒ Object
Return XML for this relation. This method uses the Builder library. The only parameter ist the builder object.
29 30 31 32 33 34 35 36 37 38 |
# File 'lib/open_street_map/relation.rb', line 29 def to_xml(option = {}) xml = [:builder] ||= Builder::XmlMarkup.new xml.instruct! unless [:skip_instruct] xml.relation(attributes) do members.each do |member| member.to_xml(:builder => xml, :skip_instruct => true) end .to_xml(:builder => xml, :skip_instruct => true) end end |