User: sylvain
Date: 00/05/18 19:36:49
Modified: src/java/org/ejboss/container ProxyContainerForObject.java
Log:
Bug fix:
the "equals" method is now implemented directly in the proxy . It is treated as
"isIdentical", ie it compares PKs.
Revision Changes Path
1.8 +3 -4
ejboss/src/java/org/ejboss/container/ProxyContainerForObject.java
Index: ProxyContainerForObject.java
===================================================================
RCS file:
/products/cvs/ejboss/ejboss/src/java/org/ejboss/container/ProxyContainerForObject.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- ProxyContainerForObject.java 2000/05/19 01:16:55 1.7
+++ ProxyContainerForObject.java 2000/05/19 02:36:49 1.8
@@ -175,7 +175,7 @@
* but has not really clearly defined the "isIdentical".
*/
- else if (method.getName().equals("isIdentical")) {
+ else if (method.getName().equals("isIdentical") ||
method.getName().equals("equals")) {
// The first argument is the EJBObject we need to work from it
@@ -231,7 +231,6 @@
otherDBPKey = ejbObject.getPrimaryKey();
if (otherDBPKey != null) {
-
return new
Boolean(otherDBPKey.equals(pKey.getDataBasePrimaryKey()));
}
@@ -279,13 +278,13 @@
// We return the hashing of the database primary Key
- return pKey.getDataBasePrimaryKey().hashCode();
+ return new
Integer(pKey.getDataBasePrimaryKey().hashCode());
}
else {
- return pKey.hashCode();
+ return new Integer(pKey.hashCode());
}
}