1 12 package org.eclipse.jdi.internal; 13 14 15 import java.io.ByteArrayOutputStream ; 16 import java.io.DataInputStream ; 17 import java.io.DataOutputStream ; 18 import java.io.IOException ; 19 import java.lang.reflect.Field ; 20 import java.lang.reflect.Modifier ; 21 import java.util.ArrayList ; 22 import java.util.Arrays ; 23 import java.util.Collections ; 24 import java.util.HashMap ; 25 import java.util.Iterator ; 26 import java.util.List ; 27 import java.util.Map ; 28 import java.util.Set ; 29 import java.util.TreeSet ; 30 31 import org.eclipse.jdi.internal.jdwp.JdwpCommandPacket; 32 import org.eclipse.jdi.internal.jdwp.JdwpMethodID; 33 import org.eclipse.jdi.internal.jdwp.JdwpReplyPacket; 34 35 import com.ibm.icu.text.MessageFormat; 36 import com.sun.jdi.AbsentInformationException; 37 import com.sun.jdi.ClassLoaderReference; 38 import com.sun.jdi.ClassNotLoadedException; 39 import com.sun.jdi.Locatable; 40 import com.sun.jdi.Location; 41 import com.sun.jdi.Method; 42 import com.sun.jdi.Type; 43 44 45 48 public class MethodImpl extends TypeComponentImpl implements Method, Locatable { 49 50 public static final int INVOKE_SINGLE_THREADED_JDWP = 0x01; 51 public static final int INVOKE_NONVIRTUAL_JDWP = 0x02; 52 53 54 private static String [] fgInvokeOptions = null; 55 56 57 private JdwpMethodID fMethodID; 58 59 60 private List fVariables = null; 61 private long fLowestValidCodeIndex = -1; 62 private long fHighestValidCodeIndex = -1; 63 private Map fCodeIndexToLine = null; 64 private Map fLineToCodeIndexes = null; 65 private Map fStratumAllLineLocations = null; 66 private int fArgumentSlotsCount = -1; 67 private List fArguments = null; 68 private List fArgumentTypes = null; 69 private List fArgumentTypeNames = null; 70 private List fArgumentTypeSignatures = null; 71 private byte[] fByteCodes = null; 72 private long[] fCodeIndexTable; 73 private int[] fJavaStratumLineNumberTable; 74 75 private String fReturnTypeName= null; 76 77 80 public MethodImpl(VirtualMachineImpl vmImpl, ReferenceTypeImpl declaringType, JdwpMethodID methodID, String name, String signature, String genericSignature, int modifierBits) { 81 super("Method", vmImpl, declaringType, name, signature, genericSignature, modifierBits); fMethodID = methodID; 83 } 84 85 88 protected void flushStoredJdwpResults() { 89 fVariables = null; 90 fLowestValidCodeIndex = -1; 91 fHighestValidCodeIndex = -1; 92 fCodeIndexToLine = null; 93 fLineToCodeIndexes = null; 94 fStratumAllLineLocations = null; 95 fCodeIndexTable= null; 96 fJavaStratumLineNumberTable= null; 97 fArgumentSlotsCount = -1; 98 fArguments = null; 99 fArgumentTypes = null; 100 fArgumentTypeNames = null; 101 fArgumentTypeSignatures = null; 102 fByteCodes = null; 103 } 104 105 108 protected JdwpMethodID getMethodID() { 109 return fMethodID; 110 } 111 112 115 protected Map javaStratumCodeIndexToLine() throws AbsentInformationException { 116 if (isAbstract()) { 117 return Collections.EMPTY_MAP; 118 } 119 getLineTable(); 120 return fCodeIndexToLine; 121 } 122 123 126 protected List javaStratumLineToCodeIndexes(int line) throws AbsentInformationException { 127 if (isAbstract() || isNative()) { 128 return null; 129 } 130 getLineTable(); 131 132 return (List )fLineToCodeIndexes.get(new Integer (line)); 133 } 134 135 138 private void getLineTable() throws AbsentInformationException { 139 if (isObsolete()) { 140 return; 141 } 142 if (fCodeIndexToLine != null) { 143 if (fCodeIndexToLine.isEmpty()) { 144 throw new AbsentInformationException(JDIMessages.MethodImpl_Got_empty_line_number_table_for_this_method_1); 145 } 146 return; 147 } 148 149 initJdwpRequest(); 150 try { 151 ByteArrayOutputStream outBytes = new ByteArrayOutputStream (); 152 DataOutputStream outData = new DataOutputStream (outBytes); 153 writeWithReferenceType(this, outData); 154 155 JdwpReplyPacket replyPacket = requestVM(JdwpCommandPacket.M_LINE_TABLE, outBytes); 156 switch (replyPacket.errorCode()) { 157 case JdwpReplyPacket.ABSENT_INFORMATION: 158 throw new AbsentInformationException(JDIMessages.MethodImpl_No_line_number_information_available_2); 159 case JdwpReplyPacket.NATIVE_METHOD: 160 throw new AbsentInformationException(JDIMessages.MethodImpl_No_line_number_information_available_2); 161 } 162 defaultReplyErrorHandler(replyPacket.errorCode()); 163 164 DataInputStream replyData = replyPacket.dataInStream(); 165 fLowestValidCodeIndex = readLong("lowest index", replyData); fHighestValidCodeIndex = readLong("highest index", replyData); int nrOfElements = readInt("elements", replyData); fCodeIndexToLine = new HashMap (); 169 fLineToCodeIndexes = new HashMap (); 170 if (nrOfElements == 0) { 171 throw new AbsentInformationException(JDIMessages.MethodImpl_Got_empty_line_number_table_for_this_method_3); 172 } 173 fCodeIndexTable= new long[nrOfElements]; 174 fJavaStratumLineNumberTable= new int[nrOfElements]; 175 for (int i = 0; i < nrOfElements; i++) { 176 long lineCodeIndex = readLong("code index", replyData); Long lineCodeIndexLong = new Long (lineCodeIndex); 178 int lineNr = readInt("line nr", replyData); Integer lineNrInt = new Integer (lineNr); 180 181 fCodeIndexToLine.put(lineCodeIndexLong, lineNrInt); 183 184 fCodeIndexTable[i]= lineCodeIndex; 185 fJavaStratumLineNumberTable[i]= lineNr; 186 187 List lineNrEntry = (List )fLineToCodeIndexes.get(lineNrInt); 188 if (lineNrEntry == null) { 189 lineNrEntry= new ArrayList (); 190 fLineToCodeIndexes.put(lineNrInt, lineNrEntry); 191 } 192 lineNrEntry.add(lineCodeIndexLong); 193 } 194 } catch (IOException e) { 195 fCodeIndexToLine = null; 196 fLineToCodeIndexes = null; 197 defaultIOExceptionHandler(e); 198 } finally { 199 handledJdwpRequest(); 200 } 201 } 202 203 206 protected int javaStratumLineNumber(long lineCodeIndex) throws AbsentInformationException { 207 if (isAbstract() || isNative() || isObsolete()) { 208 return -1; 209 } 210 getLineTable(); 211 if (lineCodeIndex > fHighestValidCodeIndex) { 212 throw new AbsentInformationException(JDIMessages.MethodImpl_Invalid_code_index_of_a_location_given_4); 213 } 214 215 Long lineCodeIndexObj; 216 Integer lineNrObj; 217 long index= lineCodeIndex; 218 do { 220 lineCodeIndexObj = new Long (index); 221 lineNrObj = (Integer )javaStratumCodeIndexToLine().get(lineCodeIndexObj); 222 } while (lineNrObj == null && --index >= fLowestValidCodeIndex); 223 if (lineNrObj == null) { 224 if (lineCodeIndex >= fLowestValidCodeIndex) { 225 index= lineCodeIndex; 226 do { 227 lineCodeIndexObj = new Long (index); 228 lineNrObj = (Integer )javaStratumCodeIndexToLine().get(lineCodeIndexObj); 229 } while (lineNrObj == null && ++index <= fHighestValidCodeIndex); 230 if (lineNrObj != null) { 231 return lineNrObj.intValue(); 232 } 233 } 234 throw new AbsentInformationException (JDIMessages.MethodImpl_Invalid_code_index_of_a_location_given_4); 235 } 236 return lineNrObj.intValue(); 237 } 238 239 240 243 public List allLineLocations() throws AbsentInformationException { 244 return allLineLocations(virtualMachine().getDefaultStratum(), null); 245 } 246 247 250 public List arguments() throws AbsentInformationException { 251 if (isNative() || isAbstract()) { 252 throw new AbsentInformationException(JDIMessages.MethodImpl_No_local_variable_information_available_9); 253 } 254 if (fArguments != null) { 255 return fArguments; 256 } 257 258 List result = new ArrayList (); 259 Iterator iter = variables().iterator(); 260 while (iter.hasNext()) { 261 LocalVariableImpl var = (LocalVariableImpl)iter.next(); 262 if (var.isArgument()) 263 result.add(var); 264 } 265 fArguments = result; 266 return fArguments; 267 } 268 269 272 public List argumentTypeNames() { 273 if (fArgumentTypeNames != null) { 274 return fArgumentTypeNames; 275 } 276 List argumentTypeSignatures= argumentTypeSignatures(); 277 List result= new ArrayList (); 278 for (Iterator iter= argumentTypeSignatures.iterator(); iter.hasNext();) { 279 result.add(TypeImpl.signatureToName((String ) iter.next())); 280 } 281 282 fArgumentTypeNames= result; 283 return fArgumentTypeNames; 284 } 285 286 287 290 private List argumentTypeSignatures() { 291 if (fArgumentTypeSignatures != null) { 292 return fArgumentTypeSignatures; 293 } 294 295 fArgumentTypeSignatures= GenericSignature.getParameterTypes(signature()); 296 return fArgumentTypeSignatures; 297 } 298 299 302 public List argumentTypes() throws ClassNotLoadedException { 303 if (fArgumentTypes != null) { 304 return fArgumentTypes; 305 } 306 307 List result = new ArrayList (); 308 Iterator iter = argumentTypeSignatures().iterator(); 309 ClassLoaderReference classLoaderRef= declaringType().classLoader(); 310 VirtualMachineImpl vm= virtualMachineImpl(); 311 while (iter.hasNext()) { 312 String argumentTypeSignature = (String )iter.next(); 313 result.add(TypeImpl.create(vm, argumentTypeSignature, classLoaderRef)); 314 } 315 fArgumentTypes = result; 316 return fArgumentTypes; 317 } 318 319 322 public byte[] bytecodes() { 323 if (fByteCodes != null) { 324 return fByteCodes; 325 } 326 327 initJdwpRequest(); 328 try { 329 ByteArrayOutputStream outBytes = new ByteArrayOutputStream (); 330 DataOutputStream outData = new DataOutputStream (outBytes); 331 writeWithReferenceType(this, outData); 332 333 JdwpReplyPacket replyPacket = requestVM(JdwpCommandPacket.M_BYTECODES, outBytes); 334 defaultReplyErrorHandler(replyPacket.errorCode()); 335 336 DataInputStream replyData = replyPacket.dataInStream(); 337 int length = readInt("length", replyData); fByteCodes = readByteArray(length, "bytecodes", replyData); return fByteCodes; 340 } catch (IOException e) { 341 fByteCodes = null; 342 defaultIOExceptionHandler(e); 343 return null; 344 } finally { 345 handledJdwpRequest(); 346 } 347 } 348 349 352 public int hashCode() { 353 return fMethodID.hashCode(); 354 } 355 356 360 public boolean equals(Object object) { 361 return object != null 362 && object.getClass().equals(this.getClass()) 363 && fMethodID.equals(((MethodImpl)object).fMethodID) 364 && referenceTypeImpl().equals(((MethodImpl)object).referenceTypeImpl()); 365 } 366 367 370 public int compareTo(Object object) { 371 if (object == null || !object.getClass().equals(this.getClass())) 372 throw new ClassCastException (JDIMessages.MethodImpl_Can__t_compare_method_to_given_object_6); 373 374 Method type2 = (Method)object; 376 if (!declaringType().equals(type2.declaringType())) 377 return declaringType().compareTo(type2.declaringType()); 378 379 int index1 = declaringType().methods().indexOf(this); 381 int index2 = type2.declaringType().methods().indexOf(type2); 382 if (index1 < index2) { 383 return -1; 384 } else if (index1 > index2) { 385 return 1; 386 } else { 387 return 0; 388 } 389 } 390 391 392 395 public boolean isAbstract() { 396 return (fModifierBits & MODIFIER_ACC_ABSTRACT) != 0; 397 } 398 399 400 403 public boolean isConstructor() { 404 return name().equals("<init>"); } 406 407 410 public boolean isNative() { 411 return (fModifierBits & MODIFIER_ACC_NATIVE) != 0; 412 } 413 414 417 public boolean isStaticInitializer() { 418 return name().equals("<clinit>"); } 420 421 424 public boolean isSynchronized() { 425 return (fModifierBits & MODIFIER_ACC_SYNCHRONIZED) != 0; 426 } 427 428 431 public Location locationOfCodeIndex(long index) { 432 if (isAbstract() || isNative()) { 433 return null; 434 } 435 try { 436 Integer lineNrInt = (Integer )javaStratumCodeIndexToLine().get(new Long (index)); 437 if (lineNrInt == null) { 438 throw new AbsentInformationException(MessageFormat.format(JDIMessages.MethodImpl_No_valid_location_at_the_specified_code_index__0__2, new Object []{Long.toString(index)})); 439 } 440 } catch (AbsentInformationException e ) { 441 } 442 return new LocationImpl(virtualMachineImpl(), this, index); 443 } 444 445 448 public List locationsOfLine(int line) throws AbsentInformationException { 449 return locationsOfLine(virtualMachine().getDefaultStratum(), null, line); 450 } 451 452 455 public Type returnType() throws ClassNotLoadedException { 456 int startIndex = signature().lastIndexOf(')') + 1; return TypeImpl.create(virtualMachineImpl(), signature().substring(startIndex), declaringType().classLoader()); 458 } 459 460 461 464 public String returnTypeName() { 465 if (fReturnTypeName != null) { 466 return fReturnTypeName; 467 } 468 int startIndex = signature().lastIndexOf(')') + 1; fReturnTypeName= TypeImpl.signatureToName(signature().substring(startIndex)); 470 return fReturnTypeName; 471 } 472 473 474 477 public List variables() throws AbsentInformationException { 478 if (isNative() || isAbstract()) { 479 throw new AbsentInformationException(JDIMessages.MethodImpl_No_local_variable_information_available_9); 480 } 481 482 if (fVariables != null) { 483 return fVariables; 484 } 485 486 initJdwpRequest(); 487 try { 488 ByteArrayOutputStream outBytes = new ByteArrayOutputStream (); 489 DataOutputStream outData = new DataOutputStream (outBytes); 490 writeWithReferenceType(this, outData); 491 492 boolean withGenericSignature= virtualMachineImpl().isJdwpVersionGreaterOrEqual(1, 5); 493 int jdwpCommand= withGenericSignature ? JdwpCommandPacket.M_VARIABLE_TABLE_WITH_GENERIC : JdwpCommandPacket.M_VARIABLE_TABLE; 494 JdwpReplyPacket replyPacket = requestVM(jdwpCommand, outBytes); 495 switch (replyPacket.errorCode()) { 496 case JdwpReplyPacket.ABSENT_INFORMATION: 497 return inferArguments(); 498 } 499 500 defaultReplyErrorHandler(replyPacket.errorCode()); 501 502 DataInputStream replyData = replyPacket.dataInStream(); 503 fArgumentSlotsCount = readInt("arg count", replyData); int nrOfElements = readInt("elements", replyData); List variables = new ArrayList (nrOfElements); 506 for (int i = 0; i < nrOfElements; i++) { 507 long codeIndex = readLong("code index", replyData); String name = readString("name", replyData); String signature = readString("signature", replyData); String genericSignature= null; 511 if (withGenericSignature) { 512 genericSignature= readString("generic signature", replyData); if ("".equals(genericSignature)) { genericSignature= null; 515 } 516 } 517 int length = readInt("length", replyData); int slot = readInt("slot", replyData); boolean isArgument = slot < fArgumentSlotsCount; 520 521 if (isStatic() || slot > 0) { 523 LocalVariableImpl localVar = new LocalVariableImpl(virtualMachineImpl(), this, codeIndex, name, signature, genericSignature, length, slot, isArgument); 524 variables.add(localVar); 525 } 526 } 527 fVariables= variables; 528 return fVariables; 529 } catch (IOException e) { 530 fArgumentSlotsCount = -1; 531 fVariables = null; 532 defaultIOExceptionHandler(e); 533 return null; 534 } finally { 535 handledJdwpRequest(); 536 } 537 } 538 539 540 543 private List inferArguments() throws AbsentInformationException { 544 546 String genericSignature= genericSignature(); 548 String [] signatures= (String []) argumentTypeSignatures().toArray(new String [0]); 549 String [] genericSignatures; 550 if (genericSignature == null) { 551 genericSignatures= new String [signatures.length]; 552 } else { 553 genericSignatures= (String []) GenericSignature.getParameterTypes(genericSignature).toArray(new String [0]); 554 for (int i= 0; i < genericSignatures.length; i++) { 555 if (genericSignatures[i].equals(signatures[i])) { 556 genericSignatures[i]= null; 557 } 558 } 559 } 560 561 int slot = 0; 562 if (!isStatic()) { 563 slot++; 564 } 565 if (signatures.length >0) { 566 fArgumentSlotsCount = signatures.length; 567 fVariables = new ArrayList (fArgumentSlotsCount); 568 for (int i = 0; i < signatures.length; i++) { 569 String name = "arg" + i; LocalVariableImpl localVar = new LocalVariableImpl(virtualMachineImpl(), this, 0, name, signatures[i], genericSignatures[i], -1, slot, true); 571 fVariables.add(localVar); 572 slot++; 573 } 574 return fVariables; 575 } 576 throw new AbsentInformationException(JDIMessages.MethodImpl_No_local_variable_information_available_9); 577 578 } 579 580 583 public List variablesByName(String name) throws AbsentInformationException { 584 Iterator iter = variables().iterator(); 585 List result = new ArrayList (); 586 while (iter.hasNext()) { 587 LocalVariableImpl var = (LocalVariableImpl)iter.next(); 588 if (var.name().equals(name)) { 589 result.add(var); 590 } 591 } 592 return result; 593 } 594 595 598 public Location location() { 599 if (isAbstract()) { 600 return null; 601 } 602 if (isNative()) { 603 return new LocationImpl(virtualMachineImpl(), this, -1); 604 } 605 try { 607 getLineTable(); 608 } catch (AbsentInformationException e) { 609 return new LocationImpl(virtualMachineImpl(), this, -1); 610 } 611 612 return new LocationImpl(virtualMachineImpl(), this, fLowestValidCodeIndex); 614 } 615 616 619 public void write(MirrorImpl target, DataOutputStream out) throws IOException { 620 fMethodID.write(out); 621 if (target.fVerboseWriter != null) { 622 target.fVerboseWriter.println("method", fMethodID.value()); } 624 } 625 626 629 protected void writeWithReferenceType(MirrorImpl target, DataOutputStream out) throws IOException { 630 referenceTypeImpl().write(target, out); 631 write(target, out); 632 } 633 634 637 protected void writeWithReferenceTypeWithTag(MirrorImpl target, DataOutputStream out) throws IOException { 638 referenceTypeImpl().writeWithTag(target, out); 639 write(target, out); 640 } 641 642 645 protected static MethodImpl readWithReferenceTypeWithTag(MirrorImpl target, DataInputStream in) throws IOException { 646 VirtualMachineImpl vmImpl = target.virtualMachineImpl(); 647 ReferenceTypeImpl referenceType = ReferenceTypeImpl.readWithTypeTag(target, in); 649 if (referenceType == null) 650 return null; 651 652 JdwpMethodID ID = new JdwpMethodID(vmImpl); 653 if (target.fVerboseWriter != null) { 654 target.fVerboseWriter.println("method", ID.value()); } 656 657 ID.read(in); 658 if (ID.isNull()) { 659 return null; 660 } 661 662 MethodImpl method = referenceType.findMethod(ID); 664 if (method == null) { 665 throw new InternalError (JDIMessages.MethodImpl_Got_MethodID_of_ReferenceType_that_is_not_a_member_of_the_ReferenceType_10); 666 } 667 return method; 668 } 669 670 673 protected static MethodImpl readWithNameSignatureModifiers(ReferenceTypeImpl target, ReferenceTypeImpl referenceType, boolean withGenericSignature, DataInputStream in) throws IOException { 674 VirtualMachineImpl vmImpl = target.virtualMachineImpl(); 675 JdwpMethodID ID = new JdwpMethodID(vmImpl); 676 ID.read(in); 677 if (target.fVerboseWriter != null) { 678 target.fVerboseWriter.println("method", ID.value()); } 680 681 if (ID.isNull()) { 682 return null; 683 } 684 String name = target.readString("name", in); String signature = target.readString("signature", in); String genericSignature= null; 687 if (withGenericSignature) { 688 genericSignature= target.readString("generic signature", in); if ("".equals(genericSignature)) { genericSignature= null; 691 } 692 } 693 int modifierBits= target.readInt("modifiers", AccessibleImpl.getModifierStrings(), in); 695 MethodImpl mirror = new MethodImpl(vmImpl, referenceType, ID, name, signature, genericSignature, modifierBits); 696 return mirror; 697 } 698 699 702 public static void getConstantMaps() { 703 if (fgInvokeOptions != null) { 704 return; 705 } 706 707 Field [] fields = MethodImpl.class.getDeclaredFields(); 708 fgInvokeOptions = new String [32]; 709 710 for (int i = 0; i < fields.length; i++) { 711 Field field = fields[i]; 712 if ((field.getModifiers() & Modifier.PUBLIC) == 0 || (field.getModifiers() & java.lang.reflect.Modifier.STATIC) == 0 || (field.getModifiers() & Modifier.FINAL) == 0) { 713 continue; 714 } 715 716 try { 717 String name = field.getName(); 718 719 if (name.startsWith("INVOKE_")) { int value = field.getInt(null); 721 for (int j = 0; j < fgInvokeOptions.length; j++) { 722 if ((1 << j & value) != 0) { 723 fgInvokeOptions[j]= name; 724 break; 725 } 726 } 727 } 728 } catch (IllegalAccessException e) { 729 } catch (IllegalArgumentException e) { 731 } 735 } 736 } 737 738 741 protected static String [] getInvokeOptions() { 742 getConstantMaps(); 743 return fgInvokeOptions; 744 } 745 754 public boolean isObsolete() { 755 if (virtualMachineImpl().isJdwpVersionGreaterOrEqual(1, 4)) { 756 return fMethodID.value() == 0; 757 } 758 return false; 759 } 760 761 764 public List allLineLocations(String stratum, String sourceName) throws AbsentInformationException { 765 if (isAbstract() || isNative()) { 766 return Collections.EMPTY_LIST; 767 } 768 if (stratum == null) { stratum= declaringType().defaultStratum(); 770 } 771 List allLineLocations= null; 772 Map sourceNameAllLineLocations= null; 773 if (fStratumAllLineLocations == null) { fStratumAllLineLocations= new HashMap (); 775 } else { 776 sourceNameAllLineLocations= (Map )fStratumAllLineLocations.get(stratum); 778 } 779 if (sourceNameAllLineLocations == null) { sourceNameAllLineLocations= new HashMap (); 781 fStratumAllLineLocations.put(stratum, sourceNameAllLineLocations); 782 } else { 783 allLineLocations= (List )sourceNameAllLineLocations.get(sourceName); 785 } 786 if (allLineLocations == null) { getLineTable(); 788 allLineLocations= referenceTypeImpl().allLineLocations(stratum, sourceName, this, fCodeIndexTable, fJavaStratumLineNumberTable); 789 sourceNameAllLineLocations.put(sourceName, allLineLocations); 790 } 791 return allLineLocations; 792 } 793 794 797 public List locationsOfLine(String stratum, String sourceName, int lineNumber) throws AbsentInformationException { 798 if (isAbstract() || isNative()) { 799 return Collections.EMPTY_LIST; 800 } 801 return referenceTypeImpl().locationsOfLine(stratum, sourceName, lineNumber, this); 802 } 803 804 809 protected List javaStratumLocationsOfLines(List javaLines) throws AbsentInformationException { 810 Set tmpLocations= new TreeSet (); 811 for (Iterator iter = javaLines.iterator(); iter.hasNext();) { 812 Integer key = (Integer )iter.next(); 813 List indexes= javaStratumLineToCodeIndexes(key.intValue()); 814 if (indexes != null) { 815 tmpLocations.addAll(indexes); 816 } 817 } 818 List locations = new ArrayList (); 819 for (Iterator iter = tmpLocations.iterator(); iter.hasNext();) { 820 long index = ((Long )iter.next()).longValue(); 821 int position= Arrays.binarySearch(fCodeIndexTable, index); 822 if (position == 0 || !tmpLocations.contains(new Long (fCodeIndexTable[position - 1]))) { 823 locations.add(new LocationImpl(virtualMachineImpl(), this, index)); 824 } 825 } 826 return locations; 827 } 828 829 public boolean isBridge() { 830 return (fModifierBits & MODIFIER_ACC_BRIDGE) != 0; 831 } 832 833 public boolean isVarArgs() { 834 return !virtualMachine().name().equals("j9") && (fModifierBits & MODIFIER_ACC_VARARGS) != 0; } 839 } 840 | Popular Tags |