db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg von Frantzius <joerg.von.frantz...@artnology.com>
Subject Re: classes registered in JDOImplHelper unloaded
Date Mon, 06 Mar 2006 17:14:21 GMT
Craig L Russell schrieb:
> Hi Erik,
>
> The JDOImplHelper cannot use soft references to registered classes 
> because it wasn't clear what would happen if the class is garbage 
> collected and then used again. We wanted to make sure that the 
> JDOImplHelper would always have the metadata for the class.
When a class object is garbage collected, doesn't that simply mean that 
it needs to be loaded again and initialized the same way it was for the 
first time?

There can't be any instances of that class anymore, so if anyone wants 
to do anything with a garbage collected class, he needs to load (and 
initialize) it first, registering the new class object with JDOImplHelper.

To me it seems that there would be no problem with SoftReferences or 
even WeakReferences here.

Mime
View raw message