that move just broke *all* of the code generation :( /max
------- Forwarded message ------- From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: Subject: [hibernate-commits] Hibernate SVN: r10319 - branches/Branch_3_2/Hibernate3/src/org/hibernate/mapping Date: Wed, 23 Aug 2006 23:57:11 +0200 Author: epbernard Date: 2006-08-23 17:57:10 -0400 (Wed, 23 Aug 2006) New Revision: 10319 Modified: branches/Branch_3_2/Hibernate3/src/org/hibernate/mapping/PersistentClass.java Log: ANN-381 add identifierProperty to getProperty and getRecursiveProperty Modified: branches/Branch_3_2/Hibernate3/src/org/hibernate/mapping/PersistentClass.java =================================================================== --- branches/Branch_3_2/Hibernate3/src/org/hibernate/mapping/PersistentClass.java 2006-08-23 13:36:35 UTC (rev 10318) +++ branches/Branch_3_2/Hibernate3/src/org/hibernate/mapping/PersistentClass.java 2006-08-23 21:57:10 UTC (rev 10319) @@ -349,7 +349,14 @@ while ( st.hasMoreElements() ) { String element = (String) st.nextElement(); if (property == null) { - property = getProperty( element, iter ); + Property identifierProperty = getIdentifierProperty(); + if ( identifierProperty != null + && identifierProperty.getName().equals( StringHelper.root(element) ) ) { + property = identifierProperty; + } + else { + property = getProperty( element, iter ); + } } else { //flat recursive algorithm @@ -379,7 +386,15 @@ public Property getProperty(String propertyName) throws MappingException { Iterator iter = getPropertyClosureIterator(); - return getProperty( propertyName, iter ); + Property identifierProperty = getIdentifierProperty(); + if ( identifierProperty != null + && identifierProperty.getName().equals( StringHelper.root(propertyName) ) + ) { + return identifierProperty; + } + else { + return getProperty( propertyName, iter ); + } } abstract public int getOptimisticLockMode(); _______________________________________________ hibernate-commits mailing list [EMAIL PROTECTED] https://lists.jboss.org/mailman/listinfo/hibernate-commits -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss a division of Red Hat [EMAIL PROTECTED] ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel