Method: CoreLibrary::ResponseHandler#apply_xml_deserializer

Defined in:
lib/apimatic-core/response_handler.rb

#apply_xml_deserializer(response) ⇒ Object

Applies xml deserializer to the response.



191
192
193
194
195
196
197
198
# File 'lib/apimatic-core/response_handler.rb', line 191

def apply_xml_deserializer(response)
  unless @xml_attribute.get_array_item_name.nil?
    return @deserializer.call(response.raw_body, @xml_attribute.get_root_element_name,
                              @xml_attribute.get_array_item_name, @deserialize_into, @datetime_format)
  end

  @deserializer.call(response.raw_body, @xml_attribute.get_root_element_name, @deserialize_into, @datetime_format)
end