Author: max.andersen(a)jboss.com
Date: 2009-03-06 14:47:25 -0500 (Fri, 06 Mar 2009)
New Revision: 14088
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.jpt.core/src/org/jboss/tools/hibernate/jpt/core/internal/context/HibernatePersistenceUnit.java
Log:
JBIDE-3960 calls to buildClassRef caused double creation of all annotations in jpa model
which resulted in validation errors
Modified:
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.jpt.core/src/org/jboss/tools/hibernate/jpt/core/internal/context/HibernatePersistenceUnit.java
===================================================================
---
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.jpt.core/src/org/jboss/tools/hibernate/jpt/core/internal/context/HibernatePersistenceUnit.java 2009-03-06
19:44:58 UTC (rev 14087)
+++
trunk/hibernatetools/plugins/org.jboss.tools.hibernate.jpt.core/src/org/jboss/tools/hibernate/jpt/core/internal/context/HibernatePersistenceUnit.java 2009-03-06
19:47:25 UTC (rev 14088)
@@ -178,8 +178,9 @@
protected void updateGenericGenerators(){
JpaProject project = getJpaProject();
- for (String annotClass : CollectionTools.iterable(project.annotatedClassNames())) {
- ClassRef classRef = buildClassRef(annotClass);
+
+ for (ClassRef classRef : CollectionTools.iterable(classRefs())) {
+ String annotClass = classRef.getClassName();
JavaPersistentType type = classRef.getJavaPersistentType();
JavaResourcePersistentMember jrpt = null;
GenericGeneratorAnnotation annotation = null;