Class NoNameCoder
java.lang.Object
com.thoughtworks.xstream.io.naming.NoNameCoder
- All Implemented Interfaces:
NameCoder
A NameCoder that does nothing.
The usage of this implementation implies that the names used for the objects can also be used in the target format without any change. This applies also for XML if the object graph contains no object that is an instance of an inner class type or is in the default package.
- Since:
- 1.4
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecodeAttribute
(String attributeName) Decode an attribute name to an object name.decodeNode
(String nodeName) Decode a node name to an object name.encodeAttribute
(String name) Encode a meta-data name for an attribute in the target format.encodeNode
(String name) Encode an object name for a node in the target format.
-
Constructor Details
-
NoNameCoder
public NoNameCoder()
-
-
Method Details
-
decodeAttribute
Decode an attribute name to an object name.- Specified by:
decodeAttribute
in interfaceNameCoder
- Parameters:
attributeName
- the name of the attribute- Returns:
- the name of the meta-data
-
decodeNode
Decode a node name to an object name.- Specified by:
decodeNode
in interfaceNameCoder
- Parameters:
nodeName
- the name of the node- Returns:
- the name of the object
-
encodeAttribute
Encode a meta-data name for an attribute in the target format.- Specified by:
encodeAttribute
in interfaceNameCoder
- Parameters:
name
- the name of the meta-data- Returns:
- the attribute name in the target format
-
encodeNode
Encode an object name for a node in the target format.- Specified by:
encodeNode
in interfaceNameCoder
- Parameters:
name
- the name of the object data- Returns:
- the node name in the target format
-