public class FlatFileCacheBacking extends AsynchronousFileCacheBacking
AsynchronousFileCacheBacking.AbstractCommand, AsynchronousFileCacheBacking.AsyncCommand, AsynchronousFileCacheBacking.AsynchronousFileCacheBackingCreator<T extends AsynchronousFileCacheBacking>, AsynchronousFileCacheBacking.ClearCommand, AsynchronousFileCacheBacking.InsertCommand, AsynchronousFileCacheBacking.KeyedCommand, AsynchronousFileCacheBacking.RemoveCommand, AsynchronousFileCacheBacking.UpdateIndexCommand
AbstractIndexedFileCacheBacking.IndexEntry
bytesMap, exposedBytes, exposedIndex, index
EMPTY_INDEX, EMPTY_KEYS, INDEX_FILE
WEAVED_CLASS_CACHE_DIR
logger
Constructor and Description |
---|
FlatFileCacheBacking(java.io.File cacheDir) |
Modifier and Type | Method and Description |
---|---|
static FlatFileCacheBacking |
createBacking(java.io.File cacheDir) |
protected java.util.Map<java.lang.String,byte[]> |
readClassBytes(java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap,
java.io.File cacheDir) |
protected java.util.Map<java.lang.String,byte[]> |
readClassBytes(java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap,
java.io.File[] files) |
protected void |
removeClassBytes(java.lang.String key)
|
protected AbstractIndexedFileCacheBacking.IndexEntry |
resolveIndexMapEntry(java.io.File cacheDir,
AbstractIndexedFileCacheBacking.IndexEntry ie) |
protected void |
writeClassBytes(java.lang.String key,
byte[] bytes) |
clear, createBacking, executeClearCommand, executeCommand, executeInsertCommand, executeRemoveCommand, executeUpdateIndexCommand, get, getBytesMap, getIndex, getIndexEntries, getIndexMap, postCacheCommand, put, remove, remove, toString
createIndexEntry, getIndexFile, getKeys, readIndex, readIndex, readIndex, writeIndex, writeIndex, writeIndex, writeIndex, writeIndex
close, close, delete, getCacheDirectory
crc
public static final FlatFileCacheBacking createBacking(java.io.File cacheDir)
protected java.util.Map<java.lang.String,byte[]> readClassBytes(java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, java.io.File cacheDir)
readClassBytes
in class AsynchronousFileCacheBacking
protected java.util.Map<java.lang.String,byte[]> readClassBytes(java.util.Map<java.lang.String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, java.io.File[] files)
protected AbstractIndexedFileCacheBacking.IndexEntry resolveIndexMapEntry(java.io.File cacheDir, AbstractIndexedFileCacheBacking.IndexEntry ie)
resolveIndexMapEntry
in class AbstractIndexedFileCacheBacking
protected void writeClassBytes(java.lang.String key, byte[] bytes) throws java.lang.Exception
writeClassBytes
in class AbstractFileCacheBacking
java.lang.Exception
protected void removeClassBytes(java.lang.String key) throws java.lang.Exception
AsynchronousFileCacheBacking
removeClassBytes
in class AsynchronousFileCacheBacking
key
- The key representing the class whose bytes are to be removedjava.lang.Exception
- if failed to remove class bytes