|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--org.iges.anagram.AbstractModule
|
+--org.iges.anagram.Catalog
Manages the list of available data objects.
| Field Summary | |
protected static java.lang.String |
CATALOG_FILE
|
protected DirHandle |
root
|
protected ExclusiveLock |
synch
|
protected static java.lang.String |
TEMP_ENTRY_FILE
|
protected long |
tempAgeLimit
|
protected java.util.LinkedList |
tempDeleteQueue
|
protected DirHandle |
tempEntries
|
protected long |
tempEntryLimit
|
protected long |
tempStorage
|
protected long |
tempStorageLimit
|
| Fields inherited from class org.iges.anagram.AbstractModule |
log, moduleName, parent, server |
| Constructor Summary | |
Catalog()
|
|
| Method Summary | |
protected void |
addHandle(DataHandle handle)
Adds a handle to the correct dir, creating it if necessary |
void |
addTemp(TempDataHandle tempData)
Adds a temporary dataset to the catalog. |
protected void |
addTemp(TempDataHandle tempData,
boolean save)
|
protected void |
checkDependencies(DataHandle data)
|
protected void |
checkLimits()
|
void |
clearTemp()
Deletes all temporary entries in the catalog |
void |
configure(Setting setting)
Configures the module according to the settings provided. |
boolean |
contains(java.lang.String path)
Returns true if the catalog contains a handle that matches the given pathname. |
protected Handle |
get(java.lang.String path)
|
protected java.lang.String |
getChildPath(java.lang.String completePath,
DirHandle dir)
Used by add, remove and getDir Takes "basepath[/name1[/name2/../nameN]]" Returns name1 if followed by name2, or "" otherwise |
protected DirHandle |
getDir(java.lang.String path,
DirHandle dir)
Used by add, remove, get, and getParent to look up datasets |
Handle |
getLocked(java.lang.String path)
Retrieves the handle, if any, that maches the given pathname. |
java.lang.String |
getModuleID()
Returns an ID for this module. |
DirHandle |
getParent(Handle handle)
Returns the parent of the handle given. |
protected void |
loadCatalogFromStore()
|
protected void |
loadEntries(java.util.List newEntries)
|
protected void |
loadTempEntriesFromStore()
|
protected boolean |
outdated(TempDataHandle tempData)
|
protected void |
removeHandle(Handle handle)
Removes a handle, removing the parent dir if appropriate. |
protected void |
removeTemp(java.lang.String reason,
TempDataHandle tempHandle)
|
void |
saveCatalogToStore()
|
protected void |
saveTempEntriesToStore()
|
protected void |
unloadEntries(java.util.List newEntries)
|
| Methods inherited from class org.iges.anagram.AbstractModule |
configModule, debug, debug, error, fail, fail, fail, getModuleName, info, init, toString, verbose, verbose |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected static final java.lang.String TEMP_ENTRY_FILE
protected static final java.lang.String CATALOG_FILE
protected ExclusiveLock synch
protected DirHandle root
protected DirHandle tempEntries
protected java.util.LinkedList tempDeleteQueue
protected long tempStorage
protected long tempStorageLimit
protected long tempEntryLimit
protected long tempAgeLimit
| Constructor Detail |
public Catalog()
| Method Detail |
public java.lang.String getModuleID()
Module
getModuleID in interface ModulegetModuleID in class AbstractModule
public void configure(Setting setting)
throws ConfigException
AbstractModule
configure in interface Moduleconfigure in class AbstractModuleConfigExceptionpublic void addTemp(TempDataHandle tempData)
protected void addTemp(TempDataHandle tempData,
boolean save)
protected boolean outdated(TempDataHandle tempData)
protected void checkDependencies(DataHandle data)
public Handle getLocked(java.lang.String path)
public boolean contains(java.lang.String path)
protected Handle get(java.lang.String path)
public void clearTemp()
public DirHandle getParent(Handle handle)
protected DirHandle getDir(java.lang.String path,
DirHandle dir)
protected java.lang.String getChildPath(java.lang.String completePath,
DirHandle dir)
protected void addHandle(DataHandle handle)
protected void removeHandle(Handle handle)
protected void unloadEntries(java.util.List newEntries)
protected void loadEntries(java.util.List newEntries)
protected void loadTempEntriesFromStore()
protected void loadCatalogFromStore()
protected void saveTempEntriesToStore()
public void saveCatalogToStore()
protected void checkLimits()
protected void removeTemp(java.lang.String reason,
TempDataHandle tempHandle)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||