Skip to content
Snippets Groups Projects
Commit 5b90c5fb authored by apriestman's avatar apriestman
Browse files

Remove onDataSourceAdded

parent 36fdaf14
Branches
Tags
No related merge requests found
......@@ -24,13 +24,6 @@
* Provides callbacks at key points during the process of adding a data source to a case database.
*/
public interface AddDataSourceCallbacks {
/**
* Call when the data source has been completely added to the case database.
*
* @param dataSourceObjectId The object ID of the new data source
*/
void onDataSourceAdded(long dataSourceObjectId);
/**
* Call to add a set of file object IDs that have been added to the database.
*
......
......@@ -24,15 +24,8 @@
* Do-nothing version of AddDataSourceCallbacks
*/
public class DefaultAddDataSourceCallbacks implements AddDataSourceCallbacks {
@Override
public void onDataSourceAdded(long dataSourceObjectId) {
// Do nothing
}
@Override
public void onFilesAdded(List<Long> fileObjectIds) {
// Do nothing
}
@Override
public void onFilesAdded(List<Long> fileObjectIds) {
// Do nothing
}
}
......@@ -107,6 +107,8 @@ void finish() {
/**
* Add a new image to the database.
* Intended to be called from the native code during the add image process.
* Will not be called if the image was added to the database prior to starting
* the add image process.
*
* @param type Type of image.
* @param ssize Sector size.
......@@ -131,14 +133,6 @@ long addImageInfo(int type, long ssize, String timezone,
caseDb.addImageNameJNI(objId, paths[i], i, trans);
}
commitTransaction();
try {
addDataSourceCallbacks.onDataSourceAdded(objId);
} catch (Exception ex) {
// Exception firewall - we do not want to return to the native code without
// passing it the data source ID
logger.log(Level.SEVERE, "Unexpected error from data source added callback", ex);
}
return objId;
} catch (TskCoreException ex) {
logger.log(Level.SEVERE, "Error adding image to the database", ex);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment