fixed in cvs.
-- dims
On Tue, 11 May 2004 14:04:04 +0200, Bi�rn Bi�rnstad
<[EMAIL PROTECTED]> wrote:
>
> Jeff,
>
> I think your right. The way the method is used in the code snippet doesn't make
> any sense to me. You should file a bug report.
>
> Bioern
>
> Jeff Greif wrote:
> > In this code snippet from org.apache.axis.message.RPCHandler, around line
> > 260 in the axis-1.2 beta sources,
> >
> > if(null != destClass && dser == null &&
> > destClass.isAssignableFrom( org.w3c.dom.Element.class )){
> > //If a DOM element is expected, as last resort always allow
> > direct mapping
> > // of parameter's SOAP xml to a DOM element. Support of
> > literal parms by default.
> > dser =
> > context.getDeserializerForType(Constants.SOAP_ELEMENT);
> >
> > }
> > the test using isAssignableFrom looks backwards, if I am reading the javadoc
> > for Class.isAssignableFrom correctly. I think this is saying that if
> > destClass is Element or a superinterface of Element use the SoapElement
> > deserializer, but what was intended was to use the SoapElement deserializer
> > if destClass implements or is a subinterface of Element. Fortunately, since
> > Element is an interface, Object does not fit the conditions of this test, so
> > the deserializer won't be chosen incorrectly at least. Presumably destClass
> > is always a class, so can never be a superinterface of Element and the test
> > will always fail.
> >
> > I think what was intended was
> > Element.class.isAssignableFrom(destClass)
> >
> > Please pardon me if I have misunderstood the intent of this code.
> >
> > Jeff
> >
>
>