com.thoughtworks.xstream.core
Class TreeMarshaller

java.lang.Object
  extended by com.thoughtworks.xstream.core.TreeMarshaller
All Implemented Interfaces:
DataHolder, MarshallingContext
Direct Known Subclasses:
AbstractReferenceMarshaller

public class TreeMarshaller
extends Object
implements MarshallingContext


Nested Class Summary
static class TreeMarshaller.CircularReferenceException
           
 
Field Summary
protected  ConverterLookup converterLookup
           
protected  HierarchicalStreamWriter writer
           
 
Constructor Summary
TreeMarshaller(HierarchicalStreamWriter writer, ConverterLookup converterLookup, Mapper mapper)
           
 
Method Summary
protected  void convert(Object item, Converter converter)
           
 void convertAnother(Object item)
          Converts another object searching for the default converter
 void convertAnother(Object item, Converter converter)
          Converts another object using the specified converter
 Object get(Object key)
           
protected  Mapper getMapper()
           
 Iterator keys()
           
 void put(Object key, Object value)
           
 void start(Object item, DataHolder dataHolder)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

writer

protected HierarchicalStreamWriter writer

converterLookup

protected ConverterLookup converterLookup
Constructor Detail

TreeMarshaller

public TreeMarshaller(HierarchicalStreamWriter writer,
                      ConverterLookup converterLookup,
                      Mapper mapper)
Method Detail

convertAnother

public void convertAnother(Object item)
Description copied from interface: MarshallingContext
Converts another object searching for the default converter

Specified by:
convertAnother in interface MarshallingContext
Parameters:
item - the next item to convert

convertAnother

public void convertAnother(Object item,
                           Converter converter)
Description copied from interface: MarshallingContext
Converts another object using the specified converter

Specified by:
convertAnother in interface MarshallingContext
Parameters:
item - the next item to convert
converter - the Converter to use

convert

protected void convert(Object item,
                       Converter converter)

start

public void start(Object item,
                  DataHolder dataHolder)

get

public Object get(Object key)
Specified by:
get in interface DataHolder

put

public void put(Object key,
                Object value)
Specified by:
put in interface DataHolder

keys

public Iterator keys()
Specified by:
keys in interface DataHolder

getMapper

protected Mapper getMapper()


Copyright © 2004-2014 XStream. All Rights Reserved.