org.aspectj.org.eclipse.jdt.internal.core
Class ElementCache
java.lang.Object
org.aspectj.org.eclipse.jdt.internal.core.util.LRUCache
org.aspectj.org.eclipse.jdt.internal.core.OverflowingLRUCache
org.aspectj.org.eclipse.jdt.internal.core.ElementCache
- All Implemented Interfaces:
- java.lang.Cloneable
- Direct Known Subclasses:
- VerboseElementCache
public class ElementCache
- extends OverflowingLRUCache
An LRU cache of JavaElements.
|
Constructor Summary |
ElementCache(int size)
Constructs a new element cache of the given size. |
ElementCache(int size,
int overflow)
Constructs a new element cache of the given size. |
| Methods inherited from class org.aspectj.org.eclipse.jdt.internal.core.OverflowingLRUCache |
clone, elements, fillingRatio, getEntryTable, getLoadFactor, getOverflow, makeSpace, printStats, privateRemoveEntry, privateRemoveEntry, put, remove, setLoadFactor, setSpaceLimit, shrink, toString, updateTimestamp |
| Methods inherited from class org.aspectj.org.eclipse.jdt.internal.core.util.LRUCache |
flush, flush, get, getCurrentSpace, getKey, getNewestTimestampCounter, getOldestElement, getOldestTimestampCounter, getSpaceLimit, keys, keysAndValues, newInstance, peek, privateAdd, privateAddEntry, removeKey, spaceFor, toStringContents, toStringFillingRation |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ElementCache
public ElementCache(int size)
- Constructs a new element cache of the given size.
ElementCache
public ElementCache(int size,
int overflow)
- Constructs a new element cache of the given size.
close
protected boolean close(LRUCache.LRUCacheEntry entry)
- Returns true if the element is successfully closed and
removed from the cache, otherwise false.
NOTE: this triggers an external removal of this element
by closing the element.
- Specified by:
close in class OverflowingLRUCache
ensureSpaceLimit
protected void ensureSpaceLimit(java.lang.Object info,
IJavaElement parent)
newInstance
protected LRUCache newInstance(int size,
int newOverflow)
- Description copied from class:
OverflowingLRUCache
- Returns a new instance of the reciever.
- Specified by:
newInstance in class OverflowingLRUCache
resetSpaceLimit
protected void resetSpaceLimit(int defaultLimit,
IJavaElement parent)