[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: serialVersionUID

From: Eric Blake
Subject: Re: serialVersionUID
Date: Sat, 21 Sep 2002 10:11:38 -0600
User-agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.0.1) Gecko/20020823 Netscape/7.0

It is necessary for serialization, although it is usually a private field. ALL classes in classpath which implement should declare this field, and it should match the results of running Sun's serialver tool on that class; otherwise, Classpath will not be compatible for serialization. uses the value of this field to see if two class versions are compatible. This field is needed in Classpath even when Sun's jar does not have the field. (Interfaces which extend Serializable do not need this field).

Giannis Georgalis wrote:
Hello again from the primary spammer of the GNU classpath list :)

I have one question. Please forgive my ignorance, as I'm new to the
classpath project.

What is serialVersionUID?, what is it used for? (instanceof operator?),
where can I find it's value for a specific class? and should *all* the
api classes have this constant?

Thank you,

This signature intentionally left boring.

Eric Blake             address@hidden
  BYU student, free software programmer

reply via email to

[Prev in Thread] Current Thread [Next in Thread]