Modifier and Type | Field and Description |
---|---|
File |
baseDirectory |
int |
countedNewFiles |
long |
countedNewFilesLength |
Vector |
modified |
Vector |
newFiles |
protected Hashtable |
saved |
boolean |
silentInstall |
Vector |
unmodified |
Constructor and Description |
---|
InstalledFilesState(File baseDirectory,
String originallySaved,
boolean silentInstall)
Create an InstalledFilesState and gather the file information.
|
Modifier and Type | Method and Description |
---|---|
boolean |
handleDeleteDataFiles(Installer installer,
InstalledConfig ic) |
boolean |
handleDeleteDataPromptedAction(Installer installer,
InstalledConfig ic)
If this returns true then the user selection has been handled, but if it returns false it indicates
that the user has cancelled the uninstall.
|
boolean |
handleDeleteDataUnpromptedAction(InstalledConfig ic)
If this is returns true then no user prompt is required and all files that should be deleted or kept
have been handled.
|
boolean |
hasUserModifiedFiles() |
boolean |
isAnUnmodifiedFile(String nameUnderDirectory)
Return if the specified file, which should be named relative to the base directory,
is an unmodified installed data file.
|
boolean |
isEmpty() |
boolean |
removeFiles(boolean deleteUserModifiedFiles,
boolean removeBaseDirectory)
Delete the unmodified data files and optionally the user modified/added data files as well.
|
public File baseDirectory
public Vector unmodified
public Vector modified
public Vector newFiles
public int countedNewFiles
public long countedNewFilesLength
public boolean silentInstall
protected Hashtable saved
public boolean isEmpty()
public boolean hasUserModifiedFiles()
public boolean isAnUnmodifiedFile(String nameUnderDirectory)
nameUnderDirectory
- the name relative to the base directory, e.g. "sub-dir/the-file.txt"public boolean handleDeleteDataUnpromptedAction(InstalledConfig ic)
public boolean removeFiles(boolean deleteUserModifiedFiles, boolean removeBaseDirectory)
deleteUserModifiedFiles
- true to also remove user modified files.removeBaseDirectory
- true to remove the base directory as well.public boolean handleDeleteDataPromptedAction(Installer installer, InstalledConfig ic)
public boolean handleDeleteDataFiles(Installer installer, InstalledConfig ic)