com.thoughtworks.xstream.mapper
Class ImmutableTypesMapper
java.lang.Object
com.thoughtworks.xstream.mapper.MapperWrapper
com.thoughtworks.xstream.mapper.ImmutableTypesMapper
- All Implemented Interfaces:
- Mapper
public class ImmutableTypesMapper
- extends MapperWrapper
Mapper that specifies which types are basic immutable types. Types that are marked as immutable will be written
multiple times in the serialization stream without using references.
- Author:
- Joe Walnes
Methods inherited from class com.thoughtworks.xstream.mapper.MapperWrapper |
aliasForAttribute, aliasForAttribute, aliasForSystemAttribute, attributeForAlias, attributeForAlias, defaultImplementationOf, getConverterFromAttribute, getConverterFromAttribute, getConverterFromAttribute, getConverterFromItemType, getConverterFromItemType, getConverterFromItemType, getFieldNameForItemTypeAndName, getImplicitCollectionDefForFieldName, getItemTypeForItemFieldName, getLocalConverter, lookupMapperOfType, realClass, realMember, serializedClass, serializedMember, shouldSerializeMember |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ImmutableTypesMapper
public ImmutableTypesMapper(Mapper wrapped)
addImmutableType
public void addImmutableType(Class type)
isImmutableValueType
public boolean isImmutableValueType(Class type)
- Description copied from interface:
Mapper
- Whether this type is a simple immutable value (int, boolean, String, URL, etc.
Immutable types will be repeatedly written in the serialized stream, instead of using object references.
- Specified by:
isImmutableValueType
in interface Mapper
- Overrides:
isImmutableValueType
in class MapperWrapper
Copyright © 2004-2014 XStream. All Rights Reserved.