I stumbled over the same problem a few days ago and found a possible solution.
Here is a snippet from my post to the SOAP::Lite Mailinglist.
--snip--
All I found so far on the web is the hint to create my own serializer to solve this.
I dont think this will solve my problem as I dont want to change the
behaviour of SOAP::Lite with regard to serialization of an undefined parameter
but rather want to skip the parameter serialization for parameterless method calls completely.
After some UTSL I changed line 1593 in SOAP::Lite from
$body->set_value($parameters ? \$parameters : SOAP::Utils::encode_data()) if
$body;
to
$body->set_value($parameters, \$parameters) if $body && $parameters;
which results in the "correct" body tag as described above.
I would like to know if there is a better way to achieve this or if not,whether we could make this behaviour configuration dependend lets say over a
method call like $handle->suppress_nils_in_parameterless_calls(1|0) as
already implemented for calls like $handle->use_default_ns()
--/snip--
cat /dev/world | perl -e "(/(^.*? \?) 42\!/) && (print $1))"
errors->(c)
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.