|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.stanwood.media.xml.XMLParser
org.stanwood.media.actions.SeenDatabase
public class SeenDatabase
This class is used to maintain a list of files that have been seen by the actions in media directories
Field Summary |
---|
Fields inherited from class org.stanwood.media.xml.XMLParser |
---|
DTD_WEB_LOCATION, SCHEMA_WEB_LOCATION |
Constructor Summary | |
---|---|
SeenDatabase(java.io.File configDir)
The constructor |
Method Summary | |
---|---|
boolean |
isSeen(java.io.File mediaDirectory,
java.io.File file)
Used to work out if a file has been seen already |
void |
markAsSeen(java.io.File mediaDirectory,
java.io.File file)
Used to mark a file as seen after actions have seen it |
void |
read(IProgressMonitor progress)
Used to read the database from disk |
void |
removeFile(java.io.File mediaDirectory,
java.io.File file)
Used to remove files from the Seen database |
void |
renamedFile(java.io.File mediaDirectory,
java.io.File oldFile,
java.io.File newFile)
Used to notify the seen database when a file has been renamed |
void |
write(IProgressMonitor parentMonitor)
Used to write the database to disc |
Methods inherited from class org.stanwood.media.xml.XMLParser |
---|
createDocBuilder, createFactory, deleteNode, domToStr, encodeAttributeValue, firstChild, getAttribute, getElement, getFirstChildElement, getFloatFromXML, getIntegerFromXML, getLastChildElement, getLongFromXML, getSchema, getStringFromXML, getStringFromXMLOrNull, getURLFromXML, getURLFromXMLOrNull, hasNode, parse, parse, parse, quoteXPathQuery, selectChildNodes, selectNodeList, selectSingleNode, strToDom, strToDom, strToDom, writeXML |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SeenDatabase(java.io.File configDir)
configDir
- The configuration directoryMethod Detail |
---|
public boolean isSeen(java.io.File mediaDirectory, java.io.File file)
mediaDirectory
- The media directory the file lives infile
- The file
public void markAsSeen(java.io.File mediaDirectory, java.io.File file)
mediaDirectory
- The media directory the file lives infile
- The filepublic void write(IProgressMonitor parentMonitor) throws java.io.FileNotFoundException
parentMonitor
- Parent progress monitor
java.io.FileNotFoundException
- Thrown if their is a problempublic void read(IProgressMonitor progress) throws java.io.FileNotFoundException, XMLParserException
progress
- Progress monitor
java.io.FileNotFoundException
- Thrown if their is a problem
XMLParserException
- Thrown if possible to parse filepublic void renamedFile(java.io.File mediaDirectory, java.io.File oldFile, java.io.File newFile)
mediaDirectory
- The media directory the file is located inoldFile
- The old filenamenewFile
- The new filenamepublic void removeFile(java.io.File mediaDirectory, java.io.File file)
mediaDirectory
- The media directory of the file to removefile
- The file to remove
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |