The ejb container is supposed to serialize primary key object of ejb bean
(passivate) and activate it in ejbActivate method.

I usually code ejbActivate in

public void ejbActivate() throws EJBException, java.rmi.RemoteException {
        primaryKey = (MyPrimaryKey)entityContext.getPrimaryKey();
}

I implement equals and hashCode methods in MyPrimaryKey. However, I use an
algorithm in hashCode to return different hashCode for different cases.
Do you think I can get different MyPrimaryKey objects with different
hashCode and equals always returning true for them?

Jim

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to