public class SerializableConverter extends AbstractReflectionConverter
AbstractReflectionConverter.DuplicateFieldException, AbstractReflectionConverter.UnknownFieldException
mapper, reflectionProvider, serializationMembers, serializationMethodInvoker
Constructor and Description |
---|
SerializableConverter(Mapper mapper,
ReflectionProvider reflectionProvider)
Deprecated.
|
SerializableConverter(Mapper mapper,
ReflectionProvider reflectionProvider,
ClassLoader classLoader)
Deprecated.
|
SerializableConverter(Mapper mapper,
ReflectionProvider reflectionProvider,
ClassLoaderReference classLoaderReference)
Construct a SerializableConverter.
|
Modifier and Type | Method and Description |
---|---|
boolean |
canConvert(Class type)
Determines whether the converter can marshall a particular type.
|
void |
doMarshal(Object source,
HierarchicalStreamWriter writer,
MarshallingContext context) |
protected void |
doMarshalConditionally(Object source,
HierarchicalStreamWriter writer,
MarshallingContext context) |
Object |
doUnmarshal(Object result,
HierarchicalStreamReader reader,
UnmarshallingContext context) |
protected Object |
doUnmarshalConditionally(Object result,
HierarchicalStreamReader reader,
UnmarshallingContext context) |
protected List |
hierarchyFor(Class type) |
protected void |
marshalUnserializableParent(HierarchicalStreamWriter writer,
MarshallingContext context,
Object replacedSource) |
canAccess, flushCache, instantiateNewInstance, marshal, marshallField, readResolve, shouldUnmarshalField, shouldUnmarshalTransientFields, unmarshal, unmarshallField
public SerializableConverter(Mapper mapper, ReflectionProvider reflectionProvider, ClassLoaderReference classLoaderReference)
mapper
- the mapper chain instancereflectionProvider
- the reflection providerclassLoaderReference
- the reference to the ClassLoader
of the XStream instancepublic SerializableConverter(Mapper mapper, ReflectionProvider reflectionProvider, ClassLoader classLoader)
SerializableConverter(Mapper, ReflectionProvider, ClassLoaderReference)
public SerializableConverter(Mapper mapper, ReflectionProvider reflectionProvider)
SerializableConverter(Mapper, ReflectionProvider, ClassLoaderReference)
public boolean canConvert(Class type)
ConverterMatcher
type
- the Class representing the object type to be convertedpublic void doMarshal(Object source, HierarchicalStreamWriter writer, MarshallingContext context)
doMarshal
in class AbstractReflectionConverter
protected void marshalUnserializableParent(HierarchicalStreamWriter writer, MarshallingContext context, Object replacedSource)
public Object doUnmarshal(Object result, HierarchicalStreamReader reader, UnmarshallingContext context)
doUnmarshal
in class AbstractReflectionConverter
protected void doMarshalConditionally(Object source, HierarchicalStreamWriter writer, MarshallingContext context)
protected Object doUnmarshalConditionally(Object result, HierarchicalStreamReader reader, UnmarshallingContext context)
Copyright © 2004–2017 XStream. All rights reserved.