axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "M.Zdila/EpiSoftware Ltd." <m.zd...@episoftware.com>
Subject Re: SOAP11, SCHEMA_1999
Date Thu, 18 Jan 2007 08:20:57 GMT
hi

i thought this should be simple to solve for someone working with axis some 
longer time as i just started using axis this week. anyway i've solved it 
myself:

1. i needed no GenericHandler overriding (no custom handler)
2. i needed to register the type:

QName xmlType = new 
QName("http://schemas.xmlsoap.org/soap/encoding/", "base64");
    mapping.register(byte[].class,
       new QName("http://schemas.xmlsoap.org/soap/encoding/", "base64"),
       new Base64SerializerFactory(byte[].class, xmlType),
       new Base64DeserializerFactory(byte[].class, xmlType));
    
    registry.register("http://schemas.xmlsoap.org/soap/encoding/", mapping);

anyway, i think this is a bit weird solution. or?
 :-)

On Wednesday 17 January 2007 18:56, M.Zdila/EpiSoftware Ltd. wrote:
> Hello
>
> I've googled, but found nothing :-(
>
> I need to communicate with client's web service that supports SOAP 1.1,
> schema version 1999. What I need to achieve is to serialize base64 data as
> xsi:type="SOAP-ENC:base64" but unfortunately the request still contains
> xsi:type="soapenc:base64Binary".
>
> I am using spring remoting with following handler with no help:
>
> import javax.xml.namespace.QName;
> import javax.xml.rpc.handler.GenericHandler;
> import javax.xml.rpc.handler.MessageContext;
>
> import org.apache.axis.Constants;
> import org.apache.axis.schema.SchemaVersion;
>
> public class MyHandler extends GenericHandler {
>
>   @Override
>   public QName[] getHeaders() {
>     return null;
>   }
>
>   @Override
>   public boolean handleRequest(MessageContext context) {
>     ((org.apache.axis.MessageContext)
> context).setSchemaVersion(SchemaVersion.SCHEMA_1999);
>     ((org.apache.axis.MessageContext)
> context).setEncodingStyle(Constants.URI_SOAP11_ENC);
>     return true;
>     // return super.handleRequest(context);
>   }
>
> }
>
> Thanks in advance!

-- 
Martin Zdila
Analyst/Developer

EpiSoftware Slovakia Ltd.
Letna 27, 043 14 Kosice

tel:+421-908-363-848
tel:+421-55-6770-420
mailto:m.zdila@episoftware.com
http://www.episoftware.com
xmpp:zdila@jabber.sk
callto://m.zdila/

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Mime
View raw message