|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.rssowl.util.archive.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 | |
File |
createUniqueArchiveFile()
Create a unique archive file to save an archive item |
private void |
deleteArchiveFile(String fileName)
Delete a file from the archive |
private void |
deleteIndex()
Delete the index file |
Archive |
getArchive()
|
private boolean |
isArchiveFileExisting(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(String feedurl)
Load an archive item from the archive |
private ArchiveIndex |
loadIndex()
Load the archive index |
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 |
shutdown()
Shutdown process |
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 File createUniqueArchiveFile() throws IOException
IOException
- If an error occurspublic Archive getArchive()
public Archive loadArchive()
public void saveArchive()
public void shutdown()
public void startup()
private void deleteArchiveFile(String fileName)
fileName
- The file to deleteprivate void deleteIndex()
private boolean isArchiveFileExisting(String fileName)
fileName
- The name of the file
private boolean isIndexExisting()
private ArchiveItem loadArchiveItem(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 |