使用 Axis 调用带有附件的 WebService 时出错

Error Calling WebService with Attachment with Axis

当我附加 Octet Stream 并使用 Apache Axis 创建的客户端调用 WebService 时出现以下错误

java.io.IOException: No serializer found for class org.apache.axis.attachments.OctetStream in registry org.apache.axis.encoding.TypeMappingDelegate@c7b00c.

  Any suggestion on how I should proceed with the fix ?

此致,

SKR

我终于通过编写自定义的OctetStreamSerializerFactory 和OctetStreamDeSerilizerFactory 解决了这个问题。我将它添加到 SOAPStub class 中的 QName "Doc"。 工厂implements SerializerFactory。 getSerializer 方法 returns `OctetStreamDataHandlerSerializer 的实例。