Package hudson.util.xstream
Class MapperDelegate
java.lang.Object
com.thoughtworks.xstream.mapper.MapperWrapper
hudson.util.xstream.MapperDelegate
- All Implemented Interfaces:
com.thoughtworks.xstream.mapper.Mapper
public class MapperDelegate
extends com.thoughtworks.xstream.mapper.MapperWrapper
Works like
MapperWrapper except it lets the subtype
change the delegation target.
Since XStream caches the result of mapper pipeline,
the kind of mutation and when you can do it is limited.
- Author:
- Kohsuke Kawaguchi
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.thoughtworks.xstream.mapper.Mapper
com.thoughtworks.xstream.mapper.Mapper.ImplicitCollectionMapping, com.thoughtworks.xstream.mapper.Mapper.Null -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaliasForAttribute(Class definedIn, String fieldName) Deprecated.aliasForAttribute(String attribute) aliasForSystemAttribute(String attribute) attributeForAlias(Class definedIn, String alias) Deprecated.since 1.3, use combination ofrealMember(Class, String)andgetConverterFromItemType(String, Class, Class)attributeForAlias(String alias) defaultImplementationOf(Class type) com.thoughtworks.xstream.converters.SingleValueConvertergetConverterFromAttribute(Class type, String attribute) Deprecated.since 1.3.1, usegetConverterFromAttribute(Class, String, Class)com.thoughtworks.xstream.converters.SingleValueConvertergetConverterFromAttribute(Class definedIn, String attribute, Class type) com.thoughtworks.xstream.converters.SingleValueConverterDeprecated.since 1.3, usegetConverterFromAttribute(Class, String, Class)com.thoughtworks.xstream.converters.SingleValueConverterDeprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)com.thoughtworks.xstream.converters.SingleValueConvertergetConverterFromItemType(String fieldName, Class type) Deprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)com.thoughtworks.xstream.converters.SingleValueConvertergetConverterFromItemType(String fieldName, Class type, Class definedIn) getFieldNameForItemTypeAndName(Class definedIn, Class itemType, String itemFieldName) com.thoughtworks.xstream.mapper.Mapper.ImplicitCollectionMappinggetImplicitCollectionDefForFieldName(Class itemType, String fieldName) getItemTypeForItemFieldName(Class definedIn, String itemFieldName) com.thoughtworks.xstream.converters.ConvertergetLocalConverter(Class definedIn, String fieldName) booleanisIgnoredElement(String name) booleanisImmutableValueType(Class type) booleanisReferenceable(Class type) com.thoughtworks.xstream.mapper.MapperlookupMapperOfType(Class type) realMember(Class type, String serialized) serializedClass(Class type) serializedMember(Class type, String memberName) booleanshouldSerializeMember(Class definedIn, String fieldName)
-
Field Details
-
delegate
protected com.thoughtworks.xstream.mapper.Mapper delegate
-
-
Constructor Details
-
MapperDelegate
public MapperDelegate(com.thoughtworks.xstream.mapper.Mapper delegate)
-
-
Method Details
-
serializedClass
- Specified by:
serializedClassin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
serializedClassin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
realClass
- Specified by:
realClassin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
realClassin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
serializedMember
- Specified by:
serializedMemberin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
serializedMemberin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
realMember
- Specified by:
realMemberin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
realMemberin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isImmutableValueType
- Specified by:
isImmutableValueTypein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
isImmutableValueTypein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
defaultImplementationOf
- Specified by:
defaultImplementationOfin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
defaultImplementationOfin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForAttribute
- Specified by:
aliasForAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
aliasForAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
attributeForAlias
- Specified by:
attributeForAliasin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
attributeForAliasin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForSystemAttribute
- Specified by:
aliasForSystemAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
aliasForSystemAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getFieldNameForItemTypeAndName
- Specified by:
getFieldNameForItemTypeAndNamein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getFieldNameForItemTypeAndNamein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getItemTypeForItemFieldName
- Specified by:
getItemTypeForItemFieldNamein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getItemTypeForItemFieldNamein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getImplicitCollectionDefForFieldName
public com.thoughtworks.xstream.mapper.Mapper.ImplicitCollectionMapping getImplicitCollectionDefForFieldName(Class itemType, String fieldName) - Specified by:
getImplicitCollectionDefForFieldNamein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getImplicitCollectionDefForFieldNamein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
shouldSerializeMember
- Specified by:
shouldSerializeMemberin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
shouldSerializeMemberin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromItemType
@Deprecated public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromItemType(String fieldName, Class type) Deprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)- Specified by:
getConverterFromItemTypein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromItemTypein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromItemType
@Deprecated public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromItemType(Class type) Deprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)- Specified by:
getConverterFromItemTypein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromItemTypein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromAttribute
@Deprecated public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromAttribute(String name) Deprecated.since 1.3, usegetConverterFromAttribute(Class, String, Class)- Specified by:
getConverterFromAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getLocalConverter
public com.thoughtworks.xstream.converters.Converter getLocalConverter(Class definedIn, String fieldName) - Specified by:
getLocalConverterin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getLocalConverterin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
lookupMapperOfType
- Specified by:
lookupMapperOfTypein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
lookupMapperOfTypein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromItemType
public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromItemType(String fieldName, Class type, Class definedIn) - Specified by:
getConverterFromItemTypein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromItemTypein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForAttribute
Deprecated.since 1.3, use combination ofserializedMember(Class, String)andgetConverterFromItemType(String, Class, Class)- Specified by:
aliasForAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
aliasForAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
attributeForAlias
Deprecated.since 1.3, use combination ofrealMember(Class, String)andgetConverterFromItemType(String, Class, Class)- Specified by:
attributeForAliasin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
attributeForAliasin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromAttribute
@Deprecated public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromAttribute(Class type, String attribute) Deprecated.since 1.3.1, usegetConverterFromAttribute(Class, String, Class)- Specified by:
getConverterFromAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromAttribute
public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromAttribute(Class definedIn, String attribute, Class type) - Specified by:
getConverterFromAttributein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
getConverterFromAttributein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isIgnoredElement
- Specified by:
isIgnoredElementin interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
isIgnoredElementin classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isReferenceable
- Specified by:
isReferenceablein interfacecom.thoughtworks.xstream.mapper.Mapper- Overrides:
isReferenceablein classcom.thoughtworks.xstream.mapper.MapperWrapper
-
serializedMember(Class, String)andgetConverterFromItemType(String, Class, Class)