- Timestamp:
- 2005-09-22T16:59:56+12:00 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gli/src/org/greenstone/gatherer/shell/GBuildProgressMonitor.java
r10530 r10618 79 79 static final int CREATINGAUXILARY = 50; 80 80 /** Now the language independant sentinel strings. */ 81 static final String BADARGUMENT_ELEMENT = "BadArgument"; 82 static final String BADARGUMENTVALUE_ELEMENT = "BadArgumentValue"; 83 static final String BADCLASSIFIER_ELEMENT = "BadClassifier"; 84 static final String BADPLUGIN_ELEMENT = "BadPlugin"; 81 85 static final String BUILD_ELEMENT = "Build"; 82 86 static final String COLLECTTEXTSTATS_VALUE = "CollectTextStats"; … … 106 110 static final String WARNING_ELEMENT = "Warning"; 107 111 static final String WORDLEVELINDEXES_VALUE = "WordLevelIndexes"; 112 113 static final private String ARGUMENT_ATTRIBUTE = "a"; 114 static final private String CLASSIFIER_ATTRIBUTE = "c"; 115 static final private String PLUGIN_ATTRIBUTE = "p"; 116 108 117 /** Indicates if the GUI has asked the process this object monitors to stop. */ 109 118 private boolean stop = false; … … 226 235 break; 227 236 case BUILD: 228 // The only thing we would expect is a stage element 237 // The only thing we would expect is a stage element or a 238 // bad classifier arg name 229 239 name = element.getElementName(); 240 230 241 if(name.equals(STAGE_ELEMENT)) { 231 242 progress_bar.setIndeterminate(false); … … 281 292 } 282 293 } 294 // We had a bad argument to a plugin/classifier 295 else if (name.equals(BADARGUMENT_ELEMENT)) { 296 if(Configuration.getMode() <= threshold) { 297 String args[] = new String[1]; 298 args[0] = element.getAttribute(ARGUMENT_ATTRIBUTE); 299 queue.add(new GShellEvent(event.getSource(), 0, event.getType(), Dictionary.get("GShell.BadArgument", args), event.getStatus())); 300 args = null; 301 } 302 } 303 // We had a bad argument value to a plugin/clasifier 304 else if (name.equals(BADARGUMENTVALUE_ELEMENT)) { 305 if(Configuration.getMode() <= threshold) { 306 String args[] = new String[1]; 307 args[0] = element.getAttribute(ARGUMENT_ATTRIBUTE); 308 queue.add(new GShellEvent(event.getSource(), 0, event.getType(), Dictionary.get("GShell.BadArgumentValue", args), event.getStatus())); 309 args = null; 310 } 311 } 312 // And this one tellsa us the plugin 313 else if (name.equals(BADPLUGIN_ELEMENT)) { 314 if(Configuration.getMode() <= threshold) { 315 String args[] = new String[1]; 316 args[0] = element.getAttribute(PLUGIN_ATTRIBUTE); 317 queue.add(new GShellEvent(event.getSource(), 0, event.getType(), Dictionary.get("GShell.BadPluginOptions", args), event.getStatus())); 318 args = null; 319 } 320 } 321 // or the classifier 322 else if (name.equals(BADCLASSIFIER_ELEMENT)) { 323 if(Configuration.getMode() <= threshold) { 324 String args[] = new String[1]; 325 args[0] = element.getAttribute(CLASSIFIER_ATTRIBUTE); 326 queue.add(new GShellEvent(event.getSource(), 0, event.getType(), Dictionary.get("GShell.BadClassifierOptions", args), event.getStatus())); 327 args = null; 328 } 329 } 330 283 331 else { 284 332 // Unknown command, go indeterminate
Note:
See TracChangeset
for help on using the changeset viewer.