I'm new to Axis2/C and trying to write a service handler.  I'm
having problems if there's embeded white space in the incoming
SOAP payload.

My handler is something like:

    child1 = axiom_node_get_first_child( node, env ) ;
    //... do somethnig with first node
    child2 = axiom_node_get_next_sibling( child1, env ) ;
    //... do somethnig with second node

If I feed it a SOAP body of:

<method><param1>string1</param1><param2>string2</param2></method>

it seems to work; but if I use:

<method>
   <param1>string1</param1>
   <param2>string2</param2>
</method>

then it doesn't work (using "axiom_node_to_string()" shows leading
whitespace (newline, spaces) before the "<param1..." part, and the
subsequent extraction of child1's contents no longer works.

Changing the first line to:

    child1 = axiom_node_get_first_element( node, env ) ;

seems to skip the initial white space for the first parameter, but the
same problem occurs once I get to the "..next_child()" call (and there's
no "...next_element()" call).

Am I doing something wrong (probably)?  Is Axis wrong?  Is there a
"swallow whitespace" option?  Also, I'm not really sure what the
difference between "...first_element()" and "...first_child()" is
meant to be.

Thanks.
----------------------------------------------------------------
Version One End-User Seminars

REGISTER NOW!
http://www.versionone.co.uk/seminars

----------------------------------------------------------------
Version One Ltd. is the author of intelligent electronic document
delivery and imaging software. This software enables the electronic
storage, retrieval, management, enhancement and delivery of business
documents such as invoices, purchase orders and statements. Version One's
'paperless office' technology is seamlessly integrated into all major 
finance and ERP systems. With a typical ROI of less than six months, 
Version One's solutions are enabling thousands of organisations to 
save dramatic amounts of time and money. 

Version One is a Member of BASDA (Business Application Software 
Developers Association) and ESA (European Software Association).

The opinions expressed within this email represent those of the 
individual and not necessarily those of Version One Limited. 
The contents of this email may be privileged and are confidential. 
It may not be disclosed to or used by anyone other than the addressee(s), 
nor copied in any way.

Version One Limited, Pentland House, Village Way, Wilmslow, Cheshire, SK9 2GH, 
UK.
Registered office: Munro House, Portsmouth Road, Cobham, Surrey, KT11 1TF, UK
Registered in England Number: 2443078   VAT Registration Number: 674 1234 43

-----------------------------------------------------------------

 

Think about the environment - Do you really need to print this email?

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to