public class CacheManager
extends java.lang.Object
| Constructor and Description |
|---|
CacheManager() |
| Modifier and Type | Method and Description |
|---|---|
static XMLDBModel |
loadFromCache(java.lang.String modelName)
Given a model name, load a model from the cache.
|
static boolean |
removeFromCache(java.util.ArrayList<XMLDBModel> modelsToRemove)
Remove a set of models from the cache.
|
static void |
updateCache(java.util.HashMap assemblies)
Update a collection of models in the cache.
|
public static boolean removeFromCache(java.util.ArrayList<XMLDBModel> modelsToRemove) throws DBConnectionException, DBExecutionException
modelsToRemove - An ArrayList of XMLDBModel objects. The names of these
are used to remove the respective MoMLs from the cache.DBConnectionException - Thrown if a problem occurs with the cache connection.DBExecutionException - Thrown if a problem occurs removing a model from the cache.public static XMLDBModel loadFromCache(java.lang.String modelName) throws DBConnectionException, DBExecutionException
modelName - The name of the model to be loaded form the cache.DBConnectionException - Thrown if a problem occurs with the cache connection.DBExecutionException - Thrown if a problem occurs retrieving the
MoML from the database.public static void updateCache(java.util.HashMap assemblies)
throws DBConnectionException,
DBExecutionException
assemblies - A HashMap that maps a collection of models names to
their respective MoML strings. These are the models to be
updated in the cache.DBConnectionException - Thrown if a problem occurs with the cache connection.DBExecutionException - Thrown if a problem occurs updating the cache.