Package com.thoughtworks.xstream.core
Class AbstractReferenceMarshaller
java.lang.Object
com.thoughtworks.xstream.core.TreeMarshaller
com.thoughtworks.xstream.core.AbstractReferenceMarshaller
- All Implemented Interfaces:
DataHolder
,MarshallingContext
- Direct Known Subclasses:
ReferenceByIdMarshaller
,ReferenceByXPathMarshaller
Abstract base class for a TreeMarshaller, that can build references.
- Since:
- 1.2
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class
static class
Nested classes/interfaces inherited from class com.thoughtworks.xstream.core.TreeMarshaller
TreeMarshaller.CircularReferenceException
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ObjectIdDictionary
private Path
private PathTracker
private ObjectIdDictionary
Fields inherited from class com.thoughtworks.xstream.core.TreeMarshaller
converterLookup, writer
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractReferenceMarshaller
(HierarchicalStreamWriter writer, ConverterLookup converterLookup, Mapper mapper) -
Method Summary
Modifier and TypeMethodDescriptionvoid
protected abstract String
createReference
(Path currentPath, Object existingReferenceKey) protected abstract Object
createReferenceKey
(Path currentPath, Object item) protected abstract void
fireValidReference
(Object referenceKey) Methods inherited from class com.thoughtworks.xstream.core.TreeMarshaller
convertAnother, convertAnother, get, getMapper, keys, put, start
-
Field Details
-
references
-
implicitElements
-
pathTracker
-
lastPath
-
-
Constructor Details
-
AbstractReferenceMarshaller
public AbstractReferenceMarshaller(HierarchicalStreamWriter writer, ConverterLookup converterLookup, Mapper mapper)
-
-
Method Details
-
convert
- Overrides:
convert
in classTreeMarshaller
-
createReference
-
createReferenceKey
-
fireValidReference
-