openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From awh...@apache.org
Subject svn commit: r713815 - in /openjpa/branches/1.1.x: openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/ openjpa-kernel/src/main/java/org/apache/openjpa/datacache/ openjpa-kernel/src/main/java/org/apache/openjpa/meta/
Date Thu, 13 Nov 2008 20:45:19 GMT
Author: awhite
Date: Thu Nov 13 12:45:18 2008
New Revision: 713815

URL: http://svn.apache.org/viewvc?rev=713815&view=rev
Log:
Complete merge of 680579 from 0.9.7 to 1.1.x.


Modified:
    openjpa/branches/1.1.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/AbstractUpdateManager.java
    openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java
    openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/meta/FieldMetaData.java

Modified: openjpa/branches/1.1.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/AbstractUpdateManager.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.1.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/AbstractUpdateManager.java?rev=713815&r1=713814&r2=713815&view=diff
==============================================================================
--- openjpa/branches/1.1.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/AbstractUpdateManager.java
(original)
+++ openjpa/branches/1.1.x/openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/AbstractUpdateManager.java
Thu Nov 13 12:45:18 2008
@@ -156,9 +156,10 @@
                     store, customs, true);
             } else if (sm.isVersionCheckRequired()) {
                 if (!((ClassMapping) sm.getMetaData()).getVersion().
-                    checkVersion(sm, store, false))
+                    checkVersion(sm, store, false)) {
                     exceps = addException(exceps, new OptimisticException(sm.
                         getManagedInstance()));
+                }
             }
         } catch (SQLException se) {
             exceps = addException(exceps, SQLExceptions.getStore(se, dict));

Modified: openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java?rev=713815&r1=713814&r2=713815&view=diff
==============================================================================
--- openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java
(original)
+++ openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/datacache/DataCachePCDataImpl.java
Thu Nov 13 12:45:18 2008
@@ -121,8 +121,8 @@
     }
 
     /**
-     * Store field-level information from the given state manager.
-     * Special process of checking if the cached collection data is out of order.
+     * Store field-level information from the given state manager. Special 
+     * process of checking if the cached collection data is out of order.
      */
     protected void storeField(OpenJPAStateManager sm, FieldMetaData fmd) {
         if (fmd.getManagement() != fmd.MANAGE_PERSISTENT)
@@ -170,8 +170,7 @@
                     Object oid = sm.getContext().getObjectId(sm.fetch(i));
                     DataCachePCData data = cache == null ? null
                         : cache.get(oid);
-                    if ((data != null) &&
-                        (data instanceof DataCachePCDataImpl)) {
+                    if (data != null && (data instanceof DataCachePCDataImpl)) {
                         ((DataCachePCDataImpl) data)
                             .clearData(inverses[j].getIndex());
                     }

Modified: openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/meta/FieldMetaData.java
URL: http://svn.apache.org/viewvc/openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/meta/FieldMetaData.java?rev=713815&r1=713814&r2=713815&view=diff
==============================================================================
--- openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/meta/FieldMetaData.java
(original)
+++ openjpa/branches/1.1.x/openjpa-kernel/src/main/java/org/apache/openjpa/meta/FieldMetaData.java
Thu Nov 13 12:45:18 2008
@@ -1121,6 +1121,7 @@
                         decs[i] = decs[i].substring(0, spc);
                     }
                     orders[i] = getRepository().newOrder(this, decs[i], asc);
+
                     //set "isUsedInOrderBy" to the field
                     ClassMetaData elemCls = getElement()
                         .getDeclaredTypeMetaData();
@@ -2010,25 +2011,21 @@
         _val.setValueMappedBy(mapped);
     }
 
-    public FieldMetaData getValueMappedByMetaData ()
-	{
-		return _val.getValueMappedByMetaData ();
-	}
-
-	public Class getTypeOverride ()
-	{
-		return _val.getTypeOverride ();
-	}
-
-	public void setTypeOverride (Class type)
-	{
-		_val.setTypeOverride (type);
-	}
-
-	public void copy (ValueMetaData vmd)
-	{
-		_val.copy (vmd);
-	}
+    public FieldMetaData getValueMappedByMetaData () {
+        return _val.getValueMappedByMetaData ();
+	  }
+
+    public Class getTypeOverride () {
+		    return _val.getTypeOverride ();
+	  }
+
+    public void setTypeOverride (Class type) {
+		    _val.setTypeOverride (type);
+	  }
+
+    public void copy (ValueMetaData vmd) {
+		    _val.copy (vmd);
+	  }
 
     /**
      * Check if this field is used by other field as "order by" value.
@@ -2036,7 +2033,7 @@
      * @since 1.1.0
      */
     public boolean isUsedInOrderBy() {
-    	return _usedInOrderBy;
+        return _usedInOrderBy;
     }
     
     /**
@@ -2045,14 +2042,14 @@
      * @since 1.1.0
      */
     public void setUsedInOrderBy(boolean isUsed) {
-    	_usedInOrderBy = isUsed;
+        _usedInOrderBy = isUsed;
     }
     
     /**
      * Serializable wrapper around a {@link Method} or {@link Field}. For 
      * space considerations, this does not support {@link Constructor}s.
      */
-	public static class MemberProvider
+    public static class MemberProvider
         implements Externalizable {
 
         private transient Member _member;



Mime
View raw message