XMLEncoder runtime problem

I'm trying to use XMLEncode for the first time.

I have a simple class TextPanel which extends JTextPane. It overrides the paint() method and adds a setRotation() and getRotation() method. The few member variables all have get/set methods.

When I apply encoder.writeObject() to an instance of TextPanel I get this message:

java.lang.IllegalAccessException: Class sun.reflect.misc.Trampoline

can not access a member ofclass TextPanel with modifiers""

Continuing ...

java.lang.Exception: XMLEncoder: discarding statement XMLEncoder.writeObject(TextPanel);

Continuing ...

Can anyone give me any clues regarding what this message means? It seems to be telling me I don't have the necessary get/set methods, but I do.

Thanks for any help.

--gary

[869 byte] By [fiziwiga] at [2007-10-3 2:48:16]
# 1
At a guess, it's telling you that one of your getters isn't public.
YAT_Archivista at 2007-7-14 20:37:04 > top of Java-index,Java Essentials,Java Programming...
# 2

That's what it seems to be saying, but all the methods are public, and all correctly named.

Just to see what would happen, I marked every single variable (there are only three of them) as "transient". It still tells me the same thing even though there are no variables left that need to be serialized.

fiziwiga at 2007-7-14 20:37:04 > top of Java-index,Java Essentials,Java Programming...