Re: SOAP11, SCHEMA_1999

2007-01-18 Thread M.Zdila/EpiSoftware Ltd.
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:[EMAIL PROTECTED]
http://www.episoftware.com
xmpp:[EMAIL PROTECTED]
callto://m.zdila/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



SOAP11, SCHEMA_1999

2007-01-17 Thread M.Zdila/EpiSoftware Ltd.
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:[EMAIL PROTECTED]
http://www.episoftware.com
xmpp:[EMAIL PROTECTED]
callto://m.zdila/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]