1 /*******************************************************************************
2 * Copyright (c) 2000, 2003 IBM Corporation and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Common Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/cpl-v10.html
9 * IBM Corporation - initial API and implementation
10 *******************************************************************************/
11 package net.sourceforge.phpdt.internal.compiler;
13 public class DefaultErrorHandlingPolicies {
16 * Accumulate all problems, then exit without proceeding.
18 * Typically, the #proceedWithProblems(Problem[]) should
22 public static IErrorHandlingPolicy exitAfterAllProblems() {
23 return new IErrorHandlingPolicy() {
24 public boolean stopOnFirstError() {
27 public boolean proceedOnErrors(){
33 * Exit without proceeding on the first problem wich appears
37 public static IErrorHandlingPolicy exitOnFirstError() {
38 return new IErrorHandlingPolicy() {
39 public boolean stopOnFirstError() {
42 public boolean proceedOnErrors(){
48 * Proceed on the first error met.
51 public static IErrorHandlingPolicy proceedOnFirstError() {
52 return new IErrorHandlingPolicy() {
53 public boolean stopOnFirstError() {
56 public boolean proceedOnErrors(){
62 * Accumulate all problems, then proceed with them.
65 public static IErrorHandlingPolicy proceedWithAllProblems() {
66 return new IErrorHandlingPolicy() {
67 public boolean stopOnFirstError() {
70 public boolean proceedOnErrors(){