JavaMemoryModel: transient final fields and deserialization

From: Sylvia Else (syljmm32@cryogenic.net)
Date: Thu Jun 10 2004 - 19:00:41 EDT


Did anything get decided about how a class can perform custom
deserialization of transient final fields?

Although not strictly a JMM issue, it has become more interesting as a
result of the new final field semantics. I'm already being frustrated by
the need to choose between default serialization and making the field
volatile. Using reflection is not an option if ones class is to run in an
environment where it is not trusted to use setAccessible.

There was some discussion of allowing readObject() constructor-like rights
regarding final fields, but nothing definite was said.

Sylvia.

-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel



This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:01:08 EDT