cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aadamc...@apache.org
Subject svn commit: r578695 - /cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java
Date Mon, 24 Sep 2007 07:51:41 GMT
Author: aadamchik
Date: Mon Sep 24 00:51:40 2007
New Revision: 578695

URL: http://svn.apache.org/viewvc?rev=578695&view=rev
Log:
CAY-848 Support for mapping to-many as Maps and Sets and Collections
adding reverse rel null check even though in most cases existing complimentary relationships
will be guaranteed by Cayenne runtime

Modified:
    cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java

Modified: cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java?rev=578695&r1=578694&r2=578695&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java
(original)
+++ cayenne/main/trunk/framework/cayenne-jdk1.4-unpublished/src/main/java/org/apache/cayenne/reflect/PersistentDescriptor.java
Mon Sep 24 00:51:40 2007
@@ -85,9 +85,9 @@
         }
         else if (property instanceof ArcProperty) {
             ObjRelationship relationship = ((ArcProperty) property).getRelationship();
-            if ("java.util.Map".equals(relationship
-                    .getReverseRelationship()
-                    .getCollectionType())) {
+            ObjRelationship reverseRelationship = relationship.getReverseRelationship();
+            if (reverseRelationship != null
+                    && "java.util.Map".equals(reverseRelationship.getCollectionType()))
{
 
                 if (declaredMapArcProperties == null) {
                     declaredMapArcProperties = new ArrayList(2);



Mime
View raw message