*/
public void hideProtein(String match) throws IOException, ClassNotFoundException, SQLException, InterruptedException {
try {
Identification identification = peptideShakerGUI.getIdentification();
FilterPreferences filterPreferences = peptideShakerGUI.getFilterPreferences();
PSParameter psParameter = new PSParameter();
psParameter = (PSParameter) identification.getProteinMatchParameter(match, psParameter);
boolean validated = false;
for (ProteinFilter matchFilter : filterPreferences.getProteinHideFilters().values()) {
if (matchFilter.getExceptions().contains(match)) {
matchFilter.removeException(match);
}
if (matchFilter.isValidated(match, peptideShakerGUI.getIdentification(), peptideShakerGUI.getIdentificationFeaturesGenerator(), peptideShakerGUI.getSearchParameters(), peptideShakerGUI.getAnnotationPreferences())) {
validated = true;
}
}
if (!validated) {
ProteinFilter proteinFilter;
if (!filterPreferences.getProteinHideFilters().containsKey(MatchFilter.MANUAL_SELECTION)) {
proteinFilter = new ProteinFilter(MatchFilter.MANUAL_SELECTION);
proteinFilter.setDescription("Manual selection via the graphical interface");
filterPreferences.getProteinHideFilters().put(proteinFilter.getName(), proteinFilter);
} else {
proteinFilter = filterPreferences.getProteinHideFilters().get(MatchFilter.MANUAL_SELECTION);
}
proteinFilter.addManualValidation(match);
}
psParameter.setHidden(true);