Package org.eclipse.jdt.internal.compiler

Examples of org.eclipse.jdt.internal.compiler.IErrorHandlingPolicy


            final CompilationProblem[] result = new CompilationProblem[problems.size()];
            problems.toArray(result);
            return new org.drools.compiler.commons.jci.compilers.CompilationResult(result);
        }

        final IErrorHandlingPolicy policy = DefaultErrorHandlingPolicies.proceedWithAllProblems();
        final IProblemFactory problemFactory = new DefaultProblemFactory(Locale.getDefault());
        final INameEnvironment nameEnvironment = new INameEnvironment() {

            public NameEnvironmentAnswer findType( final char[][] pCompoundTypeName ) {
                final StringBuilder result = new StringBuilder();
View Full Code Here


  }

public HierarchyResolver(INameEnvironment nameEnvironment, Map settings, HierarchyBuilder builder, IProblemFactory problemFactory) {
  // create a problem handler with the 'exit after all problems' handling policy
  this.options = new CompilerOptions(settings);
  IErrorHandlingPolicy policy = DefaultErrorHandlingPolicies.exitAfterAllProblems();
  ProblemReporter problemReporter = new ProblemReporter(policy, this.options, problemFactory);

  LookupEnvironment environment = new LookupEnvironment(this, this.options, problemReporter, nameEnvironment);
  environment.mayTolerateMissingType = true;
  setEnvironment(environment, builder);
View Full Code Here

   *  Low-level API performing the actual compilation
   */
  protected static IErrorHandlingPolicy getHandlingPolicy() {

    // passes the initial set of files to the batch oracle (to avoid finding more than once the same units when case insensitive match)
    return new IErrorHandlingPolicy() {
      public boolean stopOnFirstError() {
        return false;
      }
      public boolean proceedOnErrors() {
        return false; // stop if there are some errors
View Full Code Here

*  Low-level API performing the actual compilation
*/
public IErrorHandlingPolicy getHandlingPolicy() {

  // passes the initial set of files to the batch oracle (to avoid finding more than once the same units when case insensitive match)
  return new IErrorHandlingPolicy() {
    public boolean proceedOnErrors() {
      return Main.this.proceedOnError; // stop if there are some errors
    }
    public boolean stopOnFirstError() {
      return false;
View Full Code Here

   *  Low-level API performing the actual compilation
   */
  @Override
  public IErrorHandlingPolicy getHandlingPolicy() {
    // passes the initial set of files to the batch oracle (to avoid finding more than once the same units when case insensitive match)
    return new IErrorHandlingPolicy() {
      @Override
      public boolean proceedOnErrors() {
        return false; // stop if there are some errors
      }
      @Override
View Full Code Here

*  Low-level API performing the actual compilation
*/
public IErrorHandlingPolicy getHandlingPolicy() {

  // passes the initial set of files to the batch oracle (to avoid finding more than once the same units when case insensitive match)
  return new IErrorHandlingPolicy() {
    public boolean proceedOnErrors() {
      return Main.this.proceedOnError; // stop if there are some errors
    }
    public boolean stopOnFirstError() {
      return false;
View Full Code Here

    if (!(left instanceof ReferenceBinding))
      return false;

    left = left.uncapture(this.enclosingScope);
    shapeAnalysis: if (!this.shapeAnalysisComplete) {
      IErrorHandlingPolicy oldPolicy = this.enclosingScope.problemReporter().switchErrorHandlingPolicy(silentErrorHandlingPolicy);
      final CompilerOptions compilerOptions = this.enclosingScope.compilerOptions();
      boolean analyzeNPE = compilerOptions.isAnnotationBasedNullAnalysisEnabled;
      compilerOptions.isAnnotationBasedNullAnalysisEnabled = false;
      try {
        final LambdaExpression copy = copy();
View Full Code Here

    if (this.shapeAnalysisComplete && this.binding != null)
      return this;
   
    targetType = targetType.uncapture(this.enclosingScope);
    // TODO: caching
    IErrorHandlingPolicy oldPolicy = this.enclosingScope.problemReporter().switchErrorHandlingPolicy(silentErrorHandlingPolicy);
    final CompilerOptions compilerOptions = this.enclosingScope.compilerOptions();
    boolean analyzeNPE = compilerOptions.isAnnotationBasedNullAnalysisEnabled;
    final LambdaExpression copy = copy();
    if (copy == null) {
      return null;
View Full Code Here

      implicitLambda.setBody(allocation);
    }
   
    // Process the lambda, taking care not to double report diagnostics. Don't expect any from resolve, Any from code generation should surface, but not those from flow analysis.
    implicitLambda.resolve(currentScope);
    IErrorHandlingPolicy oldPolicy = currentScope.problemReporter().switchErrorHandlingPolicy(silentErrorHandlingPolicy);
    try {
      implicitLambda.analyseCode(currentScope,
          new ExceptionHandlingFlowContext(null, this, Binding.NO_EXCEPTIONS, null, currentScope, FlowInfo.DEAD_END),
          UnconditionalFlowInfo.fakeInitializedFlowInfo(currentScope.outerMostMethodScope().analysisIndex, currentScope.referenceType().maxFieldCount));
    } finally {
View Full Code Here

    return targetMethod;
  }

  MethodBinding internalResolveTentatively(TypeBinding targetType, Scope scope) {
    // FIXME: could enclosingScope still be null here??
    IErrorHandlingPolicy oldPolicy = this.enclosingScope.problemReporter().switchErrorHandlingPolicy(silentErrorHandlingPolicy);
    ExpressionContext previousContext = this.expressionContext;
    MethodBinding previousBinding = this.binding;
    MethodBinding previousDescriptor = this.descriptor;
    TypeBinding previousResolvedType = this.resolvedType;
    try {
View Full Code Here

TOP

Related Classes of org.eclipse.jdt.internal.compiler.IErrorHandlingPolicy

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.