axis 1.2.1 serializes primitive types as multirefs
--------------------------------------------------
Key: AXIS-2077
URL: http://issues.apache.org/jira/browse/AXIS-2077
Project: Apache Axis
Type: Bug
Components: Serialization/Deserialization
Versions: 1.2.1
Reporter: Daniel David Schäfer
I discovered a problem in axis 1.2.1 that also occurred in previous releases.
The soap-request gets blown up by many multirefs that only contain integers or
other primitve types.
I have provided a patch that solves this problem.
===================================================================
RCS file:
/usr/local/cvsroot/dev_projects/axis121/src/org/apache/axis/encoding/SerializationContext.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- dev_projects/axis121/src/org/apache/axis/encoding/SerializationContext.java
2005/06/22 12:34:12 1.1
+++ dev_projects/axis121/src/org/apache/axis/encoding/SerializationContext.java
2005/06/22 12:49:59 1.2
@@ -610,12 +610,21 @@
public boolean isPrimitive(Object value)
{
if (value == null) return true;
-
+
Class javaType = value.getClass();
if (javaType.isPrimitive()) return true;
-
+
+ if (javaType == Integer.class) return true;
+ if (javaType == Long.class) return true;
+ if (javaType == Double.class) return true;
+ if (javaType == Float.class) return true;
+ if (javaType == Boolean.class) return true;
+ if (javaType == Short.class) return true;
+ if (javaType == Character.class) return true;
+ if (javaType == Byte.class) return true;
if (javaType == String.class) return true;
+
if (Calendar.class.isAssignableFrom(javaType)) return true;
if (Date.class.isAssignableFrom(javaType)) return true;
if (HexBinary.class.isAssignableFrom(javaType)) return true;
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira