1.4 objects in 1.5 ?

V

VisionSet

I think the answer is no, but can you handle objects created by 1.4
compiled code in 1.5 code?
I want 1.4 on the client and 1.5 on the server and yes I serialise
objects between the two. Bad I know.

TIA
Mike W
 
T

Thomas Hawtin

VisionSet said:
I think the answer is no, but can you handle objects created by 1.4
compiled code in 1.5 code?
I want 1.4 on the client and 1.5 on the server and yes I serialise
objects between the two. Bad I know.

So long as you use serialVersionUID and your object classes are not from
Swing or are anonymous or local inner classes, you should be fine.

Swing doesn't guarantee to keep compatibility between major releases.

3rd Ed JLS pins down generated names of inner classes better than
previous editions, but does not completely match earlier compiler
behaviour (and you are strongly discourage in the spec).

IIRC, between certain versions, javac produces different methods/fields
used in the calculation of serialVersionUID. Things like class constants
and static initialisers may change. So specifying the UID is a good idea.

Tom Hawtin
 
V

VisionSet

Thomas said:
So long as you use serialVersionUID and your object classes are not from
Swing or are anonymous or local inner classes, you should be fine.


Excellent, got it working now, thanks.
Now to sort out the "gui/threading/screwy rendering due no doubt to
something not occuring on the event thread that should be" problem.

Mike W
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,812
Latest member
GracielaWa

Latest Threads

Top