openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ppod...@apache.org
Subject svn commit: r1451369 - /openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java
Date Thu, 28 Feb 2013 21:46:55 GMT
Author: ppoddar
Date: Thu Feb 28 21:46:54 2013
New Revision: 1451369

URL: http://svn.apache.org/r1451369
Log:
OPENJPA-2305: Restore the inheritance hierarchy of the generated canonical metamodel to that
of the domain model due to spec compliance, but flatten the attributes so that an inherited
attribute uses generic parameter of owning class type instead of the declared supertype

Modified:
    openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java

Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java?rev=1451369&r1=1451368&r2=1451369&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java
(original)
+++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/meta/AnnotationProcessor6.java
Thu Feb 28 21:46:54 2013
@@ -240,6 +240,10 @@ public class AnnotationProcessor6 extend
             SourceCode.Class modelClass = source.getTopLevelClass();
             Set<Element> members = handler.getPersistentMembers(e);
             TypeElement supCls = handler.getPersistentSupertype(e);
+            if (supCls != null) {
+            	String superName = factory.getMetaModelClassName(supCls.toString());
+            	source.getTopLevelClass().setSuper(superName);
+            }            
             while (supCls != null) {
             	members.addAll(handler.getPersistentMembers(supCls));
                 supCls = handler.getPersistentSupertype(supCls);



Mime
View raw message