java.lang.Object |
↳ |
com.thoughtworks.xstream.converters.reflection.XStream12FieldKeySorter |
Class Overview
Sort the fields in the order of XStream 1.2.x. Fields are returned in their declaration order,
fields of base classes last.
Summary
Public Methods |
Map
|
sort(Class type, Map keyedByFieldKey)
Sort the fields of a type.
|
Public Constructors
public
XStream12FieldKeySorter
()
Public Methods
public
Map
sort
(Class type, Map keyedByFieldKey)
Sort the fields of a type. The method will be called with the class type that contains
all the fields and a Map that retains the order in which the elements have been added.
The sequence in which elements are returned by an iterator defines the processing order
of the fields. An implementation may create a different Map with similar semantic, add
all elements of the original map and return the new one.
Parameters
type
| the class that contains all the fields |
keyedByFieldKey
| a Map containing a FieldKey as key element and a
Field as value. |
Returns
- a Map with all the entries of the original Map