History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: XSTR-456
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Joerg Schaible
Reporter: Steve Molloy
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
XStream

Should revert to different converter when encountering NotSerializableException using SerializableConverter

Created: 07/Dec/07 09:48 AM   Updated: 25/Feb/08 05:02 PM
Component/s: Converters
Affects Version/s: 1.2.2
Fix Version/s: 1.3

JDK version and platform: Sun JDK 1.6.0_03 for Linux


 Description  « Hide
Running into this problem with my object tree, which I cannot modify (testing already written code).

The serialization goes up the tree until it encounters a GTKLookAndFeel object. This class extends SynthLookAndFeel which throws a NotSerializableException as part of its writeObject method. The SynthLookAndFeel class comments state:

 * This class implements {@link Serializable} as a side effect of it
 * extending {@link BasicLookAndFeel}. It is not intended to be serialized.
 * An attempt to serialize it will
 * result in {@link NotSerializableException}.

While this might not be very clean implementation for SynthLookAndFeel, it shouldn't prevent XStream to serialize the tree using a different converter, instead of the current behavior of throwing a ConversionException.

 All   Comments   Change History      Sort Order: Ascending order - Click to sort in descending order
Joerg Schaible - 07/Dec/07 07:11 PM
I've added a LookAndFeelConverter implementation that is based on reflection. You may give the current head revision a try.

Joerg Schaible - 25/Feb/08 05:02 PM
Closing issues before next release.