SOAP-WSDL - Re: retrieving output

Posted on Fri Apr 25 11:30:39 2008 by mkutter in response to 7745 (See the whole thread of 9)
Re: retrieving output
Hi Tom,
actually, it is as simple as following methods down a tree, but you probably just got confused by not seeing anything reasonable in the Data::Dumper output.
SOAP::WSDL uses Inside-Out objects, which have several nice features like a memory overhead proportional to the number of class properties, not to the number of objects created (like hash-based objects). However, they're a bit different: They don't show their values in Dumper output, and the _DUMP output is a bit different to read.

$response->get_QryResult();

Should give you the first level response object. And - if nothing has gone wrong - calling any get_FOO method on a object should die with a message like
Can't locate object method "get_FOO" via package "MyTypes::testComplexTypeAll". Valid methods are: get_Test_2, set_Test_2, get_Test_1, set_Test_1 at lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm line 52 SOAP::WSDL::XSD::Typelib::ComplexType::AUTOMETHOD('MyTypes::testComplexTypeAll=SCALAR(0x85b +acb4)', 140225716) called at /usr/local/share/perl/5.8.8/Class/Std.pm line 546 Class::Std::AUTOLOAD('MyTypes::testComplexTypeAll=SCALAR(0x85bacb4)') called at t/SOAP/WSDL +/Generator/XSD_dot_names.t line 106

The stuff listed in "Valid methods" should give you a hint what to call.

You can also find the list of properties in the pod of the generated classes - the section should read something like this:
PROPERTIES The following properties may be accessed using get_PROPERTY / set_PROPERTY methods: * Test_1 * Test_2
However, you might also have found a bug in SOAP::WSDL, triggering incomplede code generation. But this is - unfortunately - something I cannot tell without examining the WSDL.

Martin
Direct Responses: 7769 | Write a response