Method: CoreLibrary::XmlHelper.serialize_hash_to_xml
- Defined in:
- lib/apimatic-core/utilities/xml_helper.rb
.serialize_hash_to_xml(root_element_name, entries, datetime_format: nil) ⇒ Object
Serializes the provided hash to XML.
36 37 38 39 40 41 42 |
# File 'lib/apimatic-core/utilities/xml_helper.rb', line 36 def serialize_hash_to_xml(root_element_name, entries, datetime_format: nil) doc = Nokogiri::XML::Document.new add_hash_as_subelement(doc, doc, root_element_name, entries, datetime_format: datetime_format) doc.to_xml end |