Class: RForce::SoapResponseNokogiri

Inherits:
Object
  • Object
show all
Defined in:
lib/rforce/soap_response_nokogiri.rb

Instance Method Summary collapse

Constructor Details

#initialize(content) ⇒ SoapResponseNokogiri

Returns a new instance of SoapResponseNokogiri


5
6
7
# File 'lib/rforce/soap_response_nokogiri.rb', line 5

def initialize(content)
  @content = content
end

Instance Method Details

#parseObject


9
10
11
12
13
# File 'lib/rforce/soap_response_nokogiri.rb', line 9

def parse
  doc = Nokogiri::XML(@content)
  body = doc.at_xpath("//soapenv:Body")
  to_hash(body)
end