db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/broker/cache CacheManager.java CacheStrategy.java
Date Fri, 26 Nov 2004 19:42:24 GMT
arminw      2004/11/26 11:42:24

  Modified:    src/java/org/apache/ojb/broker/cache CacheManager.java
                        CacheStrategy.java
  Log:
  minor changes + javadoc
  
  Revision  Changes    Path
  1.2       +8 -5      db-ojb/src/java/org/apache/ojb/broker/cache/CacheManager.java
  
  Index: CacheManager.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/cache/CacheManager.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CacheManager.java	11 Aug 2004 00:42:56 -0000	1.1
  +++ CacheManager.java	26 Nov 2004 19:42:24 -0000	1.2
  @@ -199,12 +199,15 @@
       {
           synchronized (dummy)
           {
  -            Iterator it = cachesForClasses.keySet().iterator();
  +            Iterator it = cachesForClasses.entrySet().iterator();
  +            Map.Entry entry;
               while (it.hasNext())
               {
  -                Class key = (Class) it.next();
  -                CacheStrategy listener = (CacheStrategy) manager.getCacheFor(key);
  -                CacheStrategy registry = getCacheFor(key);
  +                entry = (Map.Entry) it.next();
  +                Class key = (Class) entry.getKey();
  +                CacheStrategy registry = (CacheStrategy) entry.getValue();
  +
  +                CacheStrategy listener = manager.getCacheFor(key);
                   registry.addInvalidationListener(listener);
                   if (viceVersa)
                   {
  
  
  
  1.2       +3 -2      db-ojb/src/java/org/apache/ojb/broker/cache/CacheStrategy.java
  
  Index: CacheStrategy.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/cache/CacheStrategy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CacheStrategy.java	11 Aug 2004 00:42:56 -0000	1.1
  +++ CacheStrategy.java	26 Nov 2004 19:42:24 -0000	1.2
  @@ -67,7 +67,8 @@
       public ObjectCache getObjectCache();
   
       /**
  -     * Add an {@link InvalidationListener} to this cache strategy.
  +     * Add an {@link InvalidationListener} to this cache strategy. The implementation
  +     * have to ignore double added listener.
        *
        * @param listener The listener to add.
        */
  
  
  

---------------------------------------------------------------------
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