diff --git a/Core/src/org/sleuthkit/autopsy/casemodule/Case.java b/Core/src/org/sleuthkit/autopsy/casemodule/Case.java index b5dabeda18..b7d52d5c46 100644 --- a/Core/src/org/sleuthkit/autopsy/casemodule/Case.java +++ b/Core/src/org/sleuthkit/autopsy/casemodule/Case.java @@ -402,7 +402,7 @@ public class Case { /** * Adds a subscriber to specific case events. * - * @param eventName The event the subscriber is interested in. + * @param eventName The event the subscriber is interested in. * @param subscriber The subscriber (PropertyChangeListener) to add. */ public static void addEventSubscriber(String eventName, PropertyChangeListener subscriber) { @@ -412,7 +412,7 @@ public class Case { /** * Removes a subscriber to specific case events. * - * @param eventName The event the subscriber is no longer interested in. + * @param eventName The event the subscriber is no longer interested in. * @param subscriber The subscriber (PropertyChangeListener) to remove. */ public static void removeEventSubscriber(String eventName, PropertyChangeListener subscriber) { @@ -449,19 +449,21 @@ public class Case { * IMPORTANT: This method should not be called in the event dispatch thread * (EDT). * - * @param caseDir The full path of the case directory. The directory will be - * created if it doesn't already exist; if it exists, it is ASSUMED it was - * created by calling createCaseDirectory. + * @param caseDir The full path of the case directory. The directory + * will be created if it doesn't already exist; if it + * exists, it is ASSUMED it was created by calling + * createCaseDirectory. * @param caseDisplayName The display name of case, which may be changed - * later by the user. - * @param caseNumber The case number, can be the empty string. - * @param examiner The examiner to associate with the case, can be the empty - * string. - * @param caseType The type of case (single-user or multi-user). + * later by the user. + * @param caseNumber The case number, can be the empty string. + * @param examiner The examiner to associate with the case, can be + * the empty string. + * @param caseType The type of case (single-user or multi-user). * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "# {0} - exception message", "Case.exceptionMessage.wrapperMessage={0}" @@ -501,8 +503,9 @@ public class Case { * @param caseMetadataFilePath The path of the case metadata (.aut) file. * * @throws CaseActionException if there is a problem opening the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "# {0} - exception message", "Case.openException.couldNotOpenCase=Could not open case: {0}", @@ -605,8 +608,9 @@ public class Case { * (EDT). * * @throws CaseActionException if there is a problem deleting the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ public static void deleteCurrentCase() throws CaseActionException { synchronized (currentCaseWriteLock) { @@ -626,8 +630,9 @@ public class Case { * @param metadata The metadata for the case to delete. * * @throws CaseActionException if there is a problem deleting the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "# {0} - exception message", "Case.deleteException.couldNotDeleteCase=Could not delete case: {0}", @@ -774,7 +779,7 @@ public class Case { /** * Creates a case directory and its subdirectories. * - * @param caseDir Path to the case directory (typically base + case name). + * @param caseDir Path to the case directory (typically base + case name). * @param caseType The type of case, single-user or multi-user. * * @throws CaseActionException throw if could not create the case dir @@ -903,7 +908,7 @@ public class Case { * Deletes the case directory of a deleted case and removes the case form * the Recent Cases menu. * - * @param metadata The case metadata. + * @param metadata The case metadata. * @param progressIndicator A progress indicator. */ @Messages({ @@ -932,12 +937,12 @@ public class Case { * Acquires an exclusive case name lock. * * @param caseName The case name (not the case display name, which can be - * changed by a user). + * changed by a user). * * @return The lock. * * @throws CaseActionException with a user-friendly message if the lock - * cannot be acquired. + * cannot be acquired. */ @Messages({"Case.creationException.couldNotAcquireNameLock=Failed to get lock on case name"}) private static CoordinationService.Lock acquireExclusiveCaseNameLock(String caseName) throws CaseActionException { @@ -957,12 +962,12 @@ public class Case { * Acquires an exclusive case resources lock. * * @param caseName The case name (not the case display name, which can be - * changed by a user). + * changed by a user). * * @return The lock. * * @throws CaseActionException with a user-friendly message if the lock - * cannot be acquired. + * cannot be acquired. */ @Messages({"Case.creationException.couldNotAcquireResourcesLock=Failed to get lock on case resources"}) private static CoordinationService.Lock acquireExclusiveCaseResourcesLock(String caseName) throws CaseActionException { @@ -1316,7 +1321,7 @@ public class Case { * the case directory, creating it if it does not exist. * * @return The path to the module output directory, relative to the case - * directory. + * directory. */ public String getModuleOutputDirectoryRelativePath() { Path path = Paths.get(getModuleDirectory()); @@ -1333,7 +1338,8 @@ public class Case { * @return A list of data sources. * * @throws org.sleuthkit.datamodel.TskCoreException if there is a problem - * querying the case database. + * querying the case + * database. */ public List getDataSources() throws TskCoreException { List list = caseDb.getRootObjects(); @@ -1406,8 +1412,8 @@ public class Case { * This should not be called from the event dispatch thread (EDT) * * @param eventId A unique identifier for the event. This UUID must be used - * to call notifyFailedAddingDataSource or notifyNewDataSource after the - * data source is added. + * to call notifyFailedAddingDataSource or + * notifyNewDataSource after the data source is added. */ public void notifyAddingDataSource(UUID eventId) { eventPublisher.publish(new AddingDataSourceEvent(eventId)); @@ -1420,7 +1426,8 @@ public class Case { * This should not be called from the event dispatch thread (EDT) * * @param addingDataSourceEventId The unique identifier for the - * corresponding adding data source event (see notifyAddingDataSource). + * corresponding adding data source event + * (see notifyAddingDataSource). */ public void notifyFailedAddingDataSource(UUID addingDataSourceEventId) { eventPublisher.publish(new AddingDataSourceFailedEvent(addingDataSourceEventId)); @@ -1432,9 +1439,10 @@ public class Case { * * This should not be called from the event dispatch thread (EDT) * - * @param dataSource The data source. + * @param dataSource The data source. * @param addingDataSourceEventId The unique identifier for the - * corresponding adding data source event (see notifyAddingDataSource). + * corresponding adding data source event + * (see notifyAddingDataSource). */ public void notifyDataSourceAdded(Content dataSource, UUID addingDataSourceEventId) { eventPublisher.publish(new DataSourceAddedEvent(dataSource, addingDataSourceEventId)); @@ -1487,13 +1495,13 @@ public class Case { /** * Adds a report to the case. * - * @param localPath The path of the report file, must be in the case - * directory or one of its subdirectories. + * @param localPath The path of the report file, must be in the case + * directory or one of its subdirectories. * @param srcModuleName The name of the module that created the report. - * @param reportName The report name, may be empty. + * @param reportName The report name, may be empty. * * @throws TskCoreException if there is a problem adding the report to the - * case database. + * case database. */ public void addReport(String localPath, String srcModuleName, String reportName) throws TskCoreException { String normalizedLocalPath; @@ -1513,7 +1521,7 @@ public class Case { * @return A collection of report objects. * * @throws TskCoreException if there is a problem querying the case - * database. + * database. */ public List getAllReports() throws TskCoreException { return this.caseDb.getAllReports(); @@ -1547,9 +1555,9 @@ public class Case { * Updates the case display name name. * * @param oldCaseName The old case name. - * @param oldPath The old path name. + * @param oldPath The old path name. * @param newCaseName The new case name. - * @param newPath The new case path. + * @param newPath The new case path. */ void updateCaseName(String oldCaseName, String oldPath, String newCaseName, String newPath) throws CaseActionException { try { @@ -1577,19 +1585,21 @@ public class Case { } /** - * @param caseDir The full path of the case directory. The directory will be - * created if it doesn't already exist; if it exists, it is ASSUMED it was - * created by calling createCaseDirectory. + * @param caseDir The full path of the case directory. The directory + * will be created if it doesn't already exist; if it + * exists, it is ASSUMED it was created by calling + * createCaseDirectory. * @param caseDisplayName The display name of case, which may be changed - * later by the user. - * @param caseNumber The case number, can be the empty string. - * @param examiner The examiner to associate with the case, can be the empty - * string. - * @param caseType The type of case (single-user or multi-user). + * later by the user. + * @param caseNumber The case number, can be the empty string. + * @param examiner The examiner to associate with the case, can be + * the empty string. + * @param caseType The type of case (single-user or multi-user). * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "Case.exceptionMessage.illegalCaseName=Case name contains illegal characters.", @@ -1710,19 +1720,21 @@ public class Case { /** * Creates and opens a new case. * - * @param caseDir The full path of the case directory. The directory will be - * created if it doesn't already exist; if it exists, it is ASSUMED it was - * created by calling createCaseDirectory. + * @param caseDir The full path of the case directory. The directory + * will be created if it doesn't already exist; if it + * exists, it is ASSUMED it was created by calling + * createCaseDirectory. * @param caseDisplayName The display name of case, which may be changed - * later by the user. - * @param caseNumber The case number, can be the empty string. - * @param examiner The examiner to associate with the case, can be the empty - * string. - * @param caseType The type of case (single-user or multi-user). + * later by the user. + * @param caseNumber The case number, can be the empty string. + * @param examiner The examiner to associate with the case, can be + * the empty string. + * @param caseType The type of case (single-user or multi-user). * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "Case.progressMessage.creatingCaseDirectory=Creating case directory...", @@ -1809,8 +1821,9 @@ public class Case { * @param caseMetadataFilePath The apth to the case metadata file. * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ private void open(Path caseMetadataFilePath) throws CaseActionException { /* @@ -1923,8 +1936,9 @@ public class Case { * @param progressIndicator A progress indicator. * * @throws CaseActionException if there is a problem opening the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. */ @Messages({ "Case.progressMessage.openingCaseDatabase=Opening case database...", @@ -2320,7 +2334,7 @@ public class Case { * @param caseDir The full path of the case directory. * * @throws CaseActionException with a user-friendly message if the lock - * cannot be acquired. + * cannot be acquired. */ @Messages({"Case.creationException.couldNotAcquireDirLock=Failed to get lock on case directory."}) private void acquireSharedCaseDirLock(String caseDir) throws CaseActionException { @@ -2413,7 +2427,7 @@ public class Case { * characters is encountered. * * @param message The exception message. - * @param cause The exceptin cause. + * @param cause The exceptin cause. */ IllegalCaseNameException(String message, Throwable cause) { super(message, cause); @@ -2423,18 +2437,20 @@ public class Case { /** * Creates a new, single-user Autopsy case. * - * @param caseDir The full path of the case directory. The directory will be - * created if it doesn't already exist; if it exists, it is ASSUMED it was - * created by calling createCaseDirectory. + * @param caseDir The full path of the case directory. The directory + * will be created if it doesn't already exist; if it + * exists, it is ASSUMED it was created by calling + * createCaseDirectory. * @param caseDisplayName The display name of case, which may be changed - * later by the user. - * @param caseNumber The case number, can be the empty string. - * @param examiner The examiner to associate with the case, can be the empty - * string. + * later by the user. + * @param caseNumber The case number, can be the empty string. + * @param examiner The examiner to associate with the case, can be + * the empty string. * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. * @deprecated Use createAsCurrentCase instead. */ @Deprecated @@ -2445,19 +2461,21 @@ public class Case { /** * Creates a new Autopsy case and makes it the current case. * - * @param caseDir The full path of the case directory. The directory will be - * created if it doesn't already exist; if it exists, it is ASSUMED it was - * created by calling createCaseDirectory. + * @param caseDir The full path of the case directory. The directory + * will be created if it doesn't already exist; if it + * exists, it is ASSUMED it was created by calling + * createCaseDirectory. * @param caseDisplayName The display name of case, which may be changed - * later by the user. - * @param caseNumber The case number, can be the empty string. - * @param examiner The examiner to associate with the case, can be the empty - * string. - * @param caseType The type of case (single-user or multi-user). + * later by the user. + * @param caseNumber The case number, can be the empty string. + * @param examiner The examiner to associate with the case, can be + * the empty string. + * @param caseType The type of case (single-user or multi-user). * * @throws CaseActionException if there is a problem creating the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. * @deprecated Use createAsCurrentCase instead. */ @Deprecated @@ -2471,8 +2489,9 @@ public class Case { * @param caseMetadataFilePath The path of the case metadata (.aut) file. * * @throws CaseActionException if there is a problem opening the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. * @deprecated Use openAsCurrentCase instead. */ @Deprecated @@ -2484,8 +2503,9 @@ public class Case { * Closes this Autopsy case. * * @throws CaseActionException if there is a problem closing the case. The - * exception will have a user-friendly message and may be a wrapper for a - * lower-level exception. + * exception will have a user-friendly message + * and may be a wrapper for a lower-level + * exception. * @deprecated Use closeCurrentCase instead. */ @Deprecated @@ -2607,8 +2627,8 @@ public class Case { * Adds an image to the current case after it has been added to the DB. * Sends out event and reopens windows if needed. * - * @param imgPath The path of the image file. - * @param imgId The ID of the image. + * @param imgPath The path of the image file. + * @param imgId The ID of the image. * @param timeZone The time zone of the image. * * @return @@ -2643,7 +2663,7 @@ public class Case { /** * Deletes reports from the case. * - * @param reports Collection of Report to be deleted from the case. + * @param reports Collection of Report to be deleted from the case. * @param deleteFromDisk No longer supported - ignored. * * @throws TskCoreException diff --git a/Core/src/org/sleuthkit/autopsy/framework/ProgressPanel.java b/Core/src/org/sleuthkit/autopsy/framework/ProgressPanel.java index 6d4e46cc42..38c7a209b0 100644 --- a/Core/src/org/sleuthkit/autopsy/framework/ProgressPanel.java +++ b/Core/src/org/sleuthkit/autopsy/framework/ProgressPanel.java @@ -28,6 +28,7 @@ class ProgressPanel extends javax.swing.JPanel { ProgressPanel() { initComponents(); this.progressBar.setMinimum(0); + this.progressBar.setIndeterminate(true); } void setMessage(String message) {