Change History
Changes are split into three categories:
- Major changes: The major new features that all users should know about.
- Minor changes: Any smaller changes, including bugfixes.
- API changes: Any changes to the API that could impact existing users.
Version 1.0.2
Release Aug 7, 2004. Focus on improving the converters bundled with XStream to support a wider range of types.
Major changes
- XML elements are written in order they are defined in class, rather than alphabetical.
- Converters for java.io.File, java.sql.Timestamp, java.awt.Color, and dynamic proxies are now registered by default.
- EncodedByteArrayConverter is now registered by default and uses a single Base64 string to store the contents of a byte[]. This now works on all JVMs as it no longer relies on Sun specific classes. This converter will also unmarshal byte[] that have been serialized without it, for backwards compatability.
- New converters for java.sql.Time, java.sql.Date, java.util.Locale, java.util.Currency, java.util.Calendar and java.awt.Font.
- All caching is done in XStream instance instead of statics, allowing applications that use hot redeployment of classes to use XStream in a parent classloader.
- XStream will fail fast if a field value is defined more than once in XML when deserializing.
Minor changes
- The <entry> element used in Maps can now be specified by creating an alias for java.util.Map.Entry.
- Bugfix: Fields with characters that generate invalid XML (such as $ signs) are now escaped.
- Bugfix: Pre-instantiated objects can be unmarshalled through multiple levels.
API changes
- None.
Version 1.0.1
Released May 30, 2004. Misc features and bugfixes.
Major changes
- Support for multidimensional arrays.
- Object with readResolve() method will be treated the same way native serialization treats them.
Minor changes
- New converters for Throwable and StackTraceElement that retain stack trace (JDK 1.4 only)
- Bugfix: System.identityHashCode() is not guaranteed to be unique. Ensure reference checking is used as well.
- Bugfix: Allows user classes to be defined in WEB-INF/classes in Servlet environments. Tries to use context classloader if available.
- Support for java.util.Currency (through readResolve()).
- Instances of Jakarta Commons Lang Enum are now reused (through readResolve()).
- Bugfix: JavaClassConverter handles primitive type classes (contributed by Matthew Sandoz).
API changes
- Additional method: ConverterLookup.defaultConverter(). Custom implementations of this class should implement this new method.
Version 1.0
Released May 14, 2004. Focusses on finalizing the API for 1.0 release.
Major changes
- Supports fields of same name, hidden by inheritance.
Minor changes
- JavaDoc for most important parts of API.
API changes
- The ReflectionConverter and ReflectionProviders have had an overhaul to support hidden fields. Most methods now take an extra argument to specify which class a field is declared in.
Version 1.0 (release candidate 1)
Released May 9, 2004. Focusses on finalizing the API for 1.0 release.
Major changes
- JDK 1.3 compatability.
- Informative error messages.
- Defaults to using faster XPP based parser.
- Serializes final field under JDK 1.4.
- Fail fast when trying to serialize final field if not Sun 1.4 JRE.
Minor changes
- Misc performance improvements.
- Converters for TreeMap and TreeSet that store the Comparator.
API changes
- Default constructor for XStream class uses XppDriver instead of DomDriver. To use DomDriver, explicitly pass it in to the constructor.
- Exception is thrown if trying to serialize an object that contains a final field if not Sun 1.4 JRE.
About XStream version numbers...
Version 0.6
Released May 7, 2004. Focusses on providing full object graph support.
Major changes
- None.
Minor changes
- Bugfix: Objects that had no children could not be derefenced properly (thanks to Brian Slesinsky and Nick Pomfret).
- Bugfix: DateConverter is now thread safe.
- Optimization: String instances are reused as much as possible.
- Converters for BigInteger and BigDecimal.
- IntConverter now recognises hexadecimal and octal notations (thanks to Konstantin Pribluda).
API changes
- None.
Version 0.6 (release candidate 1)
Released April 19, 2004. Focusses on providing full object graph support.
Major changes
- Full support for object graphs, including duplicate references of same object and circular references.
- References can be identified using XPath (default), unique-IDs or disabled.
Minor changes
- Release includes Ant build file.
- Converters for non standard collections such as Collections.EMPTY_LIST, syncronizedList(), unmodifiableMap(), etc.
- Converter for nulls.
- Converter for dynamic proxies.
- Converter for java.net.URL.
- Converters for java.util.LinkedHashMap and java.util.LinkedHashSet.
- Converters for java.lang.reflect.Method and java.lang.reflect.Constructor.
- If duplicate reference support is disabled and a circular reference is encountered, an exception will be thrown.
API changes
- None.
Version 0.5
Released March 8, 2004. Focussed on performance.
Major changes
- Massive performance improvements. Up to 3 times faster for serialization and 22 times faster for deserialization!
- Non-DOM building pull parser based reader. Results in much smaller memory footprint, particularly when deserializing large object models.
Minor changes
- Misc performance improvements.
- Misc bugfixes.
- Alternate encodings can be used with DomDriver.
API changes
- Renamed XMLReader/Writer to HierarchicalStreamReader/Writer as XStream is not actually coupled to serializing just to XML.
- Cleaned up the public API.
- Moved internal XStream implementation classes to core package.
- Misc package/class renames to make more sense. Dumped lots of dead code.
Version 0.4
This version was never publicly released. All changes were made available in 0.5. Focussed on making it easier to create custom converters.
Major changes
- Overhaul of interface for Converters. Makes Converters much cleaner to write.
Minor changes
- Added custom converters for java.io.File, java.util.Properties, java.util.Vector, java.util.Hashtable, java.util.BitSet byte[] (Base64 encoded), char[].
- Misc bugfixes.
API changes
- New interface to be implemented by custom converters.
Version 0.3
Released January 1, 2004.
Major changes
- Added ElementMapper interface and default implementations to allow fine grained control over element name to class mapper operations.
- Added an XPP based reader and writer that uses a pull-parser to create a lightweight DOM tree.
Minor changes
- Added XStream.fromXML(XMLReader xmlReader,Object root) method to allow the population of an object graph starting with a live object root.
- Added XMLReader.peek() method to allow access to the underlying hierarchical object being unmarshalled.
API changes
- Aligned the the methods in XStream to use the specified ObjectFactory in the constructor instead of creating a SunReflectionObjectFactory.
Older versions
Changes in XStream prior to version 0.3 were not logged.