method
to_s
v2_6_3 -
Show latest stable
- Class:
RSS::XML::Element
to_s()public
No documentation available.
# File lib/rss/xml.rb, line 46
def to_s
rv = "<#{full_name}"
attributes.each do |key, value|
rv << " #{Utils.html_escape(key)}=\"#{Utils.html_escape(value)}\""
end
if children.empty?
rv << "/>"
else
rv << ">"
children.each do |child|
rv << child.to_s
end
rv << "</#{full_name}>"
end
rv
end