Package org.aspectj.weaver.tools.cache
Class ZippedFileCacheBacking
- java.lang.Object
-
- org.aspectj.weaver.tools.cache.AbstractCacheBacking
-
- org.aspectj.weaver.tools.cache.AbstractFileCacheBacking
-
- org.aspectj.weaver.tools.cache.AbstractIndexedFileCacheBacking
-
- org.aspectj.weaver.tools.cache.AsynchronousFileCacheBacking
-
- org.aspectj.weaver.tools.cache.ZippedFileCacheBacking
-
- All Implemented Interfaces:
CacheBacking
public class ZippedFileCacheBacking extends AsynchronousFileCacheBacking
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.aspectj.weaver.tools.cache.AsynchronousFileCacheBacking
AsynchronousFileCacheBacking.AbstractCommand, AsynchronousFileCacheBacking.AsyncCommand, AsynchronousFileCacheBacking.AsynchronousFileCacheBackingCreator<T extends AsynchronousFileCacheBacking>, AsynchronousFileCacheBacking.ClearCommand, AsynchronousFileCacheBacking.InsertCommand, AsynchronousFileCacheBacking.KeyedCommand, AsynchronousFileCacheBacking.RemoveCommand, AsynchronousFileCacheBacking.UpdateIndexCommand
-
Nested classes/interfaces inherited from class org.aspectj.weaver.tools.cache.AbstractIndexedFileCacheBacking
AbstractIndexedFileCacheBacking.IndexEntry
-
-
Field Summary
Fields Modifier and Type Field Description static StringZIP_FILE-
Fields inherited from class org.aspectj.weaver.tools.cache.AsynchronousFileCacheBacking
bytesMap, exposedBytes, exposedIndex, index
-
Fields inherited from class org.aspectj.weaver.tools.cache.AbstractIndexedFileCacheBacking
EMPTY_INDEX, EMPTY_KEYS, INDEX_FILE
-
Fields inherited from class org.aspectj.weaver.tools.cache.AbstractFileCacheBacking
WEAVED_CLASS_CACHE_DIR
-
Fields inherited from class org.aspectj.weaver.tools.cache.AbstractCacheBacking
logger
-
-
Constructor Summary
Constructors Constructor Description ZippedFileCacheBacking(File cacheDir)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ZippedFileCacheBackingcreateBacking(File cacheDir)FilegetZipFile()protected Map<String,byte[]>readClassBytes(Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, File cacheDir)static Map<String,byte[]>readZipClassBytes(File file)protected voidremoveClassBytes(String key)protected AbstractIndexedFileCacheBacking.IndexEntryresolveIndexMapEntry(File cacheDir, AbstractIndexedFileCacheBacking.IndexEntry ie)protected booleansyncClassBytesEntries(File dataFile, Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, Map<String,byte[]> entriesMap)protected Collection<String>syncIndexEntries(File dataFile, Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, Map<String,byte[]> entriesMap)protected voidwriteClassBytes(String key, byte[] bytes)static voidwriteZipClassBytes(File file, Map<String,byte[]> entriesMap)-
Methods inherited from class org.aspectj.weaver.tools.cache.AsynchronousFileCacheBacking
clear, createBacking, executeClearCommand, executeCommand, executeInsertCommand, executeRemoveCommand, executeUpdateIndexCommand, get, getBytesMap, getIndex, getIndexEntries, getIndexMap, postCacheCommand, put, remove, remove, toString
-
Methods inherited from class org.aspectj.weaver.tools.cache.AbstractIndexedFileCacheBacking
createIndexEntry, getIndexFile, getKeys, readIndex, readIndex, readIndex, writeIndex, writeIndex, writeIndex, writeIndex, writeIndex
-
Methods inherited from class org.aspectj.weaver.tools.cache.AbstractFileCacheBacking
close, close, delete, getCacheDirectory
-
Methods inherited from class org.aspectj.weaver.tools.cache.AbstractCacheBacking
crc
-
-
-
-
Field Detail
-
ZIP_FILE
public static final String ZIP_FILE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ZippedFileCacheBacking
public ZippedFileCacheBacking(File cacheDir)
-
-
Method Detail
-
getZipFile
public File getZipFile()
-
createBacking
public static final ZippedFileCacheBacking createBacking(File cacheDir)
-
writeClassBytes
protected void writeClassBytes(String key, byte[] bytes) throws Exception
- Overrides:
writeClassBytesin classAbstractFileCacheBacking- Throws:
Exception
-
removeClassBytes
protected void removeClassBytes(String key) throws Exception
- Specified by:
removeClassBytesin classAsynchronousFileCacheBacking- Throws:
Exception
-
readClassBytes
protected Map<String,byte[]> readClassBytes(Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, File cacheDir)
- Specified by:
readClassBytesin classAsynchronousFileCacheBacking
-
syncIndexEntries
protected Collection<String> syncIndexEntries(File dataFile, Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, Map<String,byte[]> entriesMap)
-
syncClassBytesEntries
protected boolean syncClassBytesEntries(File dataFile, Map<String,AbstractIndexedFileCacheBacking.IndexEntry> indexMap, Map<String,byte[]> entriesMap)
-
resolveIndexMapEntry
protected AbstractIndexedFileCacheBacking.IndexEntry resolveIndexMapEntry(File cacheDir, AbstractIndexedFileCacheBacking.IndexEntry ie)
- Overrides:
resolveIndexMapEntryin classAbstractIndexedFileCacheBacking
-
readZipClassBytes
public static final Map<String,byte[]> readZipClassBytes(File file) throws IOException
- Throws:
IOException
-
writeZipClassBytes
public static final void writeZipClassBytes(File file, Map<String,byte[]> entriesMap) throws IOException
- Throws:
IOException
-
-