// Convert JDT IProblems into plexus CompilerErrors
for (IProblem problem: result.getProblems()) {
if (problem.isWarning()) {
if (showWarnings) {
compilerErrors.add(new CompilerError(new String(problem.getOriginatingFileName()),
false,
problem.getSourceLineNumber(),
problem.getSourceStart(),
problem.getSourceLineNumber(),
problem.getSourceEnd(),
problem.getMessage()));
}
} else if (problem.isError()) {
hasErrors = true;
compilerErrors.add(new CompilerError(new String(problem.getOriginatingFileName()),
true,
problem.getSourceLineNumber(),
problem.getSourceStart(),
problem.getSourceLineNumber(),
problem.getSourceEnd(),