db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject svn commit: r489820 - in /db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer: MtoNCollectionPrefetcher.java ReferencePrefetcher.java RsIterator.java
Date Sat, 23 Dec 2006 01:35:49 GMT
Author: arminw
Date: Fri Dec 22 17:35:48 2006
New Revision: 489820

URL: http://svn.apache.org/viewvc?view=rev&rev=489820
Log:
minor improvement, avoid redundant method calls

Modified:
    db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/MtoNCollectionPrefetcher.java
    db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/ReferencePrefetcher.java
    db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/RsIterator.java

Modified: db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/MtoNCollectionPrefetcher.java
URL: http://svn.apache.org/viewvc/db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/MtoNCollectionPrefetcher.java?view=diff&rev=489820&r1=489819&r2=489820
==============================================================================
--- db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/MtoNCollectionPrefetcher.java
(original)
+++ db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/MtoNCollectionPrefetcher.java
Fri Dec 22 17:35:48 2006
@@ -413,8 +413,8 @@
         CollectionDescriptor cds = getCollectionDescriptor();
         PersistentField field = cds.getPersistentField();
         PersistenceBroker pb = getBroker();
-        Class ownerTopLevelClass = pb.getTopLevelClass(getOwnerClassDescriptor().getClassOfObject());
-        Class childTopLevelClass = pb.getTopLevelClass(getItemClassDescriptor().getClassOfObject());
+        Class ownerTopLevelClass = getOwnerClassDescriptor().getTopLevelClass();
+        Class childTopLevelClass = getItemClassDescriptor().getTopLevelClass();
         Class collectionClass = cds.getCollectionClass(); // this collection type will be
used:
         HashMap childMap = new HashMap();
         HashMap ownerIdsToLists = new HashMap();

Modified: db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/ReferencePrefetcher.java
URL: http://svn.apache.org/viewvc/db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/ReferencePrefetcher.java?view=diff&rev=489820&r1=489819&r2=489820
==============================================================================
--- db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/ReferencePrefetcher.java
(original)
+++ db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/ReferencePrefetcher.java
Fri Dec 22 17:35:48 2006
@@ -63,7 +63,7 @@
         Identity id;
         PersistenceBroker pb = getBroker();
         PersistentField field = ord.getPersistentField();
-        Class topLevelClass = pb.getTopLevelClass(ord.getItemClass());
+        Class topLevelClass = ord.getItemClassDescriptor().getTopLevelClass();
         HashMap childrenMap = new HashMap(children.size());
 
 
@@ -113,7 +113,7 @@
         Collection queries = new ArrayList(owners.size());
         Collection idsSubset = new HashSet(owners.size());
         Iterator iter = owners.iterator();
-        Class topLevelClass = getBroker().getTopLevelClass(ord.getItemClass());
+        Class topLevelClass = ord.getItemClassDescriptor().getTopLevelClass();
         Object[] fkValues;
         Object owner;
         Identity id;

Modified: db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/RsIterator.java
URL: http://svn.apache.org/viewvc/db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/RsIterator.java?view=diff&rev=489820&r1=489819&r2=489820
==============================================================================
--- db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/RsIterator.java
(original)
+++ db/ojb/branches/OJB_1_0_RELEASE/src/java/org/apache/ojb/broker/accesslayer/RsIterator.java
Fri Dec 22 17:35:48 2006
@@ -216,7 +216,7 @@
     {
         if (m_itemTopLevelClass == null)
         {
-            m_itemTopLevelClass = getBroker().getTopLevelClass(getQueryObject().getClassDescriptor().getClassOfObject());
+            m_itemTopLevelClass = getQueryObject().getClassDescriptor().getTopLevelClass();
         }
         return m_itemTopLevelClass;
     }



---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message