public class Checksummer extends AbstractProgressable
Modifier and Type | Class and Description |
---|---|
protected static class |
Checksummer.StringAndFile |
Modifier and Type | Field and Description |
---|---|
static String[][] |
directories |
protected static Map<String,Set<String>> |
extensions |
progress
Constructor and Description |
---|
Checksummer(FilesCollection files,
Progress progress) |
Modifier and Type | Method and Description |
---|---|
protected void |
addConflict(String filename,
String adjective,
boolean isCritical,
List<File> toDelete) |
protected static List<File> |
convert(List<Checksummer.StringAndFile> pairs) |
protected boolean |
exists(File file) |
Map<String,FileObject.Version> |
getCachedChecksums() |
protected String |
getDigest(String path,
File file,
long timestamp) |
protected void |
handle(Checksummer.StringAndFile pair) |
protected void |
handle(String unversioned)
Handle a single component, adding conflicts if there are multiple
versions.
|
protected void |
handleQueue() |
protected void |
initializeQueue() |
boolean |
isCandidate(String path) |
protected static Checksummer.StringAndFile |
pickNewest(List<Checksummer.StringAndFile> list) |
protected void |
queue(String path) |
protected void |
queue(String path,
File file) |
void |
queueDir(String[] dirs,
String[] extensions) |
void |
queueDir(String dir,
Set<String> extensions) |
protected void |
queueIfExists(String path) |
protected void |
readCachedChecksums() |
protected void |
removeConflict(String filename) |
protected boolean |
tryToGuessPlatform(FileObject file) |
void |
updateFromLocal() |
void |
updateFromLocal(List<String> files) |
protected void |
writeCachedChecksums() |
addItem, addProgress, done, itemDone, removeProgress, setCount, setItemCount, setTitle
public static final String[][] directories
public Checksummer(FilesCollection files, Progress progress)
public Map<String,FileObject.Version> getCachedChecksums()
protected boolean exists(File file)
protected void queueIfExists(String path)
protected void queue(String path)
protected void handle(String unversioned)
unversioned
- the unversioned name of the componentprotected static Checksummer.StringAndFile pickNewest(List<Checksummer.StringAndFile> list)
protected static List<File> convert(List<Checksummer.StringAndFile> pairs)
protected void addConflict(String filename, String adjective, boolean isCritical, List<File> toDelete)
protected void removeConflict(String filename)
protected void handle(Checksummer.StringAndFile pair)
protected void handleQueue()
protected boolean tryToGuessPlatform(FileObject file)
public boolean isCandidate(String path)
protected void initializeQueue()
public void updateFromLocal()
protected void readCachedChecksums()
protected void writeCachedChecksums()
protected String getDigest(String path, File file, long timestamp) throws IOException, NoSuchAlgorithmException, ZipException
Copyright © 2014–2022 ImageJ. All rights reserved.