Thanks for sharing the code. I am trying your way, with the TypeMapping.....
Could you tell me how you initiated the service = new Service(.....,...);
wsdlUrl - is the location of the file.
qn - qname I am doing qname = new QName("EmployeeDataService");
which I am unable to set and keep getting the error:
-Sri
At 01:07 PM 5/10/2005, [EMAIL PROTECTED] wrote:
Sri,
Here's what my code looks like:
=====================================
service=new Service(wsdlUrl, qn);
TypeMappingRegistry tmr = service.getTypeMappingRegistry();
TypeMapping tmcfg = tmr.createTypeMapping();
tmcfg.register(Class.forName("com.vzw.sane5.util.configuration.Configuration"), new QName("http://com.vzw.sane5.util.configuration", "Configuration"), new ConfigurationSerFactory(), new ConfigurationDeserFactory());
TypeMapping tmcfgar = tmr.createTypeMapping();
tmcfgar.register(Class.forName("com.vzw.sane5.util.configuration.Configuration"), new QName("http://com.vzw.sane5.util.configuration", "ConfigurationArray"), new org.apache.axis.encoding.ser.ArraySerializerFactory(), new org.apache.axis.encoding.ser.ArrayDeserializerFactory());
tmr.register("http://schemas.xmlsoap.org/soap/encoding/", tmcfg);
tmr.register("http://schemas.xmlsoap.org/soap/encoding/", tmcfgar);
=====================================
So I get the WSDL for my service from axis, then register my two types in the client side using the values I gave in my typeMapping section, but with a caveat:
In your typeMapping section you say :
<typeMapping
deserializer="org.apache.axis.encoding.ser.ArrayDeserializerFactory"
serializer="org.apache.axis.encoding.ser.ArraySerializerFactory"
type="java:your.special.class.package.Type[]"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
qname="ns1:TypeArray"
xmlns:ns1="http://your.special.class.package"/>
BUT, in the registration, you don't say Type[], as the classname, you say just Type. See my register() calls above - even though one is registering the ser/deser for the array and the other is for the class itself, they both register with classname "com.vzw.sane5.util.configuration.Configuration", which is the type in question. So it's slightly different on the server side than it is on the client side. It took me FOREVER to figure that one out!
Hope this helps!
Ben
___________________________________________________________________ The information contained in this message and any attachment may be proprietary, confidential, and privileged or subject to the work product doctrine and thus protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify me immediately by replying to this message and deleting it and all copies and backups thereof. Thank you.
