public abstract class AbstractIndexedFileCacheBacking extends AbstractFileCacheBacking
index
file to keep track of the cached entriesModifier and Type | Class and Description |
---|---|
static class |
AbstractIndexedFileCacheBacking.IndexEntry
The default index entry in the index file
|
Modifier and Type | Field and Description |
---|---|
protected static AbstractIndexedFileCacheBacking.IndexEntry[] |
EMPTY_INDEX |
protected static java.lang.String[] |
EMPTY_KEYS |
static java.lang.String |
INDEX_FILE
Default name of cache index file - assumed to contain
AbstractIndexedFileCacheBacking.IndexEntry -s |
WEAVED_CLASS_CACHE_DIR
logger
Modifier | Constructor and Description |
---|---|
protected |
AbstractIndexedFileCacheBacking(java.io.File cacheDir) |
Modifier and Type | Method and Description |
---|---|
static AbstractIndexedFileCacheBacking.IndexEntry |
createIndexEntry(CachedClassEntry classEntry,
byte[] originalBytes) |
protected abstract java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> |
getIndex() |
java.io.File |
getIndexFile() |
java.lang.String[] |
getKeys(java.lang.String regex)
Return a list of keys which match the given
regex.
|
protected java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> |
readIndex() |
AbstractIndexedFileCacheBacking.IndexEntry[] |
readIndex(java.io.File indexFile) |
protected java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> |
readIndex(java.io.File cacheDir,
java.io.File cacheFile) |
protected AbstractIndexedFileCacheBacking.IndexEntry |
resolveIndexMapEntry(java.io.File cacheDir,
AbstractIndexedFileCacheBacking.IndexEntry ie) |
protected void |
writeIndex() |
protected void |
writeIndex(java.io.File file) |
protected void |
writeIndex(java.io.File indexFile,
AbstractIndexedFileCacheBacking.IndexEntry... entries) |
protected void |
writeIndex(java.io.File indexFile,
java.util.Collection<? extends AbstractIndexedFileCacheBacking.IndexEntry> entries) |
protected void |
writeIndex(java.io.File indexFile,
java.util.Map<java.lang.String,? extends AbstractIndexedFileCacheBacking.IndexEntry> index) |
close, close, delete, getCacheDirectory, writeClassBytes
crc
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
clear, get, put, remove
public static final java.lang.String INDEX_FILE
AbstractIndexedFileCacheBacking.IndexEntry
-sprotected static final AbstractIndexedFileCacheBacking.IndexEntry[] EMPTY_INDEX
protected static final java.lang.String[] EMPTY_KEYS
protected AbstractIndexedFileCacheBacking(java.io.File cacheDir)
public java.io.File getIndexFile()
public java.lang.String[] getKeys(java.lang.String regex)
CacheBacking
protected java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> readIndex()
protected void writeIndex()
protected void writeIndex(java.io.File file)
protected abstract java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> getIndex()
protected java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> readIndex(java.io.File cacheDir, java.io.File cacheFile)
protected AbstractIndexedFileCacheBacking.IndexEntry resolveIndexMapEntry(java.io.File cacheDir, AbstractIndexedFileCacheBacking.IndexEntry ie)
public AbstractIndexedFileCacheBacking.IndexEntry[] readIndex(java.io.File indexFile)
protected void writeIndex(java.io.File indexFile, java.util.Map<java.lang.String,? extends AbstractIndexedFileCacheBacking.IndexEntry> index) throws java.io.IOException
java.io.IOException
protected void writeIndex(java.io.File indexFile, AbstractIndexedFileCacheBacking.IndexEntry... entries) throws java.io.IOException
java.io.IOException
protected void writeIndex(java.io.File indexFile, java.util.Collection<? extends AbstractIndexedFileCacheBacking.IndexEntry> entries) throws java.io.IOException
java.io.IOException
public static final AbstractIndexedFileCacheBacking.IndexEntry createIndexEntry(CachedClassEntry classEntry, byte[] originalBytes)