protected void cleanCache(long timeWindow){
  long currentTime=System.currentTimeMillis();
  Enumeration keys=timestamps.keys();
  while (keys.hasMoreElements()) {
    Object tester=keys.nextElement();
    Long time=(Long)timestamps.get(tester);
    if ((currentTime - time.longValue()) >= timeWindow) {
      caches.remove(tester);
      timestamps.remove(tester);
      viewAttributeLists.remove(tester);
      if (Debug.debugging("crfp")) {
        Debug.output("Expired cache, removing, have " + caches.size() + " caches left.");
      }
    }
  }
}

protected void cleanCache ( long timeWindow ) { long currentTime = System . currentTimeMillis ( ) ; Enumeration keys = timestamps . keys ( ) ; while ( keys . hasMoreElements ( ) ) { Object tester = keys . nextElement ( ) ; Long time = ( Long ) timestamps . get ( tester ) ; if ( ( currentTime - time . longValue ( ) ) >= timeWindow ) { caches . remove ( tester ) ; timestamps . remove ( tester ) ; viewAttributeLists . remove ( tester ) ; if ( Debug . debugging ( "crfp" ) ) { Debug . output ( "Expired cache, removing, have " + caches . size ( ) + " caches left." ) ; } } } }
get rid of any cache that is older than the time window .
