1 11 package org.eclipse.jdt.internal.compiler.lookup; 12 13 public class ProblemMethodBinding extends MethodBinding { 14 15 private int problemReason; 16 public MethodBinding closestMatch; 18 public ProblemMethodBinding(char[] selector, TypeBinding[] args, int problemReason) { 19 this.selector = selector; 20 this.parameters = (args == null || args.length == 0) ? Binding.NO_PARAMETERS : args; 21 this.problemReason = problemReason; 22 this.thrownExceptions = Binding.NO_EXCEPTIONS; 23 } 24 public ProblemMethodBinding(char[] selector, TypeBinding[] args, ReferenceBinding declaringClass, int problemReason) { 25 this.selector = selector; 26 this.parameters = (args == null || args.length == 0) ? Binding.NO_PARAMETERS : args; 27 this.declaringClass = declaringClass; 28 this.problemReason = problemReason; 29 this.thrownExceptions = Binding.NO_EXCEPTIONS; 30 } 31 public ProblemMethodBinding(MethodBinding closestMatch, char[] selector, TypeBinding[] args, int problemReason) { 32 this(selector, args, problemReason); 33 this.closestMatch = closestMatch; 34 if (closestMatch != null && problemReason != ProblemReasons.Ambiguous) this.declaringClass = closestMatch.declaringClass; 35 } 36 40 41 public final int problemId() { 42 return this.problemReason; 43 } 44 } 45 | Popular Tags |