Package org.eclipse.jdt.internal.compiler.lookup

Examples of org.eclipse.jdt.internal.compiler.lookup.Binding.problemId()


       if (binding instanceof ReferenceBinding) {
         if (!binding.isValidBinding())
          return new ProblemReferenceBinding(
                  CharOperation.subarray(compoundName, 0, currentIndex),
                  (ReferenceBinding)((ReferenceBinding)binding).closestMatch(),
                  binding.problemId());
         if (!this.canBeSeenByForCodeSnippet((ReferenceBinding) binding, receiverType))
          return new ProblemReferenceBinding(CharOperation.subarray(compoundName, 0, currentIndex), (ReferenceBinding) binding, ProblemReasons.NotVisible);
         break foundType;
       }
       packageBinding = (PackageBinding) binding;
View Full Code Here


      if (!binding.isValidBinding()) {
        return new ProblemFieldBinding(
            (FieldBinding)binding,
            ((FieldBinding)binding).declaringClass,
            CharOperation.concatWith(CharOperation.subarray(compoundName, 0, currentIndex), '.'),
            binding.problemId());
      }
      break; // binding is now a field
    }
    if ((binding = findMemberType(nextName, typeBinding)) == null)
      return new ProblemBinding(CharOperation.subarray(compoundName, 0, currentIndex), typeBinding, ProblemReasons.NotFound);
View Full Code Here

      return new ProblemBinding(CharOperation.subarray(compoundName, 0, currentIndex), typeBinding, ProblemReasons.NotFound);
     if (!binding.isValidBinding())
      return new ProblemReferenceBinding(
                CharOperation.subarray(compoundName, 0, currentIndex),
                (ReferenceBinding)((ReferenceBinding)binding).closestMatch(),
                binding.problemId());
  }

  if ((mask & Binding.FIELD) != 0 && (binding instanceof FieldBinding)) { // was looking for a field and found a field
    FieldBinding field = (FieldBinding) binding;
    if (!field.isStatic()) {
View Full Code Here

       if (binding instanceof ReferenceBinding) {
         if (!binding.isValidBinding())
          return new ProblemReferenceBinding(
                  CharOperation.subarray(compoundName, 0, currentIndex),
                  (ReferenceBinding)((ReferenceBinding)binding).closestMatch(),
                  binding.problemId());
         if (!this.canBeSeenByForCodeSnippet((ReferenceBinding) binding, receiverType))
          return new ProblemReferenceBinding(CharOperation.subarray(compoundName, 0, currentIndex), (ReferenceBinding) binding, ProblemReasons.NotVisible);
         break foundType;
       }
       packageBinding = (PackageBinding) binding;
View Full Code Here

       if (binding instanceof ReferenceBinding) {
         if (!binding.isValidBinding())
          return new ProblemReferenceBinding(
                  CharOperation.subarray(compoundName, 0, currentIndex),
                  (ReferenceBinding)((ReferenceBinding)binding).closestMatch(),
                  binding.problemId());
         if (!this.canBeSeenByForCodeSnippet((ReferenceBinding) binding, receiverType))
          return new ProblemReferenceBinding(CharOperation.subarray(compoundName, 0, currentIndex), (ReferenceBinding) binding, ProblemReasons.NotVisible);
         break foundType;
       }
       packageBinding = (PackageBinding) binding;
View Full Code Here

      if (!binding.isValidBinding()) {
        return new ProblemFieldBinding(
            (FieldBinding)binding,
            ((FieldBinding)binding).declaringClass,
            CharOperation.concatWith(CharOperation.subarray(compoundName, 0, currentIndex), '.'),
            binding.problemId());
      }
      break; // binding is now a field
    }
    if ((binding = findMemberType(nextName, typeBinding)) == null)
      return new ProblemBinding(CharOperation.subarray(compoundName, 0, currentIndex), typeBinding, ProblemReasons.NotFound);
View Full Code Here

      return new ProblemBinding(CharOperation.subarray(compoundName, 0, currentIndex), typeBinding, ProblemReasons.NotFound);
     if (!binding.isValidBinding())
      return new ProblemReferenceBinding(
                CharOperation.subarray(compoundName, 0, currentIndex),
                (ReferenceBinding)((ReferenceBinding)binding).closestMatch(),
                binding.problemId());
  }

  if ((mask & Binding.FIELD) != 0 && (binding instanceof FieldBinding)) { // was looking for a field and found a field
    FieldBinding field = (FieldBinding) binding;
    if (!field.isStatic()) {
View Full Code Here

protected TypeBinding getTypeBinding(Scope scope) {
  // it can be a package, type or member type
  Binding binding = scope.getTypeOrPackage(this.tokens);
  if (!binding.isValidBinding()) {
    // tolerate some error cases
    if (binding.problemId() == ProblemReasons.NotVisible){
      throw new SelectionNodeFound(binding);
    }

    if (binding instanceof TypeBinding) {
      scope.problemReporter().invalidType(this, (TypeBinding) binding);
View Full Code Here

    }

    if (binding instanceof TypeBinding) {
      scope.problemReporter().invalidType(this, (TypeBinding) binding);
    } else if (binding instanceof PackageBinding) {
      ProblemReferenceBinding problemBinding = new ProblemReferenceBinding(((PackageBinding)binding).compoundName, null, binding.problemId());
      scope.problemReporter().invalidType(this, problemBinding);
    }

    throw new SelectionNodeFound();
  }
View Full Code Here

  Binding binding = scope.getTypeOrPackage(new char[][] {this.token});
  if (!binding.isValidBinding()) {
    if (binding instanceof TypeBinding) {
      scope.problemReporter().invalidType(this, (TypeBinding) binding);
    } else if (binding instanceof PackageBinding) {
      ProblemReferenceBinding problemBinding = new ProblemReferenceBinding(((PackageBinding)binding).compoundName, null, binding.problemId());
      scope.problemReporter().invalidType(this, problemBinding);
    }
    throw new SelectionNodeFound();
  }
  throw new SelectionNodeFound(binding);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.