SOAP::Mapping::Object attribute access

I have written a Rails web service, which is working exactly as
The service has a method which returns an object of type
ActionWebService::Struct. In my SOAP client, I create a SOAP rpc driver,
execute the method, like this:

book = driver.ShowTitle(params[:isbn])

I then do a: book.inspect

and find this in the log:

<SOAP::Mapping::Object:0x…ca7b389da {}author_fname=“David”
{}author_lname=“Johnson” {}title=“The Story of SOAP”>

I cannot figure out how to access the attributes of this
SOAP::Mapping::Object. The empty curly braces are throwing me for a

Anyone see this before?

So, after a couple of days of head scratching, I finally figured it out.

The argument to the [] instance method for SOAP::Mapping::Object
requires a
quoted string rather than a symbol, so this one is solved.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs