|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmarquee.xmlrpc.objectcomm.Serializer
public class Serializer
This XmlRpcCustomSerializer serializes any Java object as an Xml-Rpc struct with a special member named "#ClassName". This member contains the qualified classname of the serialized type plus an object identifier which is used to track objects which have already been serialized for this serialization process.
The format of the member is "qualified.class.name.of.Type,oid" where oid is an integer number identifying the object being serialized. The serializer continues to serialize the content of the object if and only if the object being serialized has not already been serialized in this serialization process. That means that the content of an object is only serialized once, following references to the same object consist only of the "#ClassName" member with the same object identifier as the first occurence.
XmlRpcCustomSerializer
Constructor Summary | |
---|---|
Serializer()
|
Method Summary | |
---|---|
java.lang.Class |
getSupportedClass()
Returns the class of java.lang.Object as this serializer may serialze any object |
void |
serialize(java.lang.Object value,
java.lang.StringBuffer output)
Serializes value to output . |
static void |
setRequireSerializeable(boolean requireSerializeable)
Sets if the Serilizer should require transferred objects to implement java.io.Serializable. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Serializer()
Method Detail |
---|
public java.lang.Class getSupportedClass()
getSupportedClass
in interface XmlRpcCustomSerializer
public static void setRequireSerializeable(boolean requireSerializeable)
A
- boolean indicating if to require Serializeablepublic void serialize(java.lang.Object value, java.lang.StringBuffer output) throws XmlRpcException
value
to output
.
serialize
in interface XmlRpcCustomSerializer
value
- The object to serialize.output
- The buffer to place the serialized data.
XmlRpcException
- in case anything goes wrong during serializing.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |