Examples of LRUCache


Examples of org.eclipse.jdt.internal.core.util.LRUCache

      this.rawClasspathStatus = newRawClasspathStatus;
      this.resolvedClasspath = newResolvedClasspath;
      this.rootPathToRawEntries = newRootPathToRawEntries;
      this.rootPathToResolvedEntries = newRootPathToResolvedEntries;
      this.unresolvedEntryStatus = newUnresolvedEntryStatus;
      this.javadocCache = new LRUCache(JAVADOC_CACHE_INITIAL_SIZE);

      return classpathChange;
    }
View Full Code Here

Examples of org.eclipse.jdt.internal.core.util.LRUCache

    default:
      this.childrenCache.remove(element);
  }
}
protected void resetJarTypeCache() {
  this.jarTypeCache = new LRUCache((int) (DEFAULT_OPENABLE_SIZE * getMemoryRatio()));
}
 
View Full Code Here

Examples of org.enhydra.jdbc.util.LRUCache

   */
  void returnToCache(Object key, Connection theCon) {
    Object value = inUse.remove(key);
    // remove key/value from used statements
    if (value != null) {
      LRUCache theCache =
        (LRUCache) masterPrepStmtCache.get(theCon.toString());
      theCache.put(key, value); // place back in cache, ready for re-use
    }
  }
View Full Code Here

Examples of org.exist.storage.cache.LRUCache

        super(pool, id, true, pool.getCacheManager(), 0.01);
        lock = new ReentrantReadWriteLock(getFileName());
        fileHeader = (BTreeFileHeader)getFileHeader();
        fileHeader.setPageCount(0);
        fileHeader.setTotalCount(0);
        dataCache = new LRUCache(256, 0.0, 1.0, CacheManager.DATA_CACHE);
        dataCache.setFileName(getFileName());
        cacheManager.registerCache(dataCache);
        final File file = new File(dataDir + File.separatorChar + getFileName());
        setFile(file);
        if (exists()) {
View Full Code Here

Examples of org.logicblaze.lingo.util.LRUCache

     * Factory method to create the metadata object for the given method
     */
    protected abstract MethodMetadata createMethodMetadata(Method method);

    protected Map createCache() {
        return new LRUCache(getCacheSize());
    }
View Full Code Here

Examples of org.pdf4j.saxon.sort.LRUCache

     * @return true if the string is a valid URI
     */

    public static boolean isValidURI(CharSequence value) {

        LRUCache cache = (LRUCache)caches.get();
        if (cache == null) {
            cache = new LRUCache(10);
            caches.set(cache);
        }

        if (cache.get(value) != null) {
            return true;
        }

        String sv = Whitespace.trim(value);

        // Allow zero-length strings (RFC2396 is ambivalent on this point)
        if (sv.length() == 0) {
            return true;
        }

        // Allow a string if the java.net.URI class accepts it
        try {
            new URI(sv);
            cache.put(value, value);
            return true;
        } catch (URISyntaxException e) {
            // keep trying
            // Note: it's expensive to throw exceptions on a success path, so we keep a cache.
        }

        // Allow a string if it can be escaped into a form that java.net.URI accepts
        sv = EscapeURI.iriToUri(sv).toString();
        try {
            new URI(sv);
            cache.put(value, value);
            return true;
        } catch (URISyntaxException e) {
            return false;
        }
    }
View Full Code Here

Examples of org.teiid.core.util.LRUCache

  protected IndexSummary summary;

  public BlocksIndexInput(VirtualFile inputFile) {
    this.indexFile= inputFile;
    blockCache= new LRUCache(CACHE_SIZE);
  }
View Full Code Here

Examples of org.teiid.core.util.LRUCache

   
  /**
   * @see IndexInput#clearCache()
   */
  public void clearCache() {
    blockCache= new LRUCache(CACHE_SIZE);
  }
View Full Code Here

Examples of xbird.util.cache.algorithm.LRUCache

    public Cache buildCache(String regionName, Properties properties) {
        String v = properties.getProperty(CacheFactory.PROP_MAX_CACHE_ENTRIES);
        String maxEntries = (v == null) ? DEFAULT_MAX_CACHE_ENTRIES : v;
        if (maxEntries != null) {
            int m = new Integer(maxEntries).intValue();
            return new LRUCache(regionName, m);
        } else {
            return new LRUCache(regionName);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.