class Xcodeproj::Workspace
def to_s
-
(String)- the XML representation of the workspace.
def to_s contents = '' stack = [] @document.root.each_recursive do |elem| until stack.empty? last = stack.last break if last == elem.parent contents += xcworkspace_element_end_xml(stack.length, last) stack.pop end stack << elem contents += xcworkspace_element_start_xml(stack.length, elem) end until stack.empty? contents += xcworkspace_element_end_xml(stack.length, stack.last) stack.pop end root_xml(contents) end