axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deepal jayasinghe <>
Subject Re: [Axis2] Don't treat Object as DataHandler in ADB BeanUtil
Date Thu, 11 Jun 2009 00:48:50 GMT
Applied the patch, thank you very much for sending that.

> Hi,
> The attached patch changes SimpleTypeMapper.isDataHandler so that it no longer returns
true for java.lang.Object. The effect of this change is that if a method has a parameter of
type java.lang.Object, the method will be passed an OMNode containing the contents of the
parameter element instead of a javax.activation.DataHandler. This is a significant improvement
since the javax.activation.DataHandler conversion assumes that the element contains base 64
encoded binary data, but OMNode can represent anything. This is also consistent with java2wsdl,
which maps java.lang.Object to xs:anyType, which means that the element is allowed to have
any content, not just base64binary.
> Ideally, I would like to deserialize the object for the xs:anyType parameter based on
the xsi:type attribute, if present. That could be accomplished by changing BeanUtil, or it
can be done in the web service implementation itself. Either way, this change must be applied
first to get rid of the destructive conversion to javax.activation.DataHandler.
> In addition to the change to SimpleTypeMapper, the patch contains tests for SimpleTypeMapper
and BeanUtil, a change to pom.xml so that the BeanUtil test gets run at build time, and a
fix for a problem in CoverterUtilTest exposed by the change to pom.xml.
> Is this patch acceptable, or is there something I should do differently?
> Regards,
> Pétur Runólfsson
> Betware
> The content of this e-mail, together with any of its attachments, is for the exclusive
and confidential use of the named addressee(s) and it may contain legally privileged and confidential
information and/or copyrighted material. Any other distribution, use or reproduction without
the sender's prior consent is unauthorized and strictly prohibited. If you have by coincidence,
mistake or without specific authorization received this e-mail in error, please notify the
sender by e-mail immediately, uphold strict confidentiality and neither read, copy, transfer,
disseminate, disclose nor otherwise make use of its content in any way and delete the material
from your computer.
> The content of the e-mail and its attachments is the liability of the individual sender,
if it does not relate to the affairs of Betware.
> Betware does not assume any civil or criminal liability should the e-mail or it´s attachments
be virus infected.

Thank you!

View raw message