Package org.biojava.nbio.core.util
Class FlatFileCache
- java.lang.Object
-
- org.biojava.nbio.core.util.FlatFileCache
-
public class FlatFileCache extends java.lang.Object
Provides a cache for storing multiple small files in memory. Can be used to e.g cache gzip compressed PDB files for avoiding disk IO bottlenecks.- Author:
- Andreas Prlic.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
addToCache(java.lang.String key, java.io.File fileToCache)
void
clear()
static void
destroy()
static java.io.InputStream
getInputStream(java.lang.String key)
static FlatFileCache
getInstance()
int
size()
-
-
-
Method Detail
-
getInstance
public static FlatFileCache getInstance()
-
addToCache
public static void addToCache(java.lang.String key, java.io.File fileToCache)
-
getInputStream
public static java.io.InputStream getInputStream(java.lang.String key)
-
size
public int size()
-
clear
public void clear()
-
destroy
public static void destroy()
-
-