module NoaaWeatherClient::SoapService
Public Instance Methods
object_from_response(soap_action, message, options = {})
click to toggle source
# File lib/noaa_weather_client/services/soap_service.rb, line 8 def object_from_response(soap_action, message, options = {}) client = options.fetch(:client, SoapClientFactory.build_client) response_class = options.fetch(:response_class, Responses::GenericResponse) response_class.new client.call(soap_action, message: message).body rescue Savon::Error => e raise Errors::CommunicationError, e.message, e.backtrace end