(Answer) (Category) FAQ-O-Matic : (Category) JBuilder 4 Known Bugs :
Should the "Include debug info" switch affect the serialVersionUID?
John McGrath wrote:

It should not, but I can tell you what is happening. When the class is compiled with debug, JBuilder generates code to initialize member variables that are initialized to compile-time constants. This affects the Serialization Version UID for the class, since it creates a static initializer block. This will only occur for classes where all of the static final variables are initialized with compile-time constants.

I have a work-around that will eliminate the problem for you. If you create a static, non-final variable with an initializer, it should always create the static initializer, so the Serialization Version UID will be the same whether or not you compile with debug information. For example, add the the following to your class.

    private static int DUMMY = 1;

The other thing you can do is to explicitly specify the Serialization Version UID for the class. Although I am not that familiar with the issues concerning serialization in CORBA, doing this is critical when you store serialized versions of classes and may need to deserialize them with a modified version of the class.
2001-Jan-19 1:53pm gyles19@visi.com

See also:
(Xref) The serialVersionUID from classes compiled by JB4 doesn't match Sun's javac 1.3 or 1.4.
2001-Jul-09 2:28pm gyles19@visi.com
See also this Borland FAQ:
  http://community.borland.com/article/0,1410,27558,00.html

2001-Aug-09 6:58pm gyles19@visi.com
[Append to This Answer]
2001-Aug-09 6:58pm
Previous: (Answer) I can't define another application server.
Next: (Answer) Find in Path won't search for wildcard characters even if 'pattern match' is unchecked. The current file 'Find' command will do this.
This document is: http://www.visi.com/~gyles19/cgi-bin/fom.cgi?file=63
[Search] [Appearance]
This is a Faq-O-Matic 2.709.
This FAQ administered by gyles19@visi.com.

Other JBuilder Links

Java Community
Java Tools
Code Central
JB OpenTools
Community
Recent
Threads
Borland Chat
Chat FAQ
Feature Matrices
3.0 |  3.5 |  4.0
5.0 |  6.0 |  7.0
Shop for
JBuilder
JBuilder
Downloads
and reg keys
Report Piracy
Online Manuals
4.0 |  5.0 |  6.0
7.0
Borland
DevSupport's
Bug/RFE Form

Quality Central Client
JB Patches &
Updates
JBuilder FAQs TIs
JBuilder
Newsgroups
Tamaracka's
News Archive
Mr. Haki's
JBuilder Machine
JGuru's
JBuilder FAQ
Sun's Bug
Parade
Netring Home - About - Privacy
The
JBuilder Netring Logo
The Borland JBuilder Netring by JBuilder FAQ-O-Matic
[ Join Now | List Sites | Random | << Prev | Next >> ]
[ Previous 5 Sites | Skip Previous | Skip Next | Next 5 Sites ]