|
Lines 1-5
Link Here
|
| 1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
| 2 |
* Copyright (c) 2000, 2011 IBM Corporation and others. |
2 |
* Copyright (c) 2000, 2012 IBM Corporation and others. |
| 3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
| 4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
| 5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
|
Lines 73-78
Link Here
|
| 73 |
public char[][] packageName; |
73 |
public char[][] packageName; |
| 74 |
public boolean checkSecondaryTypes = false; // check for secondary types which were created after the initial buildTypeBindings call |
74 |
public boolean checkSecondaryTypes = false; // check for secondary types which were created after the initial buildTypeBindings call |
| 75 |
private int numberOfErrors; |
75 |
private int numberOfErrors; |
|
|
76 |
private boolean hasMandatoryErrors; |
| 76 |
|
77 |
|
| 77 |
private static final int[] EMPTY_LINE_ENDS = Util.EMPTY_INT_ARRAY; |
78 |
private static final int[] EMPTY_LINE_ENDS = Util.EMPTY_INT_ARRAY; |
| 78 |
private static final Comparator PROBLEM_COMPARATOR = new Comparator() { |
79 |
private static final Comparator PROBLEM_COMPARATOR = new Comparator() { |
|
Lines 274-279
Link Here
|
| 274 |
return this.numberOfErrors != 0; |
275 |
return this.numberOfErrors != 0; |
| 275 |
} |
276 |
} |
| 276 |
|
277 |
|
|
|
278 |
public boolean hasMandatoryErrors() { |
| 279 |
return this.hasMandatoryErrors; |
| 280 |
} |
| 281 |
|
| 277 |
public boolean hasProblems() { |
282 |
public boolean hasProblems() { |
| 278 |
return this.problemCount != 0; |
283 |
return this.problemCount != 0; |
| 279 |
} |
284 |
} |
|
Lines 324-329
Link Here
|
| 324 |
} |
329 |
} |
| 325 |
|
330 |
|
| 326 |
public void record(CategorizedProblem newProblem, ReferenceContext referenceContext) { |
331 |
public void record(CategorizedProblem newProblem, ReferenceContext referenceContext) { |
|
|
332 |
record(newProblem, referenceContext, true); |
| 333 |
return; |
| 334 |
} |
| 335 |
|
| 336 |
public void record(CategorizedProblem newProblem, ReferenceContext referenceContext, boolean mandatoryError) { |
| 327 |
//new Exception("VERBOSE PROBLEM REPORTING").printStackTrace(); |
337 |
//new Exception("VERBOSE PROBLEM REPORTING").printStackTrace(); |
| 328 |
if(newProblem.getID() == IProblem.Task) { |
338 |
if(newProblem.getID() == IProblem.Task) { |
| 329 |
recordTask(newProblem); |
339 |
recordTask(newProblem); |
|
Lines 343-348
Link Here
|
| 343 |
} |
353 |
} |
| 344 |
if (newProblem.isError()) { |
354 |
if (newProblem.isError()) { |
| 345 |
this.numberOfErrors++; |
355 |
this.numberOfErrors++; |
|
|
356 |
if (mandatoryError) this.hasMandatoryErrors = true; |
| 346 |
if ((newProblem.getID() & IProblem.Syntax) != 0) { |
357 |
if ((newProblem.getID() & IProblem.Syntax) != 0) { |
| 347 |
this.hasSyntaxError = true; |
358 |
this.hasSyntaxError = true; |
| 348 |
} |
359 |
} |
|
Lines 409-412
Link Here
|
| 409 |
} |
420 |
} |
| 410 |
return buffer.toString(); |
421 |
return buffer.toString(); |
| 411 |
} |
422 |
} |
|
|
423 |
|
| 412 |
} |
424 |
} |