Module: NoaaWeatherClient::SoapService
- Included in:
- NoaaWeatherClient::Services::ForecastByDay
- Defined in:
- lib/noaa_weather_client/services/soap_service.rb
Instance Method Summary collapse
Instance Method Details
#object_from_response(soap_action, message, options = {}) ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/noaa_weather_client/services/soap_service.rb', line 8 def object_from_response(soap_action, , = {}) client = .fetch(:client, SoapClientFactory.build_client) response_class = .fetch(:response_class, Responses::GenericResponse) response_class.new client.call(soap_action, message: ).body rescue Savon::Error => e raise Errors::CommunicationError, e., e.backtrace end |