mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Method to save the ErrorParsers ids.
This commit is contained in:
parent
645fd04fa9
commit
a5e90c433e
1 changed files with 12 additions and 4 deletions
|
@ -760,7 +760,11 @@ public class CCorePlugin extends Plugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
public String[] getPreferenceErrorParserIDs() {
|
public String[] getPreferenceErrorParserIDs() {
|
||||||
String parserIDs = CCorePlugin.getDefault().getPluginPreferences().getString(PREF_ERROR_PARSER);
|
return getPreferenceErrorParserIDs(CCorePlugin.getDefault().getPluginPreferences());
|
||||||
|
}
|
||||||
|
|
||||||
|
public String[] getPreferenceErrorParserIDs(Preferences prefs) {
|
||||||
|
String parserIDs = prefs.getString(PREF_ERROR_PARSER);
|
||||||
String[] empty = new String[0];
|
String[] empty = new String[0];
|
||||||
if (parserIDs != null && parserIDs.length() > 0) {
|
if (parserIDs != null && parserIDs.length() > 0) {
|
||||||
StringTokenizer tok = new StringTokenizer(parserIDs, ";");
|
StringTokenizer tok = new StringTokenizer(parserIDs, ";");
|
||||||
|
@ -774,11 +778,15 @@ public class CCorePlugin extends Plugin {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setPreferenceErrorParser(String[] parsersIDs) {
|
public void setPreferenceErrorParser(String[] parsersIDs) {
|
||||||
|
setPreferenceErrorParser(CCorePlugin.getDefault().getPluginPreferences(), parsersIDs);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPreferenceErrorParser(Preferences prefs, String[] parserIDs) {
|
||||||
StringBuffer buf = new StringBuffer();
|
StringBuffer buf = new StringBuffer();
|
||||||
for (int i = 0; i < parsersIDs.length; i++) {
|
for (int i = 0; i < parserIDs.length; i++) {
|
||||||
buf.append(parsersIDs[i]).append(';');
|
buf.append(parserIDs[i]).append(';');
|
||||||
}
|
}
|
||||||
CCorePlugin.getDefault().getPluginPreferences().setValue(PREF_ERROR_PARSER, buf.toString());
|
prefs.setValue(PREF_ERROR_PARSER, buf.toString());
|
||||||
}
|
}
|
||||||
|
|
||||||
public IScannerInfoProvider getScannerInfoProvider(IProject project) {
|
public IScannerInfoProvider getScannerInfoProvider(IProject project) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue