You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Sebastien Cesbron <se...@laposte.net> on 2003/09/09 12:56:44 UTC
Repost : NullPointerException in hashCode
Am I the only one that have this problem ? Can anybody tell me what I
can do in this situation ?
Thanx
Seb
Hi,
I have a NullPointerException in my hashCode method when it is called by
AnonymousPersistentField.set().
My custom hashcode method just call the hashcode method on my pk field
(a string).
In the archive I saw a message
(http://www.mail-archive.com/ojb-user@db.apache.org/msg03742.html) that
said that this is a normal problem. Is there a way to solve that ? Do I
have to remove my hashCode implementation ?
Seb
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org
Re: Repost : NullPointerException in hashCode
Posted by Sebastien Cesbron <se...@laposte.net>.
Ok, I removed the hashCode too and OJB works well. But my hashCode was
based on my object's pk. Now I have some problems putting my objects in
a HashMap.
So what can I do now ? Is this a bug that will be corrected or is it a
known problem that will remain unchanged in the future ?
Seb
Christian Pesch wrote:
> Sebastien Cesbron wrote:
>
>> Am I the only one that have this problem ?
>
>
> No :-)
>
>> Can anybody tell me what I can do in this situation ?
>
>
> I removed hashCode() and waited for a wise suggestion,
> what to do :-)
>
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org
Re: Repost : NullPointerException in hashCode
Posted by Christian Pesch <ch...@coremedia.com>.
Sebastien Cesbron wrote:
> Am I the only one that have this problem ?
No :-)
> Can anybody tell me what I can do in this situation ?
I removed hashCode() and waited for a wise suggestion,
what to do :-)
--
Christian
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org