axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Toshiyuki Kimura <>
Subject RE: SerializationTester and Vector serialization
Date Fri, 19 Sep 2003 03:48:43 GMT
Hi Wolfgang and Stephanie,

  Thank you for using my SerializationTester.

  I was sad underneath because it seemed that no one has an interest
in the package. :)   But, some of folks are using the file and it's
been maintained. Great!! That's open source!

Toshi <>

-----Original Message-----
From: Kroll, Stephanie []
Sent: Friday, September 19, 2003 12:45 AM
Subject: RE: SerializationTester and Vector serialization

Hi Wolfgang,

I was able to get sub-elements to serialize in-line by adding these
two lines to the serialize method of class SerializationTester:

        MessageContext msgContext =
                            new MessageContext( service.getEngine() );
added-> msgContext.setProperty(AxisEngine.PROP_DOMULTIREFS,
added-> msgContext.setTypeMappingRegistry(_tmr);

        SerializationContext ctx =
                     new SerializationContextImpl(writer, msgContext);


-----Original Message-----
From: Wolfgang Vullhorst []
Sent: Thursday, September 18, 2003 2:12 AM
To: Axis-Userlist (E-Mail)
Subject: SerializationTester and Vector serialization

  a few days ago I found a SerializationTester in this list (written by
Toshiyuki Kimura).
It works fine but I have a problem with the serialization of an object
"AnalysisRequest" that contains a Vector of "AnalysisRequestElement"

I registered the type mappings for "Request", "RequestElement" and Vector"

	SerializationTester st = new SerializationTester();
	st.registerTypeMapping(AnalysisRequest.class, new
QName("", "AnalysisRequest"),
BeanSerializerFactory.class, BeanDeserializerFactory.class);
	st.registerTypeMapping(AnalysisRequestElement.class, new
QName("", "AnalysisRequestElement"),
BeanSerializerFactory.class, BeanDeserializerFactory.class);
	st.registerTypeMapping(Vector.class, new
QName("", "AnalysisRequestElement"),
VectorSerializerFactory.class, VectorDeserializerFactory.class);
	st.test(req);	// <- req is an object of AnalysisRequest

The tester gives me the following result:

Your class : []
  ===> Serializer: [org.apache.axis.encoding.ser.BeanSerializer@13ad085]
  ========== Result: start ==========
  <?xml version="1.0" encoding="UTF-8"?>
  ========== Result: end   ==========
  *** Serialization was succeed !! ***

How can I configure the serializer to serialize the Vector too?
I tried the tester because I want to pass a java object as a part of a
message style SOAP request. Perhaps there is another way to do this?

Thanks for your help,

View raw message