|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ActiveBitPreservation
All bitpreservation implementations are assumed to have access to admin data and bitarchives. Operations may request information from the bitarchive by sending batch jobs, reading admin data directly, or reading from cached information from either.
Method Summary | |
---|---|
void |
addMissingFilesToAdminData(java.lang.String... filenames)
Add files unknown in admin.data to admin.data. |
void |
changeStateForAdminData(java.lang.String filename)
Reestablish admin data to match bitarchive states for file. |
void |
findChangedFiles(Location bitarchive)
Update the list of checksums in a given bitarchive. |
void |
findMissingFiles(Location bitarchive)
Update the list of files in a given bitarchive. |
java.lang.Iterable<java.lang.String> |
getChangedFiles(Location location)
Return a list of files with changed checksums on this location. |
java.lang.Iterable<java.lang.String> |
getChangedFilesForAdminData()
Return a list of files with wrong checksum or state in admin data. |
java.util.Date |
getDateForChangedFiles(Location location)
Return the date for last check of changed files for location. |
java.util.Date |
getDateForMissingFiles(Location location)
Return the date for last check of missing files for location. |
FilePreservationState |
getFilePreservationState(java.lang.String filename)
Get the details of the state of the given file in the bitarchives and admin data. |
java.util.Map<java.lang.String,FilePreservationState> |
getFilePreservationStateMap(java.lang.String... filenames)
Get details of the state of one or more files in the bitarchives and admin data. |
java.lang.Iterable<java.lang.String> |
getMissingFiles(Location location)
Return a list of files marked as missing on this location. |
java.lang.Iterable<java.lang.String> |
getMissingFilesForAdminData()
Return a list of files present in bitarchive but missing in AdminData. |
long |
getNumberOfChangedFiles(Location location)
Return the number of changed files for location. |
long |
getNumberOfFiles(Location location)
Return the total number of files for location. |
long |
getNumberOfMissingFiles(Location location)
Return the number of missing files for location. |
void |
replaceChangedFile(Location location,
java.lang.String filename,
java.lang.String credentials,
java.lang.String checksum)
Check that the checksum of the file is indeed different to the value in admin data and reference location. |
void |
uploadMissingFiles(Location location,
java.lang.String... filenames)
Check that files are indeed missing on the given location, and present in admin data and reference location. |
Method Detail |
---|
java.util.Map<java.lang.String,FilePreservationState> getFilePreservationStateMap(java.lang.String... filenames)
filenames
- the list of filenames to investigate
FilePreservationState getFilePreservationState(java.lang.String filename)
filename
- A given file
java.lang.Iterable<java.lang.String> getMissingFiles(Location location)
location
- The location to get missing files from.
IOFailure
- if the list cannot be generated.java.lang.Iterable<java.lang.String> getChangedFiles(Location location)
location
- The location to get a list of changed files from.
IOFailure
- if the list cannot be generated.void findMissingFiles(Location bitarchive)
bitarchive
- The bitarchive to update list of files for.void findChangedFiles(Location bitarchive)
bitarchive
- The bitarchive to update list of files for.long getNumberOfMissingFiles(Location location)
location
- The location to get the number of missing files from.
long getNumberOfChangedFiles(Location location)
location
- The location to get the number of changed files from.
long getNumberOfFiles(Location location)
location
- The location to get the number of files from.
java.util.Date getDateForMissingFiles(Location location)
location
- The location to get date for changed files from.
java.util.Date getDateForChangedFiles(Location location)
location
- The location to get date for changed files from.
void uploadMissingFiles(Location location, java.lang.String... filenames)
location
- The location to restore files tofilenames
- The names of the files.
IOFailure
- if any file cannot be reestablished, or if any file is
not in correct state. The process will be attempted for all files, even
if one causes this exception.void replaceChangedFile(Location location, java.lang.String filename, java.lang.String credentials, java.lang.String checksum)
location
- The location to restore file tofilename
- The name of the filecredentials
- The credentials used to perform this replace operationchecksum
- The known bad checksum. Only a file with this bad
checksum is attempted repaired.
IOFailure
- if the file cannot be reestablished
PermissionDenied
- if the file is not in correct statejava.lang.Iterable<java.lang.String> getMissingFilesForAdminData()
IOFailure
- if the list cannot be generated.java.lang.Iterable<java.lang.String> getChangedFilesForAdminData()
IOFailure
- if the list cannot be generated.void addMissingFilesToAdminData(java.lang.String... filenames)
filenames
- The files to add.
PermissionDenied
- if the file is not in correct statevoid changeStateForAdminData(java.lang.String filename)
filename
- The file to reestablish state for.
PermissionDenied
- if the file is not in correct state
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |