use of com.google.security.zynamics.binnavi.debug.debugger.interfaces.IDebuggerTemplateManagerListener in project binnavi by google.
the class DebuggerTemplateManager method addDebugger.
/**
* Adds a debugger template to the debugger template manager.
*
* @param debugger The debugger template to add to the template manager.
*/
public void addDebugger(final DebuggerTemplate debugger) {
Preconditions.checkNotNull(debugger, "IE00806: Debugger can not be null");
Preconditions.checkArgument(!debuggers.contains(debugger), "IE00807: Can not add debugger description more than once");
Preconditions.checkArgument(debugger.inSameDatabase(sqlProvider), "IE00808: Debugger template and debugger template manager are in different databases");
debuggers.add(debugger);
for (final IDebuggerTemplateManagerListener listener : listeners) {
try {
listener.addedDebugger(this, debugger);
} catch (final Exception e) {
CUtilityFunctions.logException(e);
}
}
}
use of com.google.security.zynamics.binnavi.debug.debugger.interfaces.IDebuggerTemplateManagerListener in project binnavi by google.
the class DebuggerTemplateManager method removeDebugger.
/**
* Removes a debugger template from the database.
*
* @param debugger The debugger template to be removed.
*
* @throws CouldntDeleteException Thrown if the debugger template could not be removed from the
* database.
*/
public void removeDebugger(final DebuggerTemplate debugger) throws CouldntDeleteException {
Preconditions.checkNotNull(debugger, "IE00812: Debugger argument can not be null");
Preconditions.checkArgument(debugger.inSameDatabase(sqlProvider), "IE00813: Debugger template and debugger template manager are not in the same database");
sqlProvider.deleteDebugger(debugger);
debuggers.remove(debugger);
for (final IDebuggerTemplateManagerListener listener : listeners) {
try {
listener.removedDebugger(this, debugger);
} catch (final Exception e) {
CUtilityFunctions.logException(e);
}
}
}
Aggregations