public class Archiver
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
imgName_Thumbnail_GIF_I |
static java.lang.String |
imgName_Thumbnail_GIF_R |
static java.lang.String |
imgName_Thumbnail_Static_I |
static java.lang.String |
imgName_Thumbnail_Static_R |
| Constructor and Description |
|---|
Archiver(java.lang.String propertyFilename)
Class constructor specifying the local directory to be used.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkStorageAccessibility()
Checks that the archive volume is accessible.
|
int |
deleteRecordFromIIS(java.lang.String archiveEventPath)
Prompts the IIS to delete the event record with the specified name.
|
java.lang.String |
getRootStoragePath() |
java.lang.String |
getRootTransferPath() |
double |
getStorageTotalSpace()
Returns the total space of the archive volume in GB.
|
double |
getStorageUsableSpace()
Returns the usable space of the archive volume in GB.
|
int |
informServer(java.lang.String eventName,
java.lang.String eventDirPath,
java.lang.String eventCompressedPath,
EventRecord event)
Informs the IIS about a new Event Record, or updates the information of an existing one.
|
int |
informServerNewEvent(java.lang.String archiveEventPath,
EventRecord event)
Informs the IIS of a new archived Event Record.
|
int |
insertIntoDatabase(EventRecord event,
java.lang.String eventName,
java.lang.String eventDirectory,
boolean archived,
int informID)
Inserts the event information in the database.
|
java.util.ArrayList<java.lang.String> |
loadReceivedFiles() |
int |
saveNewRecord(java.lang.String recordDirname)
Does neither inform the website, nor save record into database.
|
int |
saveNewRecord(java.lang.String recordDirname,
boolean informWeb,
boolean insertDB)
Saves a record for an event from the temporary directory to the archive.
|
int |
updateFitsInArchive(EventRecord event,
java.lang.String eventName) |
int |
updateServer(int id,
java.lang.String eventName,
java.lang.String eventDirPath,
java.lang.String eventCompressedPath,
EventRecord event)
Informs the IIS about a new Event Record, or updates the information of an existing one.
|
int |
updateServerEvent(int id,
java.lang.String archiveEventPath,
EventRecord event)
Informs the IIS of a new archived Event Record.
|
public static final java.lang.String imgName_Thumbnail_Static_R
public static final java.lang.String imgName_Thumbnail_Static_I
public static final java.lang.String imgName_Thumbnail_GIF_R
public static final java.lang.String imgName_Thumbnail_GIF_I
public Archiver(java.lang.String propertyFilename)
propertyFilename - the name of the property filepublic int saveNewRecord(java.lang.String recordDirname,
boolean informWeb,
boolean insertDB)
insertDB - insertDB2 - public int saveNewRecord(java.lang.String recordDirname)
recordDirname - public int informServerNewEvent(java.lang.String archiveEventPath,
EventRecord event)
archiveEventPath - public int informServer(java.lang.String eventName,
java.lang.String eventDirPath,
java.lang.String eventCompressedPath,
EventRecord event)
eventName - The name that has been assigned to the eventeventDirPath - The path to the directory of an event record (in the archive)eventCompressedPath - The path to the compressed file of an event record (in the archive)event - The EventRecord object (will be loaded from the directory, if nullpublic int updateServerEvent(int id,
java.lang.String archiveEventPath,
EventRecord event)
archiveEventPath - public int updateServer(int id,
java.lang.String eventName,
java.lang.String eventDirPath,
java.lang.String eventCompressedPath,
EventRecord event)
eventName - The name that has been assigned to the eventeventDirPath - The path to the directory of an event record (in the archive)eventCompressedPath - The path to the compressed file of an event record (in the archive)event - The EventRecord object (will be loaded from the directory, if nullpublic int deleteRecordFromIIS(java.lang.String archiveEventPath)
archiveEventPath - public int insertIntoDatabase(EventRecord event, java.lang.String eventName, java.lang.String eventDirectory, boolean archived, int informID)
event - eventDirectory - archived - informID - public int updateFitsInArchive(EventRecord event, java.lang.String eventName)
public java.util.ArrayList<java.lang.String> loadReceivedFiles()
public boolean checkStorageAccessibility()
public double getStorageUsableSpace()
public double getStorageTotalSpace()
public java.lang.String getRootStoragePath()
public java.lang.String getRootTransferPath()