public enum WorkFiles extends Enum<WorkFiles>
The following files are encapsulated:
"unsorted.txt": Unsorted list of files in a bitarchive "sorted.txt": Sorted list of files in a bitarchive
"missingba.txt": Files that are missing in a bitarchive "missingadmindata.txt"; Files that are missing from admin data "wrongfiles.txt": Files with wrong checksum??? "referenceba.txt"; File list from reference ba?
"wrongstates.txt"; Files that are in wrong state "insertinadmin.txt"; Files to insert into admin data "deletefromadmin.txt"; Files to delete from admin data "uploadtoba.txt"; Files to upload to the bitarchive "deletefromba.txt"; Files to delete from the bitarchive
Enum Constant and Description |
---|
CHECKSUMS_ON_BA
CHECKSUMS_ON_BA.
|
DELETE_FROM_ADMIN
DELETE_FROM_ADMIN.
|
DELETE_FROM_BA
DELETE_FROM_BA.
|
FILES_ON_BA
FILES_ON_BA.
|
FILES_ON_REFERENCE_BA
FILES_ON_REFERENCE_BA.
|
INSERT_IN_ADMIN
INSERT_IN_ADMIN.
|
MISSING_FILES_ADMINDATA
The MISSING_FILES_ADMINDATA is the workfile for the list of missing files for the admin data.
|
MISSING_FILES_BA
The MISSING_FILES_BA is the workfile for the list of missing files for a bitarchive.
|
UPLOAD_TO_BA
UPLOAD_TO_BA.
|
WRONG_FILES
WRONG_FILES.
|
WRONG_STATES
WRONG_STATES.
|
Modifier and Type | Method and Description |
---|---|
static File |
getFile(Replica rep,
WorkFiles fileType)
Method for retrieving a working file.
|
static Date |
getLastUpdate(Replica rep,
WorkFiles fileType)
Method for retrieving the last modified date of a working file for a specific replica.
|
static List<String> |
getLines(Replica replica,
WorkFiles fileType)
Method for retrieving the lines of a working file for a specific replica.
|
protected static File |
getPreservationDir(Replica replica)
Get the base dir for all files related to bitpreservation for a given bitarchive.
|
protected static File |
getSortedFile(File unsortedFile)
Get a sorted file from an unsorted one, updating if necessary.
|
static WorkFiles |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static WorkFiles[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
static void |
write(Replica replica,
WorkFiles fileType,
Set<String> files)
Method for writing the list of files to a work file.
|
public static final WorkFiles MISSING_FILES_BA
public static final WorkFiles MISSING_FILES_ADMINDATA
public static final WorkFiles WRONG_FILES
public static final WorkFiles FILES_ON_REFERENCE_BA
public static final WorkFiles INSERT_IN_ADMIN
public static final WorkFiles DELETE_FROM_ADMIN
public static final WorkFiles UPLOAD_TO_BA
public static final WorkFiles DELETE_FROM_BA
public static final WorkFiles WRONG_STATES
public static final WorkFiles FILES_ON_BA
public static final WorkFiles CHECKSUMS_ON_BA
public static WorkFiles[] values()
for (WorkFiles c : WorkFiles.values()) System.out.println(c);
public static WorkFiles valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullprotected static File getPreservationDir(Replica replica)
replica
- The name of a bitarchive.protected static File getSortedFile(File unsortedFile) throws IOFailure
unsortedFile
- An unsorted fileIOFailure
- If the file does not exist.public static void write(Replica replica, WorkFiles fileType, Set<String> files)
replica
- The replica for the working file.fileType
- The type of working file.files
- The list of filenames (?) to write to the working file.public static File getFile(Replica rep, WorkFiles fileType)
rep
- The replica to whom the file corresponds.fileType
- The type of working file.public static Date getLastUpdate(Replica rep, WorkFiles fileType)
FIXME this might throw odd exceptions if the file does not exist.
rep
- The replica for the working file.fileType
- The type of working file.Copyright © 2005–2015 The Royal Danish Library, the Danish State and University Library, the National Library of France and the Austrian National Library.. All rights reserved.