From: <one...@us...> - 2003-01-13 13:03:54
|
Update of /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/proxy In directory sc8-pr-cvs1:/tmp/cvs-serv10279/net/sf/hibernate/proxy Modified Files: SerializableProxy.java Log Message: fixed proxy serialization for classes with no identifier getter Index: SerializableProxy.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/proxy/SerializableProxy.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** SerializableProxy.java 12 Jan 2003 09:02:58 -0000 1.5 --- SerializableProxy.java 13 Jan 2003 13:03:51 -0000 1.6 *************** *** 25,30 **** this.interfaces = interfaces; this.id = id; ! getIdentifierMethodClass = getIdentifierMethod.getDeclaringClass(); ! getIdentifierMethodName = getIdentifierMethod.getName(); } --- 25,32 ---- this.interfaces = interfaces; this.id = id; ! if (getIdentifierMethod!=null) { ! getIdentifierMethodClass = getIdentifierMethod.getDeclaringClass(); ! getIdentifierMethodName = getIdentifierMethod.getName(); ! } } *************** *** 34,38 **** persistentClass, interfaces, ! getIdentifierMethodClass.getDeclaredMethod(getIdentifierMethodName, null), id, null --- 36,40 ---- persistentClass, interfaces, ! (getIdentifierMethodName==null) ? null : getIdentifierMethodClass.getDeclaredMethod(getIdentifierMethodName, null), id, null |