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
-
Constructor Summary
-
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.SingleValueConverter
getConverterFromAttribute
(Class type, String attribute) Deprecated.since 1.3.1, usegetConverterFromAttribute(Class, String, Class)
com.thoughtworks.xstream.converters.SingleValueConverter
getConverterFromAttribute
(Class definedIn, String attribute, Class type) com.thoughtworks.xstream.converters.SingleValueConverter
Deprecated.since 1.3, usegetConverterFromAttribute(Class, String, Class)
com.thoughtworks.xstream.converters.SingleValueConverter
Deprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)
com.thoughtworks.xstream.converters.SingleValueConverter
getConverterFromItemType
(String fieldName, Class type) Deprecated.since 1.3, usegetConverterFromItemType(String, Class, Class)
com.thoughtworks.xstream.converters.SingleValueConverter
getConverterFromItemType
(String fieldName, Class type, Class definedIn) getFieldNameForItemTypeAndName
(Class definedIn, Class itemType, String itemFieldName) com.thoughtworks.xstream.mapper.Mapper.ImplicitCollectionMapping
getImplicitCollectionDefForFieldName
(Class itemType, String fieldName) getItemTypeForItemFieldName
(Class definedIn, String itemFieldName) com.thoughtworks.xstream.converters.Converter
getLocalConverter
(Class definedIn, String fieldName) boolean
isIgnoredElement
(String name) boolean
isImmutableValueType
(Class type) boolean
isReferenceable
(Class type) com.thoughtworks.xstream.mapper.Mapper
lookupMapperOfType
(Class type) realMember
(Class type, String serialized) serializedClass
(Class type) serializedMember
(Class type, String memberName) boolean
shouldSerializeMember
(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:
serializedClass
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
serializedClass
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
realClass
- Specified by:
realClass
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
realClass
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
serializedMember
- Specified by:
serializedMember
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
serializedMember
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
realMember
- Specified by:
realMember
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
realMember
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isImmutableValueType
- Specified by:
isImmutableValueType
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
isImmutableValueType
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
defaultImplementationOf
- Specified by:
defaultImplementationOf
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
defaultImplementationOf
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForAttribute
- Specified by:
aliasForAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
aliasForAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
attributeForAlias
- Specified by:
attributeForAlias
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
attributeForAlias
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForSystemAttribute
- Specified by:
aliasForSystemAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
aliasForSystemAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getFieldNameForItemTypeAndName
- Specified by:
getFieldNameForItemTypeAndName
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getFieldNameForItemTypeAndName
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getItemTypeForItemFieldName
- Specified by:
getItemTypeForItemFieldName
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getItemTypeForItemFieldName
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getImplicitCollectionDefForFieldName
public com.thoughtworks.xstream.mapper.Mapper.ImplicitCollectionMapping getImplicitCollectionDefForFieldName(Class itemType, String fieldName) - Specified by:
getImplicitCollectionDefForFieldName
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getImplicitCollectionDefForFieldName
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
shouldSerializeMember
- Specified by:
shouldSerializeMember
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
shouldSerializeMember
in 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:
getConverterFromItemType
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromItemType
in 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:
getConverterFromItemType
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromItemType
in 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:
getConverterFromAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getLocalConverter
public com.thoughtworks.xstream.converters.Converter getLocalConverter(Class definedIn, String fieldName) - Specified by:
getLocalConverter
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getLocalConverter
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
lookupMapperOfType
- Specified by:
lookupMapperOfType
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
lookupMapperOfType
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromItemType
public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromItemType(String fieldName, Class type, Class definedIn) - Specified by:
getConverterFromItemType
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromItemType
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
aliasForAttribute
Deprecated.since 1.3, use combination ofserializedMember(Class, String)
andgetConverterFromItemType(String, Class, Class)
- Specified by:
aliasForAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
aliasForAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
attributeForAlias
Deprecated.since 1.3, use combination ofrealMember(Class, String)
andgetConverterFromItemType(String, Class, Class)
- Specified by:
attributeForAlias
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
attributeForAlias
in 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:
getConverterFromAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
getConverterFromAttribute
public com.thoughtworks.xstream.converters.SingleValueConverter getConverterFromAttribute(Class definedIn, String attribute, Class type) - Specified by:
getConverterFromAttribute
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
getConverterFromAttribute
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isIgnoredElement
- Specified by:
isIgnoredElement
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
isIgnoredElement
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
isReferenceable
- Specified by:
isReferenceable
in interfacecom.thoughtworks.xstream.mapper.Mapper
- Overrides:
isReferenceable
in classcom.thoughtworks.xstream.mapper.MapperWrapper
-
serializedMember(Class, String)
andgetConverterFromItemType(String, Class, Class)