Module: Wrest::Components::Translators::Xml
Instance Method Summary (collapse)
Instance Method Details
- (Object) deserialise(response, options = {})
14 15 16 17 18 19 20 |
# File 'lib/wrest/components/translators/xml.rb', line 14 def deserialise(response,={}) if(![:xpath].nil?) ActiveSupport::XmlMini.filter(response.body,[:xpath]) else Hash.from_xml(response.body) end end |
- (Object) serialise(hash, options = {})
22 23 24 |
# File 'lib/wrest/components/translators/xml.rb', line 22 def serialise(hash, = {}) hash.to_xml() end |