evilh...@yandex.ru wrote:
Hi I've created java webservice with .NET client with CXF. I have no problems 
with import of the WSDL to .NET client. But when I make some requests I see 
parameters in logged XML request. But when I check this parameters in the 
debugger there are nulls for all of them.
@WebParam(name="...") annotations were added, correct methods are invoked, but 
parameters are null.
How can I fix it? Thanks!
I have this issue too.
I solve it by modifying DocLiteralInInterceptor -
function private void getPara() to allow parameters name resolution.

I know this is not a good solution - but it works.


private void getPara(DepthXMLStreamReader xmlReader,
                        DataReader<XMLStreamReader> dr,
                        MessageContentsList parameters,
                        Iterator<MessagePartInfo> itr,
                        Message message) {

       boolean hasNext = true;
       while (itr.hasNext()) {
           MessagePartInfo part = itr.next();
           if (hasNext) {
               hasNext = StaxUtils.toNextElement(xmlReader);
           }
           Object obj = null;
           if (hasNext) {
               QName rname = xmlReader.getName();
               while (part != null
&& !(rname.equals(part.getConcreteName()) || rname.equals(part.getElementQName()))) {
                   if (part.getXmlSchema() instanceof XmlSchemaElement) {
//TODO - should check minOccurs=0 and throw validation exception
                       //thing if the part needs to be here
                       parameters.put(part, null);
                   }

                   if (itr.hasNext()) {
                       part = itr.next();
                   } else {
                       part = null;
                   }
               }
               if (part == null) {
                   return;
               }
if (rname.equals(part.getConcreteName()) || rname.equals(part.getElementQName())) {
                   obj = dr.read(part, xmlReader);
               }
           }
           parameters.put(part, obj);
       }
   }

--------
This data is for general information only and shall not be used to produce documents of any kind without same being submitted to, reviewed by, and approved by Intego in writing. All data is subject to change. User assumes all liability relating to the use of this data and agrees to release, indemnify, and hold harmless Intego from any and all claims relating said use. User is responsible to check for any viruses before use.

Reply via email to