|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.rssowl.util.archive.ArchiveManager
public class ArchiveManager
The ArchiveManager handles loading and saving of the archive on startup and shutdown. Its the maincontroller of the whole archive and other objects from RSSOwl access the archive through this class.
| Field Summary | |
|---|---|
private Archive |
archive
|
private org.jdom.input.SAXBuilder |
builder
|
(package private) ArchiveIndex |
index
|
| Constructor Summary | |
|---|---|
ArchiveManager()
Instantiate a new ArchiveManager |
|
| Method Summary | |
|---|---|
java.io.File |
createUniqueArchiveFile()
Create a unique archive file to save an archive item |
private void |
deleteArchiveFile(java.lang.String fileName)
Delete a file from the archive |
void |
flush()
Sync all changes to the Archive with the File-System. |
Archive |
getArchive()
|
private boolean |
isArchiveFileExisting(java.lang.String fileName)
Check if the given archive file is existing |
private boolean |
isIndexExisting()
Check if the index file is exsiting |
Archive |
loadArchive()
Load the archive |
private ArchiveItem |
loadArchiveItem(java.lang.String feedurl)
Load an archive item from the archive |
private ArchiveIndex |
loadIndex()
Load the archive index |
private void |
saveArchive()
Save all archive items |
private void |
saveArchiveItem(ArchiveItem archiveItem)
Save an archiveitem to a unique file |
private void |
saveIndex()
Save the archive index |
void |
startup()
Startup process |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private Archive archive
private org.jdom.input.SAXBuilder builder
ArchiveIndex index
| Constructor Detail |
|---|
public ArchiveManager()
| Method Detail |
|---|
public java.io.File createUniqueArchiveFile()
throws java.io.IOException
java.io.IOException - If an error occurspublic Archive getArchive()
public Archive loadArchive()
private void saveArchive()
public void flush()
public void startup()
private void deleteArchiveFile(java.lang.String fileName)
fileName - The file to deleteprivate boolean isArchiveFileExisting(java.lang.String fileName)
fileName - The name of the file
private boolean isIndexExisting()
private ArchiveItem loadArchiveItem(java.lang.String feedurl)
feedurl - The URL of the feed
private ArchiveIndex loadIndex()
private void saveArchiveItem(ArchiveItem archiveItem)
archiveItem - An archive item that contains severyl archive entriesprivate void saveIndex()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||