Hello,

I believe I have spotted a little issue in the WSIF code
(perhaps...).

The WSDL i am using is in document,wrapped, litteral style.
And when I am trying to invoke a function with no parameter,
WSIFClientProxy throw me a NullPointerException at line 668.
After looking at the source code, I discover that nearly
everywhere, it was tested if the variable args is null but not
there (args.length throw the error) so that's why I believe
it's a little mistake. I have seen that there is a little TODO
but this portion of code is used since 07/03/2003.
I have written this simple workaround (but don't know if it is
correct):

if (!unwrap&&args!=null) {
                // TODO: try to work out from part types
                // for now just hack
                unwrap = args.length != parts.size();
        } else if (!unwrap&&args==null) {
                unwrap = (parts.size()>0);
        }

instead of this original code :

if (!unwrap) {
                // TODO: try to work out from part types
                // for now just hack
                unwrap = args.length != parts.size();
        }

It solved the problem.
Tell me if I am right or if I am doing something wrong.


By the way, since I used a wsdl in document,wrapped, litteral
style, all my type are complex and I need to map them with
WSIFService.mapType(QName, Class) What do I put in Class if
the QName represent no paramater ?
I must map to something since WSIF just failed to find the
corresponding type and putting null just don't work (I get a
NullPointerException in WSIFServiceImpl.mapType)

Anthony Arrigoni

Acc�dez au courrier �lectronique de La Poste : www.laposte.net ; 
3615 LAPOSTENET (0,34�/mn) ; t�l : 08 92 68 13 50 (0,34�/mn)



Reply via email to