User: starksm 
  Date: 02/04/13 13:25:01

  Modified:    src/main/org/jboss/util LRUCachePolicy.java
  Log:
  Clear the cache list.
  Utility methods for jars.
  
  Revision  Changes    Path
  1.3       +12 -1     jboss-common/src/main/org/jboss/util/LRUCachePolicy.java
  
  Index: LRUCachePolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-common/src/main/org/jboss/util/LRUCachePolicy.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LRUCachePolicy.java       28 Feb 2002 04:02:45 -0000      1.2
  +++ LRUCachePolicy.java       13 Apr 2002 20:25:01 -0000      1.3
  @@ -13,7 +13,7 @@
    * Implementation of a Least Recently Used cache policy.
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Simone Bordet</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public class LRUCachePolicy
      implements CachePolicy
  @@ -109,6 +109,10 @@
       */
      public void destroy()
      {
  +      if( m_map != null )
  +         m_map.clear();
  +      if( m_list != null )
  +         m_list.clear();
      }
   
      public Object get(Object key)
  @@ -397,6 +401,13 @@
          * @param oldCapacity the capacity before the change happened
          */
         protected void capacityChanged(int oldCapacity) {}
  +
  +      protected void clear()
  +      {
  +         m_head = null;
  +         m_tail = null;
  +         m_count = 0;         
  +      }
   
         public String toString()
         {
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to