src/main/java/org/jboss/util/LRUCachePolicy.java
/**
       * Demotes from the cache the least used entry. <br>
       * If the cache is not full, does nothing.
       * @see #promote
       */
Demotes from the cache the least used entry. 
If the cache is not full, does nothing.
@see #promote
Demotes from the cache the least used entry . If the cache is not full does nothing . @see #promote
protected void demote()
      {
         if (m_capacity < 1) {throw new IllegalStateException("Can't work with capacity < 1");}
         if (m_count > m_maxCapacity) {throw new IllegalStateException("Cache list entries number (" + m_count + ") > than the maximum allowed (" + m_maxCapacity + ")");}
         if (m_count == m_maxCapacity)
         {
            LRUCacheEntry entry = m_tail;
            ageOut(entry);
         }
         else {} 
      }
protected void demote ( ) { if ( m_capacity < 1 ) { throw new IllegalStateException ( "Can't work with capacity < 1" ) ; } if ( m_count > m_maxCapacity ) { throw new IllegalStateException ( "Cache list entries number (" + m_count + ") > than the maximum allowed (" + m_maxCapacity + ")" ) ; } if ( m_count == m_maxCapacity ) { LRUCacheEntry entry = m_tail ; ageOut ( entry ) ; } else { } }
Demotes from the cache the least used entry.
Demotes from the cache the least used entry .
// the entry will be removed by ageOut // cache is not full, do nothing