SOAP-WSDL - Re: retrieving output

Posted on Wed Apr 23 20:37:52 2008 by rhumbliner in response to 7733 (See the whole thread of 9)
Re: retrieving output

the output of `print "_DUMP: ",$response-<_DUMP();` is:

_DUMP: { 'MyTypes::fsPublic_SQLOutput' => { 'QryResult' => bless( do{\(my $o = 20)}, 'MyTypes::QryResult' +) } };


the output of `perldoc MyElements::fsPublic_SQLOutput` is:

NAME MyElements::fsPublic_SQLOutput DESCRIPTION Perl data type class for the XML Schema defined element fsPublic_SQLOutput from the namespac +e http://infraweb- dev.fs.usda.gov/fs_public.Services. METHODS new my $element = MyElements::fsPublic_SQLOutput->new($data); Constructor. The following data structure may be passed to new(): { # MyTypes::fsPublic_SQLOutput QryResult => { # MyTypes::QryResult StrHTML => $some_value, # string StrCsv => $some_value, # string StrXML => $some_value, # string }, }, AUTHOR Generated by SOAP::WSDL


which, incidently, puzzles me because why would i want a method to create something that i am expecting as output. shouldn't the pod describe methods to retrieve data from the object?

passing "{outputxml =>1}" as an option to the interface constructor produces xml with the dataset i'm expecting:

$response = '<?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http: +//schemas.xmlsoap.org/soap/encoding/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http +://www.w3.org/2001/XMLSchema-instance"> <SOAP-ENV:Header xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"></SOAP-ENV:Header><SOAP +-ENV:Body> <ser-root:fsPublic_SQLOutput xmlns:ser-root="http://infrawebdev.fs.usda.gov/fs_public.Services"><Qr +yResult> <StrHTML></StrHTML> <StrCsv></StrCsv> <StrXML> &lt;qryResults&gt; &lt;rows&gt; &lt;ID&gt;04&lt;/ID&gt; &lt;NAME&gt;R4, INTERMOUNTAIN REGION&lt;/NAME&gt; &lt;/rows&gt; ... snip ... &lt;/qryResults&gt;</StrXML></QryResult></ser-root:fsPublic_SQLOutput></SOAP-ENV:Body> </SOAP-ENV:Envelope>


thanks for walking me thru this,
tom
Direct Responses: 7741 | Write a response