1 /* 2 * Copyright (c) 1998, 2019, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26 JDWP "Java(tm) Debug Wire Protocol" 27 (CommandSet VirtualMachine=1 28 (Command Version=1 29 "Returns the JDWP version implemented by the target VM. " 30 "The version string format is implementation dependent. " 31 (Out 32 ) 33 (Reply 34 (string description "Text information on the VM version") 35 (int jdwpMajor "Major JDWP Version number") 36 (int jdwpMinor "Minor JDWP Version number") 37 (string vmVersion "Target VM JRE version, as in the java.version property") 38 (string vmName "Target VM name, as in the java.vm.name property") 39 ) 40 (ErrorSet 41 (Error VM_DEAD) 42 ) 43 ) 44 (Command ClassesBySignature=2 45 "Returns reference types for all the classes loaded by the target VM " 46 "which match the given signature. " 47 "Multple reference types will be returned if two or more class " 48 "loaders have loaded a class of the same name. " 49 "The search is confined to loaded classes only; no attempt is made " 50 "to load a class of the given signature. " 51 (Out 52 (string signature "JNI signature of the class to find " 53 "(for example, \"Ljava/lang/String;\"). " 54 ) 55 ) 56 (Reply 57 (Repeat classes "Number of reference types that follow." 58 (Group ClassInfo 59 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 60 "of following reference type. ") 61 (referenceTypeID typeID "Matching loaded reference type") 62 (int status "The current class " 63 "<a href=\"#JDWP_ClassStatus\">status.</a> ") 64 ) 65 ) 66 ) 67 (ErrorSet 68 (Error VM_DEAD) 69 ) 70 ) 71 (Command AllClasses=3 72 "Returns reference types for all classes currently loaded by the " 73 "target VM. " 74 "See <a href=\"../jvmti.html#GetLoadedClasses\">JVM TI GetLoadedClasses</a>." 75 (Out 76 ) 77 (Reply 78 (Repeat classes "Number of reference types that follow." 79 (Group ClassInfo 80 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 81 "of following reference type. ") 82 (referenceTypeID typeID "Loaded reference type") 83 (string signature 84 "The JNI signature of the loaded reference type") 85 (int status "The current class " 86 "<a href=\"#JDWP_ClassStatus\">status.</a> ") 87 ) 88 ) 89 ) 90 (ErrorSet 91 (Error VM_DEAD) 92 ) 93 ) 94 (Command AllThreads=4 95 "Returns all threads currently running in the target VM . " 96 "The returned list contains threads created through " 97 "java.lang.Thread, all native threads attached to " 98 "the target VM through JNI, and system threads created " 99 "by the target VM. Threads that have not yet been started " 100 "and threads that have completed their execution are not " 101 "included in the returned list. " 102 (Out 103 ) 104 (Reply 105 (Repeat threads "Number of threads that follow." 106 (threadObject thread "A running thread") 107 ) 108 ) 109 (ErrorSet 110 (Error VM_DEAD) 111 ) 112 ) 113 (Command TopLevelThreadGroups=5 114 "Returns all thread groups that do not have a parent. This command " 115 "may be used as the first step in building a tree (or trees) of the " 116 "existing thread groups." 117 (Out 118 ) 119 (Reply 120 (Repeat groups "Number of thread groups that follow." 121 (threadGroupObject group "A top level thread group") 122 ) 123 ) 124 (ErrorSet 125 (Error VM_DEAD) 126 ) 127 ) 128 (Command Dispose=6 129 "Invalidates this virtual machine mirror. " 130 "The communication channel to the target VM is closed, and " 131 "the target VM prepares to accept another subsequent connection " 132 "from this debugger or another debugger, including the " 133 "following tasks: " 134 "<ul>" 135 "<li>All event requests are cancelled. " 136 "<li>All threads suspended by the thread-level " 137 "<a href=\"#JDWP_ThreadReference_Resume\">resume</a> command " 138 "or the VM-level " 139 "<a href=\"#JDWP_VirtualMachine_Resume\">resume</a> command " 140 "are resumed as many times as necessary for them to run. " 141 "<li>Garbage collection is re-enabled in all cases where it was " 142 "<a href=\"#JDWP_ObjectReference_DisableCollection\">disabled</a> " 143 "</ul>" 144 "Any current method invocations executing in the target VM " 145 "are continued after the disconnection. Upon completion of any such " 146 "method invocation, the invoking thread continues from the " 147 "location where it was originally stopped. " 148 "<p>" 149 "Resources originating in " 150 "this VirtualMachine (ObjectReferences, ReferenceTypes, etc.) " 151 "will become invalid. " 152 (Out 153 ) 154 (Reply 155 ) 156 (ErrorSet 157 ) 158 ) 159 (Command IDSizes=7 160 "Returns the sizes of variably-sized data types in the target VM." 161 "The returned values indicate the number of bytes used by the " 162 "identifiers in command and reply packets." 163 (Out 164 ) 165 (Reply 166 (int fieldIDSize "fieldID size in bytes ") 167 (int methodIDSize "methodID size in bytes ") 168 (int objectIDSize "objectID size in bytes ") 169 (int referenceTypeIDSize "referenceTypeID size in bytes ") 170 (int frameIDSize "frameID size in bytes ") 171 ) 172 (ErrorSet 173 (Error VM_DEAD) 174 ) 175 ) 176 (Command Suspend=8 177 "Suspends the execution of the application running in the target " 178 "VM. All Java threads currently running will be suspended. " 179 "<p>" 180 "Unlike java.lang.Thread.suspend, " 181 "suspends of both the virtual machine and individual threads are " 182 "counted. Before a thread will run again, it must be resumed through " 183 "the <a href=\"#JDWP_VirtualMachine_Resume\">VM-level resume</a> command " 184 "or the <a href=\"#JDWP_ThreadReference_Resume\">thread-level resume</a> command " 185 "the same number of times it has been suspended. " 186 (Out 187 ) 188 (Reply 189 ) 190 (ErrorSet 191 (Error VM_DEAD) 192 ) 193 ) 194 (Command Resume=9 195 "Resumes execution of the application after the suspend " 196 "command or an event has stopped it. " 197 "Suspensions of the Virtual Machine and individual threads are " 198 "counted. If a particular thread is suspended n times, it must " 199 "resumed n times before it will continue. " 200 (Out 201 ) 202 (Reply 203 ) 204 (ErrorSet 205 ) 206 ) 207 (Command Exit=10 208 "Terminates the target VM with the given exit code. " 209 "On some platforms, the exit code might be truncated, for " 210 "example, to the low order 8 bits. " 211 "All ids previously returned from the target VM become invalid. " 212 "Threads running in the VM are abruptly terminated. " 213 "A thread death exception is not thrown and " 214 "finally blocks are not run." 215 (Out 216 (int exitCode "the exit code") 217 ) 218 (Reply 219 ) 220 (ErrorSet 221 ) 222 ) 223 (Command CreateString=11 224 "Creates a new string object in the target VM and returns " 225 "its id. " 226 (Out 227 (string utf "UTF-8 characters to use in the created string. ") 228 ) 229 (Reply 230 (stringObject stringObject 231 "Created string (instance of java.lang.String) ") 232 ) 233 (ErrorSet 234 (Error VM_DEAD) 235 ) 236 ) 237 (Command Capabilities=12 238 "Retrieve this VM's capabilities. The capabilities are returned " 239 "as booleans, each indicating the presence or absence of a " 240 "capability. The commands associated with each capability will " 241 "return the NOT_IMPLEMENTED error if the cabability is not " 242 "available." 243 (Out 244 ) 245 (Reply 246 (boolean canWatchFieldModification 247 "Can the VM watch field modification, and therefore " 248 "can it send the Modification Watchpoint Event?") 249 (boolean canWatchFieldAccess 250 "Can the VM watch field access, and therefore " 251 "can it send the Access Watchpoint Event?") 252 (boolean canGetBytecodes 253 "Can the VM get the bytecodes of a given method? ") 254 (boolean canGetSyntheticAttribute 255 "Can the VM determine whether a field or method is " 256 "synthetic? (that is, can the VM determine if the " 257 "method or the field was invented by the compiler?) ") 258 (boolean canGetOwnedMonitorInfo 259 "Can the VM get the owned monitors infornation for " 260 "a thread?") 261 (boolean canGetCurrentContendedMonitor 262 "Can the VM get the current contended monitor of a thread?") 263 (boolean canGetMonitorInfo 264 "Can the VM get the monitor information for a given object? ") 265 ) 266 (ErrorSet 267 (Error VM_DEAD) 268 ) 269 ) 270 (Command ClassPaths=13 271 "Retrieve the classpath and bootclasspath of the target VM. " 272 "If the classpath is not defined, returns an empty list. If the " 273 "bootclasspath is not defined returns an empty list." 274 (Out 275 ) 276 (Reply 277 (string baseDir "Base directory used to resolve relative " 278 "paths in either of the following lists.") 279 (Repeat classpaths "Number of paths in classpath." 280 (string path "One component of classpath") ) 281 (Repeat bootclasspaths "Number of paths in bootclasspath." 282 (string path "One component of bootclasspath") ) 283 ) 284 (ErrorSet 285 (Error VM_DEAD) 286 ) 287 ) 288 (Command DisposeObjects=14 289 "Releases a list of object IDs. For each object in the list, the " 290 "following applies. " 291 "The count of references held by the back-end (the reference " 292 "count) will be decremented by refCnt. " 293 "If thereafter the reference count is less than " 294 "or equal to zero, the ID is freed. " 295 "Any back-end resources associated with the freed ID may " 296 "be freed, and if garbage collection was " 297 "disabled for the object, it will be re-enabled. " 298 "The sender of this command " 299 "promises that no further commands will be sent " 300 "referencing a freed ID. 301 "<p>" 302 "Use of this command is not required. If it is not sent, " 303 "resources associated with each ID will be freed by the back-end " 304 "at some time after the corresponding object is garbage collected. " 305 "It is most useful to use this command to reduce the load on the " 306 "back-end if a very large number of " 307 "objects has been retrieved from the back-end (a large array, " 308 "for example) but may not be garbage collected any time soon. " 309 "<p>" 310 "IDs may be re-used by the back-end after they " 311 "have been freed with this command." 312 "This description assumes reference counting, " 313 "a back-end may use any implementation which operates " 314 "equivalently. " 315 (Out 316 (Repeat requests "Number of object dispose requests that follow" 317 (Group Request 318 (object object "The object ID") 319 (int refCnt "The number of times this object ID has been " 320 "part of a packet received from the back-end. " 321 "An accurate count prevents the object ID " 322 "from being freed on the back-end if " 323 "it is part of an incoming packet, not yet " 324 "handled by the front-end.") 325 ) 326 ) 327 ) 328 (Reply 329 ) 330 (ErrorSet 331 ) 332 ) 333 (Command HoldEvents=15 334 "Tells the target VM to stop sending events. Events are not discarded; " 335 "they are held until a subsequent ReleaseEvents command is sent. " 336 "This command is useful to control the number of events sent " 337 "to the debugger VM in situations where very large numbers of events " 338 "are generated. " 339 "While events are held by the debugger back-end, application " 340 "execution may be frozen by the debugger back-end to prevent " 341 "buffer overflows on the back end. 342 "Responses to commands are never held and are not affected by this 343 "command. If events are already being held, this command is " 344 "ignored." 345 (Out 346 ) 347 (Reply 348 ) 349 (ErrorSet 350 ) 351 ) 352 (Command ReleaseEvents=16 353 "Tells the target VM to continue sending events. This command is " 354 "used to restore normal activity after a HoldEvents command. If " 355 "there is no current HoldEvents command in effect, this command is " 356 "ignored." 357 (Out 358 ) 359 (Reply 360 ) 361 (ErrorSet 362 ) 363 ) 364 (Command CapabilitiesNew=17 365 "Retrieve all of this VM's capabilities. The capabilities are returned " 366 "as booleans, each indicating the presence or absence of a " 367 "capability. The commands associated with each capability will " 368 "return the NOT_IMPLEMENTED error if the cabability is not " 369 "available." 370 "Since JDWP version 1.4." 371 (Out 372 ) 373 (Reply 374 (boolean canWatchFieldModification 375 "Can the VM watch field modification, and therefore " 376 "can it send the Modification Watchpoint Event?") 377 (boolean canWatchFieldAccess 378 "Can the VM watch field access, and therefore " 379 "can it send the Access Watchpoint Event?") 380 (boolean canGetBytecodes 381 "Can the VM get the bytecodes of a given method? ") 382 (boolean canGetSyntheticAttribute 383 "Can the VM determine whether a field or method is " 384 "synthetic? (that is, can the VM determine if the " 385 "method or the field was invented by the compiler?) ") 386 (boolean canGetOwnedMonitorInfo 387 "Can the VM get the owned monitors infornation for " 388 "a thread?") 389 (boolean canGetCurrentContendedMonitor 390 "Can the VM get the current contended monitor of a thread?") 391 (boolean canGetMonitorInfo 392 "Can the VM get the monitor information for a given object? ") 393 (boolean canRedefineClasses 394 "Can the VM redefine classes?") 395 (boolean canAddMethod 396 "Can the VM add methods when redefining " 397 "classes?") 398 (boolean canUnrestrictedlyRedefineClasses 399 "Can the VM redefine classes " 400 "in ways that are normally restricted?") 401 (boolean canPopFrames 402 "Can the VM pop stack frames?") 403 (boolean canUseInstanceFilters 404 "Can the VM filter events by specific object?") 405 (boolean canGetSourceDebugExtension 406 "Can the VM get the source debug extension?") 407 (boolean canRequestVMDeathEvent 408 "Can the VM request VM death events?") 409 (boolean canSetDefaultStratum 410 "Can the VM set a default stratum?") 411 (boolean canGetInstanceInfo 412 "Can the VM return instances, counts of instances of classes " 413 "and referring objects?") 414 (boolean canRequestMonitorEvents 415 "Can the VM request monitor events?") 416 (boolean canGetMonitorFrameInfo 417 "Can the VM get monitors with frame depth info?") 418 (boolean canUseSourceNameFilters 419 "Can the VM filter class prepare events by source name?") 420 (boolean canGetConstantPool 421 "Can the VM return the constant pool information?") 422 (boolean canForceEarlyReturn 423 "Can the VM force early return from a method?") 424 (boolean reserved22 425 "Reserved for future capability") 426 (boolean reserved23 427 "Reserved for future capability") 428 (boolean reserved24 429 "Reserved for future capability") 430 (boolean reserved25 431 "Reserved for future capability") 432 (boolean reserved26 433 "Reserved for future capability") 434 (boolean reserved27 435 "Reserved for future capability") 436 (boolean reserved28 437 "Reserved for future capability") 438 (boolean reserved29 439 "Reserved for future capability") 440 (boolean reserved30 441 "Reserved for future capability") 442 (boolean reserved31 443 "Reserved for future capability") 444 (boolean reserved32 445 "Reserved for future capability") 446 ) 447 (ErrorSet 448 (Error VM_DEAD) 449 ) 450 ) 451 (Command RedefineClasses=18 452 "Installs new class definitions. " 453 "If there are active stack frames in methods of the redefined classes in the " 454 "target VM then those active frames continue to run the bytecodes of the " 455 "original method. These methods are considered obsolete - see " 456 "<a href=\"#JDWP_Method_IsObsolete\">IsObsolete</a>. The methods in the " 457 "redefined classes will be used for new invokes in the target VM. " 458 "The original method ID refers to the redefined method. " 459 "All breakpoints in the redefined classes are cleared." 460 "If resetting of stack frames is desired, the " 461 "<a href=\"#JDWP_StackFrame_PopFrames\">PopFrames</a> command can be used " 462 "to pop frames with obsolete methods." 463 "<p>" 464 "Unless the canUnrestrictedlyRedefineClasses capability is present the following " 465 "redefinitions are restricted: " 466 "<ul>" 467 "<li>changing the schema (the fields)</li>" 468 "<li>changing the hierarchy (superclasses, interfaces)</li>" 469 "<li>deleting a method</li>" 470 "<li>changing class modifiers</li>" 471 "<li>changing method modifiers</li>" 472 "<li>changing the <code>NestHost</code>, <code>NestMembers</code>, or <code>Record</code> class attributes</li>" 473 "</ul>" 474 "<p>" 475 "Requires canRedefineClasses capability - see " 476 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 477 "In addition to the canRedefineClasses capability, the target VM must " 478 "have the canAddMethod capability to add methods when redefining classes, " 479 "or the canUnrestrictedlyRedefineClasses capability to redefine classes in ways " 480 "that are normally restricted." 481 (Out 482 (Repeat classes "Number of reference types that follow." 483 (Group ClassDef 484 (referenceType refType "The reference type.") 485 (Repeat classfile "Number of bytes defining class (below)" 486 (byte classbyte "byte in JVM class file " 487 "format.") 488 ) 489 ) 490 ) 491 ) 492 (Reply 493 ) 494 (ErrorSet 495 (Error INVALID_CLASS "One of the refTypes is not the ID of a reference " 496 "type.") 497 (Error INVALID_OBJECT "One of the refTypes is not a known ID.") 498 (Error UNSUPPORTED_VERSION) 499 (Error INVALID_CLASS_FORMAT) 500 (Error CIRCULAR_CLASS_DEFINITION) 501 (Error FAILS_VERIFICATION) 502 (Error NAMES_DONT_MATCH) 503 (Error NOT_IMPLEMENTED "No aspect of this functionality is implemented " 504 "(CapabilitiesNew.canRedefineClasses is false)") 505 (Error ADD_METHOD_NOT_IMPLEMENTED) 506 (Error SCHEMA_CHANGE_NOT_IMPLEMENTED) 507 (Error HIERARCHY_CHANGE_NOT_IMPLEMENTED) 508 (Error DELETE_METHOD_NOT_IMPLEMENTED) 509 (Error CLASS_MODIFIERS_CHANGE_NOT_IMPLEMENTED) 510 (Error METHOD_MODIFIERS_CHANGE_NOT_IMPLEMENTED) 511 (Error CLASS_ATTRIBUTE_CHANGE_NOT_IMPLEMENTED) 512 (Error VM_DEAD) 513 ) 514 ) 515 (Command SetDefaultStratum=19 516 "Set the default stratum. Requires canSetDefaultStratum capability - see " 517 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 518 (Out 519 (string stratumID "default stratum, or empty string to use " 520 "reference type default.") 521 ) 522 (Reply 523 ) 524 (ErrorSet 525 (Error NOT_IMPLEMENTED) 526 (Error VM_DEAD) 527 ) 528 ) 529 (Command AllClassesWithGeneric=20 530 "Returns reference types for all classes currently loaded by the " 531 "target VM. " 532 "Both the JNI signature and the generic signature are " 533 "returned for each class. " 534 "Generic signatures are described in the signature attribute " 535 "section in " 536 "<cite>The Java™ Virtual Machine Specification</cite>. " 537 "Since JDWP version 1.5." 538 (Out 539 ) 540 (Reply 541 (Repeat classes "Number of reference types that follow." 542 (Group ClassInfo 543 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 544 "of following reference type. ") 545 (referenceTypeID typeID "Loaded reference type") 546 (string signature 547 "The JNI signature of the loaded reference type.") 548 (string genericSignature 549 "The generic signature of the loaded reference type " 550 "or an empty string if there is none.") 551 (int status "The current class " 552 "<a href=\"#JDWP_ClassStatus\">status.</a> ") 553 ) 554 ) 555 ) 556 (ErrorSet 557 (Error VM_DEAD) 558 ) 559 ) 560 561 (Command InstanceCounts=21 562 "Returns the number of instances of each reference type in the input list. " 563 "Only instances that are reachable for the purposes of " 564 "garbage collection are counted. If a reference type is invalid, " 565 "eg. it has been unloaded, zero is returned for its instance count." 566 "<p>Since JDWP version 1.6. Requires canGetInstanceInfo capability - see " 567 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 568 (Out 569 (Repeat refTypesCount "Number of reference types that follow. Must be non-negative." 570 (referenceType refType "A reference type ID.") 571 ) 572 ) 573 (Reply 574 (Repeat counts "The number of counts that follow." 575 (long instanceCount "The number of instances for the corresponding reference type " 576 "in 'Out Data'.") 577 ) 578 ) 579 (ErrorSet 580 (Error ILLEGAL_ARGUMENT "refTypesCount is less than zero.") 581 (Error NOT_IMPLEMENTED) 582 (Error VM_DEAD) 583 ) 584 ) 585 (Command AllModules=22 586 "Returns all modules in the target VM." 587 "<p>Since JDWP version 9." 588 (Out 589 ) 590 (Reply 591 (Repeat modules "The number of the modules that follow." 592 (moduleID module "One of the modules.") 593 ) 594 ) 595 (ErrorSet 596 (Error NOT_IMPLEMENTED) 597 (Error VM_DEAD) 598 ) 599 ) 600 ) 601 602 (CommandSet ReferenceType=2 603 (Command Signature=1 604 "Returns the type signature of a reference type. " 605 "Type signature formats are the same as specified in " 606 "<a href=\"../jvmti.html#GetClassSignature\">JVM TI GetClassSignature</a>." 607 (Out 608 (referenceType refType "The reference type ID.") 609 ) 610 (Reply 611 (string signature 612 "The JNI signature for the reference type.") 613 ) 614 (ErrorSet 615 (Error INVALID_CLASS "refType is not the ID of a reference " 616 "type.") 617 (Error INVALID_OBJECT "refType is not a known ID.") 618 (Error VM_DEAD) 619 ) 620 ) 621 (Command ClassLoader=2 622 "Returns the instance of java.lang.ClassLoader which loaded " 623 "a given reference type. If the reference type was loaded by the " 624 "system class loader, the returned object ID is null." 625 (Out 626 (referenceType refType "The reference type ID.") 627 ) 628 (Reply 629 (classLoaderObject classLoader "The class loader for the reference type. ") 630 ) 631 (ErrorSet 632 (Error INVALID_CLASS "refType is not the ID of a reference " 633 "type.") 634 (Error INVALID_OBJECT "refType is not a known ID.") 635 (Error VM_DEAD) 636 ) 637 ) 638 (Command Modifiers=3 639 "Returns the modifiers (also known as access flags) for a reference type. " 640 "The returned bit mask contains information on the declaration " 641 "of the reference type. If the reference type is an array or " 642 "a primitive class (for example, java.lang.Integer.TYPE), the " 643 "value of the returned bit mask is undefined." 644 (Out 645 (referenceType refType "The reference type ID.") 646 ) 647 (Reply 648 (int modBits "Modifier bits as defined in Chapter 4 of " 649 "<cite>The Java™ Virtual Machine Specification</cite>") 650 ) 651 (ErrorSet 652 (Error INVALID_CLASS "refType is not the ID of a reference " 653 "type.") 654 (Error INVALID_OBJECT "refType is not a known ID.") 655 (Error VM_DEAD) 656 ) 657 ) 658 (Command Fields=4 659 "Returns information for each field in a reference type. " 660 "Inherited fields are not included. " 661 "The field list will include any synthetic fields created " 662 "by the compiler. " 663 "Fields are returned in the order they occur in the class file." 664 (Out 665 (referenceType refType "The reference type ID.") 666 ) 667 (Reply 668 (Repeat declared "Number of declared fields." 669 (Group FieldInfo 670 (field fieldID "Field ID.") 671 (string name "Name of field.") 672 (string signature "JNI Signature of field.") 673 (int modBits "The modifier bit flags (also known as access flags) " 674 "which provide additional information on the " 675 "field declaration. Individual flag values are " 676 "defined in Chapter 4 of " 677 "<cite>The Java™ Virtual Machine Specification</cite>. " 678 "In addition, The <code>0xf0000000</code> bit identifies " 679 "the field as synthetic, if the synthetic attribute " 680 "<a href=\"#JDWP_VirtualMachine_Capabilities\">capability</a> is available.") 681 ) 682 ) 683 ) 684 (ErrorSet 685 (Error CLASS_NOT_PREPARED) 686 (Error INVALID_CLASS "refType is not the ID of a reference " 687 "type.") 688 (Error INVALID_OBJECT "refType is not a known ID.") 689 (Error VM_DEAD) 690 ) 691 ) 692 (Command Methods=5 693 "Returns information for each method in a reference type. " 694 "Inherited methods are not included. The list of methods will " 695 "include constructors (identified with the name \"<init>\"), " 696 "the initialization method (identified with the name \"<clinit>\") " 697 "if present, and any synthetic methods created by the compiler. " 698 "Methods are returned in the order they occur in the class file." 699 (Out 700 (referenceType refType "The reference type ID.") 701 ) 702 (Reply 703 (Repeat declared "Number of declared methods." 704 (Group MethodInfo 705 (method methodID "Method ID.") 706 (string name "Name of method.") 707 (string signature "JNI signature of method.") 708 (int modBits "The modifier bit flags (also known as access flags) " 709 "which provide additional information on the " 710 "method declaration. Individual flag values are " 711 "defined in Chapter 4 of " 712 "<cite>The Java™ Virtual Machine Specification</cite>. " 713 "In addition, The <code>0xf0000000</code> bit identifies " 714 "the method as synthetic, if the synthetic attribute " 715 "<a href=\"#JDWP_VirtualMachine_Capabilities\">capability</a> is available.") 716 ) 717 ) 718 ) 719 (ErrorSet 720 (Error CLASS_NOT_PREPARED) 721 (Error INVALID_CLASS "refType is not the ID of a reference " 722 "type.") 723 (Error INVALID_OBJECT "refType is not a known ID.") 724 (Error VM_DEAD) 725 ) 726 ) 727 (Command GetValues=6 728 "Returns the value of one or more static fields of the " 729 "reference type. Each field must be member of the reference type " 730 "or one of its superclasses, superinterfaces, or implemented interfaces. " 731 "Access control is not enforced; for example, the values of private " 732 "fields can be obtained." 733 (Out 734 (referenceType refType "The reference type ID.") 735 (Repeat fields "The number of values to get" 736 (Group Field 737 (field fieldID "A field to get") 738 ) 739 ) 740 ) 741 (Reply 742 (Repeat values "The number of values returned, always equal to fields, " 743 "the number of values to get." 744 (value value "The field value") 745 ) 746 ) 747 (ErrorSet 748 (Error INVALID_CLASS "refType is not the ID of a reference " 749 "type.") 750 (Error INVALID_OBJECT "refType is not a known ID.") 751 (Error INVALID_FIELDID) 752 (Error VM_DEAD) 753 ) 754 ) 755 (Command SourceFile=7 756 "Returns the name of source file in which a reference type was " 757 "declared. " 758 (Out 759 (referenceType refType "The reference type ID.") 760 ) 761 (Reply 762 (string sourceFile "The source file name. No path information " 763 "for the file is included") 764 ) 765 (ErrorSet 766 (Error INVALID_CLASS "refType is not the ID of a reference " 767 "type.") 768 (Error INVALID_OBJECT "refType is not a known ID.") 769 (Error ABSENT_INFORMATION "The source file attribute is absent.") 770 (Error VM_DEAD) 771 ) 772 ) 773 (Command NestedTypes=8 774 "Returns the classes and interfaces directly nested within this type." 775 "Types further nested within those types are not included. " 776 (Out 777 (referenceType refType "The reference type ID.") 778 ) 779 (Reply 780 (Repeat classes "The number of nested classes and interfaces" 781 (Group TypeInfo 782 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 783 "of following reference type. ") 784 (referenceTypeID typeID "The nested class or interface ID.") 785 ) 786 ) 787 ) 788 (ErrorSet 789 (Error INVALID_CLASS "refType is not the ID of a reference " 790 "type.") 791 (Error INVALID_OBJECT "refType is not a known ID.") 792 (Error VM_DEAD) 793 ) 794 ) 795 (Command Status=9 796 "Returns the current status of the reference type. The status " 797 "indicates the extent to which the reference type has been " 798 "initialized, as described in section 2.1.6 of " 799 "<cite>The Java™ Virtual Machine Specification</cite>. " 800 "If the class is linked the PREPARED and VERIFIED bits in the returned status bits " 801 "will be set. If the class is initialized the INITIALIZED bit in the returned " 802 "status bits will be set. If an error occured during initialization then the " 803 "ERROR bit in the returned status bits will be set. " 804 "The returned status bits are undefined for array types and for " 805 "primitive classes (such as java.lang.Integer.TYPE). " 806 (Out 807 (referenceType refType "The reference type ID.") 808 ) 809 (Reply 810 (int status "<a href=\"#JDWP_ClassStatus\">Status</a> bits:" 811 "See <a href=\"#JDWP_ClassStatus\">JDWP.ClassStatus</a>") 812 ) 813 (ErrorSet 814 (Error INVALID_CLASS "refType is not the ID of a reference " 815 "type.") 816 (Error INVALID_OBJECT "refType is not a known ID.") 817 (Error VM_DEAD) 818 ) 819 ) 820 (Command Interfaces=10 821 "Returns the interfaces declared as implemented by this class. " 822 "Interfaces indirectly implemented (extended by the implemented " 823 "interface or implemented by a superclass) are not included." 824 (Out 825 (referenceType refType "The reference type ID.") 826 ) 827 (Reply 828 (Repeat interfaces "The number of implemented interfaces" 829 (interfaceType interfaceType "implemented interface.") 830 ) 831 ) 832 (ErrorSet 833 (Error INVALID_CLASS "refType is not the ID of a reference " 834 "type.") 835 (Error INVALID_OBJECT "refType is not a known ID.") 836 (Error VM_DEAD) 837 ) 838 ) 839 (Command ClassObject=11 840 "Returns the class object corresponding to this type. " 841 (Out 842 (referenceType refType "The reference type ID.") 843 ) 844 (Reply 845 (classObject classObject "class object.") 846 ) 847 (ErrorSet 848 (Error INVALID_CLASS "refType is not the ID of a reference " 849 "type.") 850 (Error INVALID_OBJECT "refType is not a known ID.") 851 (Error VM_DEAD) 852 ) 853 ) 854 (Command SourceDebugExtension=12 855 "Returns the value of the SourceDebugExtension attribute. " 856 "Since JDWP version 1.4. Requires canGetSourceDebugExtension capability - see " 857 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 858 (Out 859 (referenceType refType "The reference type ID.") 860 ) 861 (Reply 862 (string extension "extension attribute") 863 ) 864 (ErrorSet 865 (Error INVALID_CLASS "refType is not the ID of a reference " 866 "type.") 867 (Error INVALID_OBJECT "refType is not a known ID.") 868 (Error ABSENT_INFORMATION "If the extension is not specified.") 869 (Error NOT_IMPLEMENTED) 870 (Error VM_DEAD) 871 ) 872 ) 873 (Command SignatureWithGeneric=13 874 "Returns the JNI signature of a reference type along with the " 875 "generic signature if there is one. " 876 "Generic signatures are described in the signature attribute " 877 "section in " 878 "<cite>The Java™ Virtual Machine Specification</cite>. " 879 "Since JDWP version 1.5." 880 (Out 881 (referenceType refType "The reference type ID.") 882 ) 883 (Reply 884 (string signature 885 "The JNI signature for the reference type.") 886 (string genericSignature 887 "The generic signature for the reference type or an empty " 888 "string if there is none.") 889 ) 890 (ErrorSet 891 (Error INVALID_CLASS "refType is not the ID of a reference " 892 "type.") 893 (Error INVALID_OBJECT "refType is not a known ID.") 894 (Error VM_DEAD) 895 ) 896 ) 897 (Command FieldsWithGeneric=14 898 "Returns information, including the generic signature if any, " 899 "for each field in a reference type. " 900 "Inherited fields are not included. " 901 "The field list will include any synthetic fields created " 902 "by the compiler. " 903 "Fields are returned in the order they occur in the class file. " 904 "Generic signatures are described in the signature attribute " 905 "section in " 906 "<cite>The Java™ Virtual Machine Specification</cite>. " 907 "Since JDWP version 1.5." 908 (Out 909 (referenceType refType "The reference type ID.") 910 ) 911 (Reply 912 (Repeat declared "Number of declared fields." 913 (Group FieldInfo 914 (field fieldID "Field ID.") 915 (string name "The name of the field.") 916 (string signature "The JNI signature of the field.") 917 (string genericSignature "The generic signature of the " 918 "field, or an empty string if there is none.") 919 (int modBits "The modifier bit flags (also known as access flags) " 920 "which provide additional information on the " 921 "field declaration. Individual flag values are " 922 "defined in Chapter 4 of " 923 "<cite>The Java™ Virtual Machine Specification</cite>. " 924 "In addition, The <code>0xf0000000</code> bit identifies " 925 "the field as synthetic, if the synthetic attribute " 926 "<a href=\"#JDWP_VirtualMachine_Capabilities\">capability</a> is available.") 927 ) 928 ) 929 ) 930 (ErrorSet 931 (Error CLASS_NOT_PREPARED) 932 (Error INVALID_CLASS "refType is not the ID of a reference " 933 "type.") 934 (Error INVALID_OBJECT "refType is not a known ID.") 935 (Error VM_DEAD) 936 ) 937 ) 938 (Command MethodsWithGeneric=15 939 "Returns information, including the generic signature if any, " 940 "for each method in a reference type. " 941 "Inherited methodss are not included. The list of methods will " 942 "include constructors (identified with the name \"<init>\"), " 943 "the initialization method (identified with the name \"<clinit>\") " 944 "if present, and any synthetic methods created by the compiler. " 945 "Methods are returned in the order they occur in the class file. " 946 "Generic signatures are described in the signature attribute " 947 "section in " 948 "<cite>The Java™ Virtual Machine Specification</cite>. " 949 "Since JDWP version 1.5." 950 (Out 951 (referenceType refType "The reference type ID.") 952 ) 953 (Reply 954 (Repeat declared "Number of declared methods." 955 (Group MethodInfo 956 (method methodID "Method ID.") 957 (string name "The name of the method.") 958 (string signature "The JNI signature of the method.") 959 (string genericSignature "The generic signature of the method, or " 960 "an empty string if there is none.") 961 (int modBits "The modifier bit flags (also known as access flags) " 962 "which provide additional information on the " 963 "method declaration. Individual flag values are " 964 "defined in Chapter 4 of " 965 "<cite>The Java™ Virtual Machine Specification</cite>. " 966 "In addition, The <code>0xf0000000</code> bit identifies " 967 "the method as synthetic, if the synthetic attribute " 968 "<a href=\"#JDWP_VirtualMachine_Capabilities\">capability</a> is available.") 969 ) 970 ) 971 ) 972 (ErrorSet 973 (Error CLASS_NOT_PREPARED) 974 (Error INVALID_CLASS "refType is not the ID of a reference " 975 "type.") 976 (Error INVALID_OBJECT "refType is not a known ID.") 977 (Error VM_DEAD) 978 ) 979 ) 980 (Command Instances=16 981 "Returns instances of this reference type. " 982 "Only instances that are reachable for the purposes of " 983 "garbage collection are returned. " 984 "<p>Since JDWP version 1.6. Requires canGetInstanceInfo capability - see " 985 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 986 (Out 987 (referenceType refType "The reference type ID.") 988 (int maxInstances "Maximum number of instances to return. Must be non-negative. " 989 "If zero, all instances are returned.") 990 ) 991 (Reply 992 (Repeat instances "The number of instances that follow." 993 (tagged-object instance "An instance of this reference type.") 994 ) 995 ) 996 (ErrorSet 997 (Error INVALID_CLASS "refType is not the ID of a reference " 998 "type.") 999 (Error INVALID_OBJECT "refType is not a known ID.") 1000 (Error ILLEGAL_ARGUMENT "maxInstances is less than zero.") 1001 (Error NOT_IMPLEMENTED) 1002 (Error VM_DEAD) 1003 ) 1004 ) 1005 (Command ClassFileVersion=17 1006 "Returns the class file major and minor version numbers, as defined in the class " 1007 "file format of the Java Virtual Machine specification. " 1008 "<p>Since JDWP version 1.6. " 1009 (Out 1010 (referenceType refType "The class.") 1011 ) 1012 (Reply 1013 (int majorVersion "Major version number") 1014 (int minorVersion "Minor version number") 1015 ) 1016 (ErrorSet 1017 (Error INVALID_CLASS "refType is not the ID of a reference " 1018 "type.") 1019 (Error INVALID_OBJECT "refType is not a known ID.") 1020 (Error ABSENT_INFORMATION "The class file version information is " 1021 "absent for primitive and array types.") 1022 (Error VM_DEAD) 1023 ) 1024 ) 1025 (Command ConstantPool=18 1026 "Return the raw bytes of the constant pool in the format of the " 1027 "constant_pool item of the Class File Format in " 1028 "<cite>The Java™ Virtual Machine Specification</cite>. " 1029 "<p>Since JDWP version 1.6. Requires canGetConstantPool capability - see " 1030 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>."" 1031 (Out 1032 (referenceType refType "The class.") 1033 ) 1034 (Reply 1035 (int count "Total number of constant pool entries plus one. This " 1036 "corresponds to the constant_pool_count item of the " 1037 "Class File Format in " 1038 "<cite>The Java™ Virtual Machine Specification</cite>. ") 1039 (Repeat bytes 1040 (byte cpbytes "Raw bytes of constant pool") 1041 ) 1042 ) 1043 (ErrorSet 1044 (Error INVALID_CLASS "refType is not the ID of a reference " 1045 "type.") 1046 (Error INVALID_OBJECT "refType is not a known ID.") 1047 (Error NOT_IMPLEMENTED "If the target virtual machine does not " 1048 "support the retrieval of constant pool information.") 1049 (Error ABSENT_INFORMATION "The Constant Pool information is " 1050 "absent for primitive and array types.") 1051 (Error VM_DEAD) 1052 ) 1053 ) 1054 (Command Module=19 1055 "Returns the module that this reference type belongs to." 1056 "<p>Since JDWP version 9." 1057 (Out 1058 (referenceType refType "The reference type.") 1059 ) 1060 (Reply 1061 (moduleID module "The module this reference type belongs to.") 1062 ) 1063 (ErrorSet 1064 (Error INVALID_CLASS "refType is not the ID of a reference type.") 1065 (Error INVALID_OBJECT "refType is not a known ID.") 1066 (Error NOT_IMPLEMENTED) 1067 (Error VM_DEAD) 1068 ) 1069 ) 1070 ) 1071 (CommandSet ClassType=3 1072 (Command Superclass=1 1073 "Returns the immediate superclass of a class." 1074 (Out 1075 (classType clazz "The class type ID.") 1076 ) 1077 (Reply 1078 (classType superclass 1079 "The superclass (null if the class ID for java.lang.Object is specified).") 1080 ) 1081 (ErrorSet 1082 (Error INVALID_CLASS "clazz is not the ID of a class.") 1083 (Error INVALID_OBJECT "clazz is not a known ID.") 1084 (Error VM_DEAD) 1085 ) 1086 ) 1087 (Command SetValues=2 1088 "Sets the value of one or more static fields. " 1089 "Each field must be member of the class type " 1090 "or one of its superclasses, superinterfaces, or implemented interfaces. " 1091 "Access control is not enforced; for example, the values of private " 1092 "fields can be set. Final fields cannot be set." 1093 "For primitive values, the value's type must match the " 1094 "field's type exactly. For object values, there must exist a " 1095 "widening reference conversion from the value's type to the 1096 "field's type and the field's type must be loaded. " 1097 (Out 1098 (classType clazz "The class type ID.") 1099 (Repeat values "The number of fields to set." 1100 (Group FieldValue "A Field/Value pair." 1101 (field fieldID "Field to set.") 1102 (untagged-value value "Value to put in the field.") 1103 ) 1104 ) 1105 ) 1106 (Reply "none" 1107 ) 1108 (ErrorSet 1109 (Error INVALID_CLASS "clazz is not the ID of a class.") 1110 (Error CLASS_NOT_PREPARED) 1111 (Error INVALID_OBJECT "clazz is not a known ID or a value of an " 1112 "object field is not a known ID.") 1113 (Error INVALID_FIELDID) 1114 (Error VM_DEAD) 1115 ) 1116 ) 1117 (Command InvokeMethod=3 1118 "Invokes a static method. " 1119 "The method must be member of the class type " 1120 "or one of its superclasses. " 1121 "Access control is not enforced; for example, private " 1122 "methods can be invoked." 1123 "<p>" 1124 "The method invocation will occur in the specified thread. " 1125 "Method invocation can occur only if the specified thread " 1126 "has been suspended by an event. " 1127 "Method invocation is not supported " 1128 "when the target VM has been suspended by the front-end. " 1129 "<p>" 1130 "The specified method is invoked with the arguments in the specified " 1131 "argument list. " 1132 "The method invocation is synchronous; the reply packet is not " 1133 "sent until the invoked method returns in the target VM. " 1134 "The return value (possibly the void value) is " 1135 "included in the reply packet. " 1136 "If the invoked method throws an exception, the " 1137 "exception object ID is set in the reply packet; otherwise, the " 1138 "exception object ID is null. " 1139 "<p>" 1140 "For primitive arguments, the argument value's type must match the " 1141 "argument's type exactly. For object arguments, there must exist a " 1142 "widening reference conversion from the argument value's type to the " 1143 "argument's type and the argument's type must be loaded. " 1144 "<p>" 1145 "By default, all threads in the target VM are resumed while " 1146 "the method is being invoked if they were previously " 1147 "suspended by an event or by command. " 1148 "This is done to prevent the deadlocks " 1149 "that will occur if any of the threads own monitors " 1150 "that will be needed by the invoked method. It is possible that " 1151 "breakpoints or other events might occur during the invocation. " 1152 "Note, however, that this implicit resume acts exactly like " 1153 "the ThreadReference resume command, so if the thread's suspend " 1154 "count is greater than 1, it will remain in a suspended state " 1155 "during the invocation. By default, when the invocation completes, " 1156 "all threads in the target VM are suspended, regardless their state " 1157 "before the invocation. " 1158 "<p>" 1159 "The resumption of other threads during the invoke can be prevented " 1160 "by specifying the INVOKE_SINGLE_THREADED " 1161 "bit flag in the <code>options</code> field; however, " 1162 "there is no protection against or recovery from the deadlocks " 1163 "described above, so this option should be used with great caution. " 1164 "Only the specified thread will be resumed (as described for all " 1165 "threads above). Upon completion of a single threaded invoke, the invoking thread " 1166 "will be suspended once again. Note that any threads started during " 1167 "the single threaded invocation will not be suspended when the " 1168 "invocation completes. " 1169 "<p>" 1170 "If the target VM is disconnected during the invoke (for example, through " 1171 "the VirtualMachine dispose command) the method invocation continues. " 1172 (Out 1173 (classType clazz "The class type ID.") 1174 (threadObject thread "The thread in which to invoke.") 1175 (method methodID "The method to invoke.") 1176 (Repeat arguments 1177 (value arg "The argument value.") 1178 ) 1179 (int options "Invocation <a href=\"#JDWP_InvokeOptions\">options</a>") 1180 ) 1181 (Reply 1182 (value returnValue "The returned value.") 1183 (tagged-object exception "The thrown exception.") 1184 ) 1185 (ErrorSet 1186 (Error INVALID_CLASS "clazz is not the ID of a class.") 1187 (Error INVALID_OBJECT "clazz is not a known ID.") 1188 (Error INVALID_METHODID "methodID is not the ID of a static method in " 1189 "this class type or one of its superclasses.") 1190 (Error INVALID_THREAD) 1191 (Error THREAD_NOT_SUSPENDED) 1192 (Error VM_DEAD) 1193 ) 1194 ) 1195 (Command NewInstance=4 1196 "Creates a new object of this type, invoking the specified " 1197 "constructor. The constructor method ID must be a member of " 1198 "the class type." 1199 "<p>" 1200 "Instance creation will occur in the specified thread. " 1201 "Instance creation can occur only if the specified thread " 1202 "has been suspended by an event. " 1203 "Method invocation is not supported " 1204 "when the target VM has been suspended by the front-end. " 1205 "<p>" 1206 "The specified constructor is invoked with the arguments in the specified " 1207 "argument list. " 1208 "The constructor invocation is synchronous; the reply packet is not " 1209 "sent until the invoked method returns in the target VM. " 1210 "The return value (possibly the void value) is " 1211 "included in the reply packet. " 1212 "If the constructor throws an exception, the " 1213 "exception object ID is set in the reply packet; otherwise, the " 1214 "exception object ID is null. " 1215 "<p>" 1216 "For primitive arguments, the argument value's type must match the " 1217 "argument's type exactly. For object arguments, there must exist a " 1218 "widening reference conversion from the argument value's type to the " 1219 "argument's type and the argument's type must be loaded. " 1220 "<p>" 1221 "By default, all threads in the target VM are resumed while " 1222 "the method is being invoked if they were previously " 1223 "suspended by an event or by command. " 1224 "This is done to prevent the deadlocks " 1225 "that will occur if any of the threads own monitors " 1226 "that will be needed by the invoked method. It is possible that " 1227 "breakpoints or other events might occur during the invocation. " 1228 "Note, however, that this implicit resume acts exactly like " 1229 "the ThreadReference resume command, so if the thread's suspend " 1230 "count is greater than 1, it will remain in a suspended state " 1231 "during the invocation. By default, when the invocation completes, " 1232 "all threads in the target VM are suspended, regardless their state " 1233 "before the invocation. " 1234 "<p>" 1235 "The resumption of other threads during the invoke can be prevented " 1236 "by specifying the INVOKE_SINGLE_THREADED " 1237 "bit flag in the <code>options</code> field; however, " 1238 "there is no protection against or recovery from the deadlocks " 1239 "described above, so this option should be used with great caution. " 1240 "Only the specified thread will be resumed (as described for all " 1241 "threads above). Upon completion of a single threaded invoke, the invoking thread " 1242 "will be suspended once again. Note that any threads started during " 1243 "the single threaded invocation will not be suspended when the " 1244 "invocation completes. " 1245 "<p>" 1246 "If the target VM is disconnected during the invoke (for example, through " 1247 "the VirtualMachine dispose command) the method invocation continues. " 1248 (Out 1249 (classType clazz "The class type ID.") 1250 (threadObject thread "The thread in which to invoke the constructor.") 1251 (method methodID "The constructor to invoke.") 1252 (Repeat arguments 1253 (value arg "The argument value.") 1254 ) 1255 (int options "Constructor invocation <a href=\"#JDWP_InvokeOptions\">options</a>") 1256 ) 1257 (Reply 1258 (tagged-object newObject "The newly created object, or null " 1259 "if the constructor threw an exception.") 1260 (tagged-object exception "The thrown exception, if any; otherwise, null.") 1261 ) 1262 (ErrorSet 1263 (Error INVALID_CLASS "clazz is not the ID of a class.") 1264 (Error INVALID_OBJECT "clazz is not a known ID or a value of an " 1265 "object parameter is not a known ID..") 1266 (Error INVALID_METHODID "methodID is not the ID of a method.") 1267 (Error INVALID_OBJECT) 1268 (Error INVALID_THREAD) 1269 (Error THREAD_NOT_SUSPENDED) 1270 (Error VM_DEAD) 1271 ) 1272 ) 1273 ) 1274 (CommandSet ArrayType=4 1275 (Command NewInstance=1 1276 "Creates a new array object of this type with a given length." 1277 (Out 1278 (arrayType arrType "The array type of the new instance.") 1279 (int length "The length of the array.") 1280 ) 1281 (Reply 1282 (tagged-object newArray "The newly created array object. ") 1283 ) 1284 (ErrorSet 1285 (Error INVALID_ARRAY) 1286 (Error INVALID_OBJECT) 1287 (Error VM_DEAD) 1288 ) 1289 ) 1290 ) 1291 (CommandSet InterfaceType=5 1292 (Command InvokeMethod=1 1293 "Invokes a static method. " 1294 "The method must not be a static initializer. " 1295 "The method must be a member of the interface type. " 1296 "<p>Since JDWP version 1.8 " 1297 "<p>" 1298 "The method invocation will occur in the specified thread. " 1299 "Method invocation can occur only if the specified thread " 1300 "has been suspended by an event. " 1301 "Method invocation is not supported " 1302 "when the target VM has been suspended by the front-end. " 1303 "<p>" 1304 "The specified method is invoked with the arguments in the specified " 1305 "argument list. " 1306 "The method invocation is synchronous; the reply packet is not " 1307 "sent until the invoked method returns in the target VM. " 1308 "The return value (possibly the void value) is " 1309 "included in the reply packet. " 1310 "If the invoked method throws an exception, the " 1311 "exception object ID is set in the reply packet; otherwise, the " 1312 "exception object ID is null. " 1313 "<p>" 1314 "For primitive arguments, the argument value's type must match the " 1315 "argument's type exactly. For object arguments, there must exist a " 1316 "widening reference conversion from the argument value's type to the " 1317 "argument's type and the argument's type must be loaded. " 1318 "<p>" 1319 "By default, all threads in the target VM are resumed while " 1320 "the method is being invoked if they were previously " 1321 "suspended by an event or by a command. " 1322 "This is done to prevent the deadlocks " 1323 "that will occur if any of the threads own monitors " 1324 "that will be needed by the invoked method. It is possible that " 1325 "breakpoints or other events might occur during the invocation. " 1326 "Note, however, that this implicit resume acts exactly like " 1327 "the ThreadReference resume command, so if the thread's suspend " 1328 "count is greater than 1, it will remain in a suspended state " 1329 "during the invocation. By default, when the invocation completes, " 1330 "all threads in the target VM are suspended, regardless their state " 1331 "before the invocation. " 1332 "<p>" 1333 "The resumption of other threads during the invoke can be prevented " 1334 "by specifying the INVOKE_SINGLE_THREADED " 1335 "bit flag in the <code>options</code> field; however, " 1336 "there is no protection against or recovery from the deadlocks " 1337 "described above, so this option should be used with great caution. " 1338 "Only the specified thread will be resumed (as described for all " 1339 "threads above). Upon completion of a single threaded invoke, the invoking thread " 1340 "will be suspended once again. Note that any threads started during " 1341 "the single threaded invocation will not be suspended when the " 1342 "invocation completes. " 1343 "<p>" 1344 "If the target VM is disconnected during the invoke (for example, through " 1345 "the VirtualMachine dispose command) the method invocation continues. " 1346 (Out 1347 (interfaceType clazz "The interface type ID.") 1348 (threadObject thread "The thread in which to invoke.") 1349 (method methodID "The method to invoke.") 1350 (Repeat arguments 1351 (value arg "The argument value.") 1352 ) 1353 (int options "Invocation <a href=\"#JDWP_InvokeOptions\">options</a>") 1354 ) 1355 (Reply 1356 (value returnValue "The returned value.") 1357 (tagged-object exception "The thrown exception.") 1358 ) 1359 (ErrorSet 1360 (Error INVALID_CLASS "clazz is not the ID of an interface.") 1361 (Error INVALID_OBJECT "clazz is not a known ID.") 1362 (Error INVALID_METHODID "methodID is not the ID of a static method in this " 1363 "interface type or is the ID of a static initializer.") 1364 (Error INVALID_THREAD) 1365 (Error THREAD_NOT_SUSPENDED) 1366 (Error VM_DEAD) 1367 ) 1368 ) 1369 ) 1370 (CommandSet Method=6 1371 (Command LineTable=1 1372 "Returns line number information for the method, if present. " 1373 "The line table maps source line numbers to the initial code index " 1374 "of the line. The line table " 1375 "is ordered by code index (from lowest to highest). The line number " 1376 "information is constant unless a new class definition is installed " 1377 "using <a href=\"#JDWP_VirtualMachine_RedefineClasses\">RedefineClasses</a>." 1378 (Out 1379 (referenceType refType "The class.") 1380 (method methodID "The method.") 1381 ) 1382 (Reply 1383 (long start "Lowest valid code index for the method, >=0, or -1 if the method is native ") 1384 (long end "Highest valid code index for the method, >=0, or -1 if the method is native") 1385 (Repeat lines "The number of entries in the line table for this method." 1386 (Group LineInfo 1387 (long lineCodeIndex "Initial code index of the line, " 1388 "start <= lineCodeIndex < end") 1389 (int lineNumber "Line number.") 1390 ) 1391 ) 1392 ) 1393 (ErrorSet 1394 (Error INVALID_CLASS "refType is not the ID of a reference " 1395 "type.") 1396 (Error INVALID_OBJECT "refType is not a known ID.") 1397 (Error INVALID_METHODID "methodID is not the ID of a method.") 1398 (Error VM_DEAD) 1399 ) 1400 ) 1401 (Command VariableTable=2 1402 "Returns variable information for the method. The variable table " 1403 "includes arguments and locals declared within the method. For " 1404 "instance methods, the \"this\" reference is included in the " 1405 "table. Also, synthetic variables may be present. " 1406 (Out 1407 (referenceType refType "The class.") 1408 (method methodID "The method.") 1409 ) 1410 (Reply 1411 (int argCnt "The number of words in the frame used by arguments. " 1412 "Eight-byte arguments use two words; all others use one. ") 1413 (Repeat slots "The number of variables." 1414 (Group SlotInfo "Information about the variable." 1415 (long codeIndex 1416 "First code index at which the variable is visible (unsigned). " 1417 "Used in conjunction with <code>length</code>. " 1418 "The variable can be get or set only when the current " 1419 "<code>codeIndex</code> <= current frame code index < <code>codeIndex + length</code> ") 1420 (string name "The variable's name.") 1421 (string signature "The variable type's JNI signature.") 1422 (int length 1423 "Unsigned value used in conjunction with <code>codeIndex</code>. " 1424 "The variable can be get or set only when the current " 1425 "<code>codeIndex</code> <= current frame code index < <code>code index + length</code> ") 1426 (int slot "The local variable's index in its frame") 1427 ) 1428 ) 1429 ) 1430 (ErrorSet 1431 (Error INVALID_CLASS "refType is not the ID of a reference " 1432 "type.") 1433 (Error INVALID_OBJECT "refType is not a known ID.") 1434 (Error INVALID_METHODID "methodID is not the ID of a method.") 1435 (Error ABSENT_INFORMATION "there is no variable information for the method.") 1436 (Error VM_DEAD) 1437 ) 1438 ) 1439 (Command Bytecodes=3 1440 "Retrieve the method's bytecodes as defined in " 1441 "<cite>The Java™ Virtual Machine Specification</cite>. " 1442 "Requires canGetBytecodes capability - see " 1443 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 1444 (Out 1445 (referenceType refType "The class.") 1446 (method methodID "The method.") 1447 ) 1448 (Reply 1449 (Repeat bytes 1450 (byte bytecode "A Java bytecode.") 1451 ) 1452 ) 1453 (ErrorSet 1454 (Error INVALID_CLASS "refType is not the ID of a reference " 1455 "type.") 1456 (Error INVALID_OBJECT "refType is not a known ID.") 1457 (Error INVALID_METHODID "methodID is not the ID of a method.") 1458 (Error NOT_IMPLEMENTED "If the target virtual machine does not " 1459 "support the retrieval of bytecodes.") 1460 (Error VM_DEAD) 1461 ) 1462 ) 1463 (Command IsObsolete=4 1464 "Determine if this method is obsolete. A method is obsolete if it has been replaced " 1465 "by a non-equivalent method using the " 1466 "<a href=\"#JDWP_VirtualMachine_RedefineClasses\">RedefineClasses</a> command. " 1467 "The original and redefined methods are considered equivalent if their bytecodes are " 1468 "the same except for indices into the constant pool and the referenced constants are " 1469 "equal." 1470 (Out 1471 (referenceType refType "The class.") 1472 (method methodID "The method.") 1473 ) 1474 (Reply 1475 (boolean isObsolete "true if this method has been replaced" 1476 "by a non-equivalent method using" 1477 "the RedefineClasses command.") 1478 ) 1479 (ErrorSet 1480 (Error INVALID_CLASS "refType is not the ID of a reference " 1481 "type.") 1482 (Error INVALID_OBJECT "refType is not a known ID.") 1483 (Error INVALID_METHODID "methodID is not the ID of a method.") 1484 (Error NOT_IMPLEMENTED "If the target virtual machine does " 1485 "not support this query.") 1486 (Error VM_DEAD) 1487 ) 1488 ) 1489 (Command VariableTableWithGeneric=5 1490 "Returns variable information for the method, including " 1491 "generic signatures for the variables. The variable table " 1492 "includes arguments and locals declared within the method. For " 1493 "instance methods, the \"this\" reference is included in the " 1494 "table. Also, synthetic variables may be present. " 1495 "Generic signatures are described in the signature attribute " 1496 "section in " 1497 "<cite>The Java™ Virtual Machine Specification</cite>. " 1498 "Since JDWP version 1.5." 1499 (Out 1500 (referenceType refType "The class.") 1501 (method methodID "The method.") 1502 ) 1503 (Reply 1504 (int argCnt "The number of words in the frame used by arguments. " 1505 "Eight-byte arguments use two words; all others use one. ") 1506 (Repeat slots "The number of variables." 1507 (Group SlotInfo "Information about the variable." 1508 (long codeIndex 1509 "First code index at which the variable is visible (unsigned). " 1510 "Used in conjunction with <code>length</code>. " 1511 "The variable can be get or set only when the current " 1512 "<code>codeIndex</code> <= current frame code index < <code>codeIndex + length</code> ") 1513 (string name "The variable's name.") 1514 (string signature "The variable type's JNI signature.") 1515 (string genericSignature "The variable type's generic " 1516 "signature or an empty string if there is none.") 1517 (int length 1518 "Unsigned value used in conjunction with <code>codeIndex</code>. " 1519 "The variable can be get or set only when the current " 1520 "<code>codeIndex</code> <= current frame code index < <code>code index + length</code> ") 1521 (int slot "The local variable's index in its frame") 1522 ) 1523 ) 1524 ) 1525 (ErrorSet 1526 (Error INVALID_CLASS "refType is not the ID of a reference " 1527 "type.") 1528 (Error INVALID_OBJECT "refType is not a known ID.") 1529 (Error INVALID_METHODID "methodID is not the ID of a method.") 1530 (Error ABSENT_INFORMATION "there is no variable information for the method.") 1531 (Error VM_DEAD) 1532 ) 1533 ) 1534 1535 ) 1536 (CommandSet Field=8 1537 ) 1538 (CommandSet ObjectReference=9 1539 (Command ReferenceType=1 1540 "Returns the runtime type of the object. " 1541 "The runtime type will be a class or an array. " 1542 (Out 1543 (object object "The object ID") 1544 ) 1545 (Reply 1546 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 1547 "of following reference type. ") 1548 (referenceTypeID typeID "The runtime reference type.") 1549 ) 1550 (ErrorSet 1551 (Error INVALID_OBJECT) 1552 (Error VM_DEAD) 1553 ) 1554 ) 1555 (Command GetValues=2 1556 "Returns the value of one or more instance fields. " 1557 "Each field must be member of the object's type " 1558 "or one of its superclasses, superinterfaces, or implemented interfaces. " 1559 "Access control is not enforced; for example, the values of private " 1560 "fields can be obtained." 1561 (Out 1562 (object object "The object ID") 1563 (Repeat fields "The number of values to get" 1564 (Group Field 1565 (field fieldID "Field to get.") 1566 ) 1567 ) 1568 ) 1569 (Reply 1570 (Repeat values "The number of values returned, always equal to 'fields', " 1571 "the number of values to get. Field values are ordered " 1572 "in the reply in the same order as corresponding fieldIDs " 1573 "in the command." 1574 (value value "The field value") 1575 ) 1576 ) 1577 (ErrorSet 1578 (Error INVALID_OBJECT) 1579 (Error INVALID_FIELDID) 1580 (Error VM_DEAD) 1581 ) 1582 ) 1583 (Command SetValues=3 1584 "Sets the value of one or more instance fields. " 1585 "Each field must be member of the object's type " 1586 "or one of its superclasses, superinterfaces, or implemented interfaces. " 1587 "Access control is not enforced; for example, the values of private " 1588 "fields can be set. " 1589 "For primitive values, the value's type must match the " 1590 "field's type exactly. For object values, there must be a " 1591 "widening reference conversion from the value's type to the 1592 "field's type and the field's type must be loaded. " 1593 (Out 1594 (object object "The object ID") 1595 (Repeat values "The number of fields to set." 1596 (Group FieldValue "A Field/Value pair." 1597 (field fieldID "Field to set.") 1598 (untagged-value value "Value to put in the field.") 1599 ) 1600 ) 1601 ) 1602 (Reply "none" 1603 ) 1604 (ErrorSet 1605 (Error INVALID_OBJECT) 1606 (Error INVALID_FIELDID) 1607 (Error VM_DEAD) 1608 ) 1609 ) 1610 (Command MonitorInfo=5 1611 "Returns monitor information for an object. All threads int the VM must " 1612 "be suspended." 1613 "Requires canGetMonitorInfo capability - see " 1614 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 1615 (Out 1616 (object object "The object ID") 1617 ) 1618 (Reply 1619 (threadObject owner "The monitor owner, or null if it is not currently owned.") 1620 (int entryCount "The number of times the monitor has been entered.") 1621 (Repeat waiters "The number of threads that are waiting for the monitor " 1622 "0 if there is no current owner" 1623 (threadObject thread "A thread waiting for this monitor.") 1624 ) 1625 ) 1626 (ErrorSet 1627 (Error INVALID_OBJECT) 1628 (Error NOT_IMPLEMENTED) 1629 (Error VM_DEAD) 1630 ) 1631 ) 1632 (Command InvokeMethod=6 1633 "Invokes a instance method. " 1634 "The method must be member of the object's type " 1635 "or one of its superclasses, superinterfaces, or implemented interfaces. " 1636 "Access control is not enforced; for example, private " 1637 "methods can be invoked." 1638 "<p>" 1639 "The method invocation will occur in the specified thread. " 1640 "Method invocation can occur only if the specified thread " 1641 "has been suspended by an event. " 1642 "Method invocation is not supported " 1643 "when the target VM has been suspended by the front-end. " 1644 "<p>" 1645 "The specified method is invoked with the arguments in the specified " 1646 "argument list. " 1647 "The method invocation is synchronous; the reply packet is not " 1648 "sent until the invoked method returns in the target VM. " 1649 "The return value (possibly the void value) is " 1650 "included in the reply packet. " 1651 "If the invoked method throws an exception, the " 1652 "exception object ID is set in the reply packet; otherwise, the " 1653 "exception object ID is null. " 1654 "<p>" 1655 "For primitive arguments, the argument value's type must match the " 1656 "argument's type exactly. For object arguments, there must be a " 1657 "widening reference conversion from the argument value's type to the " 1658 "argument's type and the argument's type must be loaded. " 1659 "<p>" 1660 "By default, all threads in the target VM are resumed while " 1661 "the method is being invoked if they were previously " 1662 "suspended by an event or by a command. " 1663 "This is done to prevent the deadlocks " 1664 "that will occur if any of the threads own monitors " 1665 "that will be needed by the invoked method. It is possible that " 1666 "breakpoints or other events might occur during the invocation. " 1667 "Note, however, that this implicit resume acts exactly like " 1668 "the ThreadReference resume command, so if the thread's suspend " 1669 "count is greater than 1, it will remain in a suspended state " 1670 "during the invocation. By default, when the invocation completes, " 1671 "all threads in the target VM are suspended, regardless their state " 1672 "before the invocation. " 1673 "<p>" 1674 "The resumption of other threads during the invoke can be prevented " 1675 "by specifying the INVOKE_SINGLE_THREADED " 1676 "bit flag in the <code>options</code> field; however, " 1677 "there is no protection against or recovery from the deadlocks " 1678 "described above, so this option should be used with great caution. " 1679 "Only the specified thread will be resumed (as described for all " 1680 "threads above). Upon completion of a single threaded invoke, the invoking thread " 1681 "will be suspended once again. Note that any threads started during " 1682 "the single threaded invocation will not be suspended when the " 1683 "invocation completes. " 1684 "<p>" 1685 "If the target VM is disconnected during the invoke (for example, through " 1686 "the VirtualMachine dispose command) the method invocation continues. " 1687 (Out 1688 (object object "The object ID") 1689 (threadObject thread "The thread in which to invoke.") 1690 (classType clazz "The class type.") 1691 (method methodID "The method to invoke.") 1692 (Repeat arguments "The number of arguments." 1693 (value arg "The argument value.") 1694 ) 1695 (int options "Invocation <a href=\"#JDWP_InvokeOptions\">options</a>") 1696 ) 1697 (Reply 1698 (value returnValue "The returned value, or null if an exception is thrown.") 1699 (tagged-object exception "The thrown exception, if any.") 1700 ) 1701 (ErrorSet 1702 (Error INVALID_OBJECT) 1703 (Error INVALID_CLASS "clazz is not the ID of a reference " 1704 "type.") 1705 (Error INVALID_METHODID "methodID is not the ID of an instance method " 1706 "in this object's type or one of its superclasses, " 1707 "superinterfaces, or implemented interfaces.") 1708 (Error INVALID_THREAD) 1709 (Error THREAD_NOT_SUSPENDED) 1710 (Error VM_DEAD) 1711 ) 1712 ) 1713 (Command DisableCollection=7 1714 "Prevents garbage collection for the given object. By " 1715 "default all objects in back-end replies may be " 1716 "collected at any time the target VM is running. A call to " 1717 "this command guarantees that the object will not be " 1718 "collected. The " 1719 "<a href=\"#JDWP_ObjectReference_EnableCollection\">EnableCollection</a> " 1720 "command can be used to " 1721 "allow collection once again. " 1722 "<p>" 1723 "Note that while the target VM is suspended, no garbage " 1724 "collection will occur because all threads are suspended. " 1725 "The typical examination of variables, fields, and arrays " 1726 "during the suspension is safe without explicitly disabling " 1727 "garbage collection. " 1728 "<p>" 1729 "This method should be used sparingly, as it alters the " 1730 "pattern of garbage collection in the target VM and, " 1731 "consequently, may result in application behavior under the " 1732 "debugger that differs from its non-debugged behavior. " 1733 (Out 1734 (object object "The object ID") 1735 ) 1736 (Reply "none" 1737 ) 1738 (ErrorSet 1739 (Error INVALID_OBJECT) 1740 (Error VM_DEAD) 1741 ) 1742 ) 1743 (Command EnableCollection=8 1744 "Permits garbage collection for this object. By default all " 1745 "objects returned by JDWP may become unreachable in the target VM, " 1746 "and hence may be garbage collected. A call to this command is " 1747 "necessary only if garbage collection was previously disabled with " 1748 "the <a href=\"#JDWP_ObjectReference_DisableCollection\">DisableCollection</a> " 1749 "command." 1750 (Out 1751 (object object "The object ID") 1752 ) 1753 (Reply "none" 1754 ) 1755 (ErrorSet 1756 (Error VM_DEAD) 1757 ) 1758 ) 1759 (Command IsCollected=9 1760 "Determines whether an object has been garbage collected in the " 1761 "target VM. " 1762 (Out 1763 (object object "The object ID") 1764 ) 1765 (Reply 1766 (boolean isCollected "true if the object has been collected; false otherwise") 1767 ) 1768 (ErrorSet 1769 (Error INVALID_OBJECT) 1770 (Error VM_DEAD) 1771 ) 1772 ) 1773 (Command ReferringObjects=10 1774 "Returns objects that directly reference this object. " 1775 "Only objects that are reachable for the purposes " 1776 "of garbage collection are returned. " 1777 "Note that an object can also be referenced in other ways, " 1778 "such as from a local variable in a stack frame, or from a JNI global " 1779 "reference. Such non-object referrers are not returned by this command. " 1780 "<p>Since JDWP version 1.6. Requires canGetInstanceInfo capability - see " 1781 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 1782 (Out 1783 (object object "The object ID") 1784 (int maxReferrers "Maximum number of referring objects to return. " 1785 "Must be non-negative. If zero, all referring " 1786 "objects are returned.") 1787 ) 1788 (Reply 1789 (Repeat referringObjects "The number of objects that follow." 1790 (tagged-object instance "An object that references this object.") 1791 ) 1792 ) 1793 (ErrorSet 1794 (Error INVALID_OBJECT "object is not a known ID.") 1795 (Error ILLEGAL_ARGUMENT "maxReferrers is less than zero.") 1796 (Error NOT_IMPLEMENTED) 1797 (Error VM_DEAD) 1798 ) 1799 ) 1800 ) 1801 1802 (CommandSet StringReference=10 1803 (Command Value=1 1804 "Returns the characters contained in the string. " 1805 (Out 1806 (object stringObject "The String object ID. ") 1807 ) 1808 (Reply 1809 (string stringValue "UTF-8 representation of the string value.") 1810 ) 1811 (ErrorSet 1812 (Error INVALID_STRING) 1813 (Error INVALID_OBJECT) 1814 (Error VM_DEAD) 1815 ) 1816 ) 1817 ) 1818 (CommandSet ThreadReference=11 1819 (Command Name=1 1820 "Returns the thread name. " 1821 (Out 1822 (threadObject thread "The thread object ID. ") 1823 ) 1824 (Reply 1825 (string threadName "The thread name.") 1826 ) 1827 (ErrorSet 1828 (Error INVALID_THREAD) 1829 (Error INVALID_OBJECT "thread is not a known ID.") 1830 (Error VM_DEAD) 1831 ) 1832 ) 1833 (Command Suspend=2 1834 "Suspends the thread. " 1835 "<p>" 1836 "Unlike java.lang.Thread.suspend(), suspends of both " 1837 "the virtual machine and individual threads are counted. Before " 1838 "a thread will run again, it must be resumed the same number " 1839 "of times it has been suspended. " 1840 "<p>" 1841 "Suspending single threads with command has the same " 1842 "dangers java.lang.Thread.suspend(). If the suspended " 1843 "thread holds a monitor needed by another running thread, " 1844 "deadlock is possible in the target VM (at least until the " 1845 "suspended thread is resumed again). " 1846 "<p>" 1847 "The suspended thread is guaranteed to remain suspended until " 1848 "resumed through one of the JDI resume methods mentioned above; " 1849 "the application in the target VM cannot resume the suspended thread " 1850 "through {@link java.lang.Thread#resume}. " 1851 "<p>" 1852 "Note that this doesn't change the status of the thread (see the " 1853 "<a href=\"#JDWP_ThreadReference_Status\">ThreadStatus</a> command.) " 1854 "For example, if it was " 1855 "Running, it will still appear running to other threads. " 1856 (Out 1857 (threadObject thread "The thread object ID. ") 1858 ) 1859 (Reply "none" 1860 ) 1861 (ErrorSet 1862 (Error INVALID_THREAD) 1863 (Error INVALID_OBJECT "thread is not a known ID.") 1864 (Error VM_DEAD) 1865 ) 1866 ) 1867 (Command Resume=3 1868 "Resumes the execution of a given thread. If this thread was " 1869 "not previously suspended by the front-end, " 1870 "calling this command has no effect. " 1871 "Otherwise, the count of pending suspends on this thread is " 1872 "decremented. If it is decremented to 0, the thread will " 1873 "continue to execute. " 1874 (Out 1875 (threadObject thread "The thread object ID. ") 1876 ) 1877 (Reply "none" 1878 ) 1879 (ErrorSet 1880 (Error INVALID_THREAD) 1881 (Error INVALID_OBJECT "thread is not a known ID.") 1882 (Error VM_DEAD) 1883 ) 1884 ) 1885 (Command Status=4 1886 "Returns the current status of a thread. The thread status " 1887 "reply indicates the thread status the last time it was running. " 1888 "the suspend status provides information on the thread's " 1889 "suspension, if any." 1890 (Out 1891 (threadObject thread "The thread object ID. ") 1892 ) 1893 (Reply 1894 (int threadStatus "One of the thread status codes " 1895 "See <a href=\"#JDWP_ThreadStatus\">JDWP.ThreadStatus</a>") 1896 (int suspendStatus "One of the suspend status codes " 1897 "See <a href=\"#JDWP_SuspendStatus\">JDWP.SuspendStatus</a>") 1898 ) 1899 (ErrorSet 1900 (Error INVALID_THREAD) 1901 (Error INVALID_OBJECT "thread is not a known ID.") 1902 (Error VM_DEAD) 1903 ) 1904 ) 1905 (Command ThreadGroup=5 1906 "Returns the thread group that contains a given thread. " 1907 (Out 1908 (threadObject thread "The thread object ID. ") 1909 ) 1910 (Reply 1911 (threadGroupObject group "The thread group of this thread. ") 1912 ) 1913 (ErrorSet 1914 (Error INVALID_THREAD) 1915 (Error INVALID_OBJECT "thread is not a known ID.") 1916 (Error VM_DEAD) 1917 ) 1918 ) 1919 (Command Frames=6 1920 "Returns the current call stack of a suspended thread. " 1921 "The sequence of frames starts with " 1922 "the currently executing frame, followed by its caller, " 1923 "and so on. The thread must be suspended, and the returned " 1924 "frameID is valid only while the thread is suspended. " 1925 (Out 1926 (threadObject thread "The thread object ID. ") 1927 (int startFrame "The index of the first frame to retrieve.") 1928 (int length 1929 "The count of frames to retrieve " 1930 "(-1 means all remaining). ") 1931 ) 1932 (Reply 1933 (Repeat frames "The number of frames retreived" 1934 (Group Frame 1935 (frame frameID "The ID of this frame. ") 1936 (location location "The current location of this frame") 1937 ) 1938 ) 1939 ) 1940 (ErrorSet 1941 (Error INVALID_THREAD) 1942 (Error INVALID_OBJECT "thread is not a known ID.") 1943 (Error VM_DEAD) 1944 ) 1945 ) 1946 (Command FrameCount=7 1947 "Returns the count of frames on this thread's stack. " 1948 "The thread must be suspended, and the returned " 1949 "count is valid only while the thread is suspended. " 1950 "Returns JDWP.Error.errorThreadNotSuspended if not suspended. " 1951 (Out 1952 (threadObject thread "The thread object ID. ") 1953 ) 1954 (Reply 1955 (int frameCount "The count of frames on this thread's stack. ") 1956 ) 1957 (ErrorSet 1958 (Error INVALID_THREAD) 1959 (Error INVALID_OBJECT "thread is not a known ID.") 1960 (Error VM_DEAD) 1961 ) 1962 ) 1963 (Command OwnedMonitors=8 1964 "Returns the objects whose monitors have been entered by this thread. " 1965 "The thread must be suspended, and the returned information is " 1966 "relevant only while the thread is suspended. " 1967 "Requires canGetOwnedMonitorInfo capability - see " 1968 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 1969 (Out 1970 (threadObject thread "The thread object ID. ") 1971 ) 1972 (Reply 1973 (Repeat owned "The number of owned monitors" 1974 (tagged-object monitor "An owned monitor") 1975 ) 1976 ) 1977 (ErrorSet 1978 (Error INVALID_THREAD) 1979 (Error INVALID_OBJECT "thread is not a known ID.") 1980 (Error NOT_IMPLEMENTED) 1981 (Error VM_DEAD) 1982 ) 1983 ) 1984 (Command CurrentContendedMonitor=9 1985 "Returns the object, if any, for which this thread is waiting. The " 1986 "thread may be waiting to enter a monitor, or it may be waiting, via " 1987 "the java.lang.Object.wait method, for another thread to invoke the " 1988 "notify method. " 1989 "The thread must be suspended, and the returned information is " 1990 "relevant only while the thread is suspended. " 1991 "Requires canGetCurrentContendedMonitor capability - see " 1992 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 1993 (Out 1994 (threadObject thread "The thread object ID. ") 1995 ) 1996 (Reply 1997 (tagged-object monitor "The contended monitor, or null if " 1998 "there is no current contended monitor. ") 1999 ) 2000 (ErrorSet 2001 (Error INVALID_THREAD) 2002 (Error INVALID_OBJECT "thread is not a known ID.") 2003 (Error NOT_IMPLEMENTED) 2004 (Error VM_DEAD) 2005 ) 2006 ) 2007 (Command Stop=10 2008 "Stops the thread with an asynchronous exception. " 2009 (Out 2010 (threadObject thread "The thread object ID. ") 2011 (object throwable "Asynchronous exception. This object must " 2012 "be an instance of java.lang.Throwable or a subclass") 2013 ) 2014 (Reply "none" 2015 ) 2016 (ErrorSet 2017 (Error INVALID_THREAD) 2018 (Error INVALID_OBJECT "If thread is not a known ID or the asynchronous " 2019 "exception has been garbage collected.") 2020 (Error VM_DEAD) 2021 ) 2022 ) 2023 (Command Interrupt=11 2024 "Interrupt the thread, as if done by java.lang.Thread.interrupt " 2025 (Out 2026 (threadObject thread "The thread object ID. ") 2027 ) 2028 (Reply "none" 2029 ) 2030 (ErrorSet 2031 (Error INVALID_THREAD) 2032 (Error INVALID_OBJECT "thread is not a known ID.") 2033 (Error VM_DEAD) 2034 ) 2035 ) 2036 (Command SuspendCount=12 2037 "Get the suspend count for this thread. The suspend count is the " 2038 "number of times the thread has been suspended through the " 2039 "thread-level or VM-level suspend commands without a corresponding resume " 2040 (Out 2041 (threadObject thread "The thread object ID. ") 2042 ) 2043 (Reply 2044 (int suspendCount "The number of outstanding suspends of this thread. ") 2045 ) 2046 (ErrorSet 2047 (Error INVALID_THREAD) 2048 (Error INVALID_OBJECT "thread is not a known ID.") 2049 (Error VM_DEAD) 2050 ) 2051 ) 2052 (Command OwnedMonitorsStackDepthInfo=13 2053 "Returns monitor objects owned by the thread, along with stack depth at which " 2054 "the monitor was acquired. Returns stack depth of -1 if " 2055 "the implementation cannot determine the stack depth " 2056 "(e.g., for monitors acquired by JNI MonitorEnter)." 2057 "The thread must be suspended, and the returned information is " 2058 "relevant only while the thread is suspended. " 2059 "Requires canGetMonitorFrameInfo capability - see " 2060 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 2061 "<p>Since JDWP version 1.6. " 2062 2063 (Out 2064 (threadObject thread "The thread object ID. ") 2065 ) 2066 (Reply 2067 (Repeat owned "The number of owned monitors" 2068 (Group monitor 2069 (tagged-object monitor "An owned monitor") 2070 (int stack_depth "Stack depth location where monitor was acquired") 2071 ) 2072 ) 2073 ) 2074 (ErrorSet 2075 (Error INVALID_THREAD) 2076 (Error INVALID_OBJECT "thread is not a known ID.") 2077 (Error NOT_IMPLEMENTED) 2078 (Error VM_DEAD) 2079 ) 2080 ) 2081 (Command ForceEarlyReturn=14 2082 "Force a method to return before it reaches a return " 2083 "statement. " 2084 "<p>" 2085 "The method which will return early is referred to as the " 2086 "called method. The called method is the current method (as " 2087 "defined by the Frames section in " 2088 "<cite>The Java™ Virtual Machine Specification</cite>) " 2089 "for the specified thread at the time this command " 2090 "is received. " 2091 "<p>" 2092 "The specified thread must be suspended. " 2093 "The return occurs when execution of Java programming " 2094 "language code is resumed on this thread. Between sending this " 2095 "command and resumption of thread execution, the " 2096 "state of the stack is undefined. " 2097 "<p>" 2098 "No further instructions are executed in the called " 2099 "method. Specifically, finally blocks are not executed. Note: " 2100 "this can cause inconsistent states in the application. " 2101 "<p>" 2102 "A lock acquired by calling the called method (if it is a " 2103 "synchronized method) and locks acquired by entering " 2104 "synchronized blocks within the called method are " 2105 "released. Note: this does not apply to JNI locks or " 2106 "java.util.concurrent.locks locks. " 2107 "<p>" 2108 "Events, such as MethodExit, are generated as they would be in " 2109 "a normal return. " 2110 "<p>" 2111 "The called method must be a non-native Java programming " 2112 "language method. Forcing return on a thread with only one " 2113 "frame on the stack causes the thread to exit when resumed. " 2114 "<p>" 2115 "For void methods, the value must be a void value. " 2116 "For methods that return primitive values, the value's type must " 2117 "match the return type exactly. For object values, there must be a " 2118 "widening reference conversion from the value's type to the " 2119 "return type type and the return type must be loaded. " 2120 "<p>" 2121 "Since JDWP version 1.6. Requires canForceEarlyReturn capability - see " 2122 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 2123 (Out 2124 (threadObject thread "The thread object ID. ") 2125 (value value "The value to return. ") 2126 ) 2127 (Reply "none" 2128 ) 2129 (ErrorSet 2130 (Error INVALID_THREAD) 2131 (Error INVALID_OBJECT "Thread or value is not a known ID.") 2132 (Error THREAD_NOT_SUSPENDED) 2133 (Error THREAD_NOT_ALIVE) 2134 (Error OPAQUE_FRAME "Attempted to return early from " 2135 "a frame corresponding to a native " 2136 "method. Or the implementation is " 2137 "unable to provide this functionality " 2138 "on this frame.") 2139 (Error NO_MORE_FRAMES) 2140 (Error NOT_IMPLEMENTED) 2141 (Error TYPE_MISMATCH "Value is not an appropriate type for the " 2142 "return value of the method.") 2143 (Error VM_DEAD) 2144 ) 2145 ) 2146 2147 ) 2148 (CommandSet ThreadGroupReference=12 2149 (Command Name=1 2150 "Returns the thread group name. " 2151 (Out 2152 (threadGroupObject group "The thread group object ID. ") 2153 ) 2154 (Reply 2155 (string groupName "The thread group's name.") 2156 ) 2157 (ErrorSet 2158 (Error INVALID_THREAD_GROUP) 2159 (Error INVALID_OBJECT "group is not a known ID.") 2160 (Error VM_DEAD) 2161 ) 2162 ) 2163 (Command Parent=2 2164 "Returns the thread group, if any, which contains a given thread group. " 2165 (Out 2166 (threadGroupObject group "The thread group object ID. ") 2167 ) 2168 (Reply 2169 (threadGroupObject parentGroup "The parent thread group object, or " 2170 "null if the given thread group " 2171 "is a top-level thread group") 2172 ) 2173 (ErrorSet 2174 (Error INVALID_THREAD_GROUP) 2175 (Error INVALID_OBJECT "group is not a known ID.") 2176 (Error VM_DEAD) 2177 ) 2178 ) 2179 (Command Children=3 2180 "Returns the live threads and active thread groups directly contained " 2181 "in this thread group. Threads and thread groups in child " 2182 "thread groups are not included. " 2183 "A thread is alive if it has been started and has not yet been stopped. " 2184 "See <a href=../../api/java.base/java/lang/ThreadGroup.html>java.lang.ThreadGroup </a> 2185 "for information about active ThreadGroups. 2186 (Out 2187 (threadGroupObject group "The thread group object ID. ") 2188 ) 2189 (Reply 2190 (Repeat childThreads "The number of live child threads. " 2191 (threadObject childThread "A direct child thread ID. ") 2192 ) 2193 (Repeat childGroups "The number of active child thread groups. " 2194 (threadGroupObject childGroup "A direct child thread group ID. ") 2195 ) 2196 ) 2197 (ErrorSet 2198 (Error INVALID_THREAD_GROUP) 2199 (Error INVALID_OBJECT "group is not a known ID.") 2200 (Error VM_DEAD) 2201 ) 2202 ) 2203 ) 2204 (CommandSet ArrayReference=13 2205 (Command Length=1 2206 "Returns the number of components in a given array. " 2207 (Out 2208 (arrayObject arrayObject "The array object ID. ") 2209 ) 2210 (Reply 2211 (int arrayLength "The length of the array.") 2212 ) 2213 (ErrorSet 2214 (Error INVALID_OBJECT "arrayObject is not a known ID.") 2215 (Error INVALID_ARRAY) 2216 (Error VM_DEAD) 2217 ) 2218 ) 2219 (Command GetValues=2 2220 "Returns a range of array components. The specified range must " 2221 "be within the bounds of the array. " 2222 (Out 2223 (arrayObject arrayObject "The array object ID. ") 2224 (int firstIndex "The first index to retrieve.") 2225 (int length "The number of components to retrieve.") 2226 ) 2227 (Reply 2228 (typed-sequence values "The retrieved values. If the values " 2229 "are objects, they are tagged-values; " 2230 "otherwise, they are untagged-values") 2231 ) 2232 (ErrorSet 2233 (Error INVALID_LENGTH "If index is beyond the end of this array.") 2234 (Error INVALID_OBJECT "arrayObject is not a known ID.") 2235 (Error INVALID_ARRAY) 2236 (Error VM_DEAD) 2237 ) 2238 ) 2239 (Command SetValues=3 2240 "Sets a range of array components. The specified range must " 2241 "be within the bounds of the array. " 2242 "For primitive values, each value's type must match the " 2243 "array component type exactly. For object values, there must be a " 2244 "widening reference conversion from the value's type to the 2245 "array component type and the array component type must be loaded. " 2246 (Out 2247 (arrayObject arrayObject "The array object ID. ") 2248 (int firstIndex "The first index to set.") 2249 (Repeat values "The number of values to set. " 2250 (untagged-value value "A value to set. ") 2251 ) 2252 ) 2253 (Reply "none" 2254 ) 2255 (ErrorSet 2256 (Error INVALID_LENGTH "If index is beyond the end of this array.") 2257 (Error INVALID_OBJECT "arrayObject is not a known ID.") 2258 (Error INVALID_ARRAY) 2259 (Error VM_DEAD) 2260 ) 2261 ) 2262 ) 2263 (CommandSet ClassLoaderReference=14 2264 (Command VisibleClasses=1 2265 "Returns a list of all classes which this class loader can find " 2266 "by name via <code>ClassLoader::loadClass</code>, " 2267 "<code>Class::forName</code> and bytecode linkage. That is, " 2268 "all classes for which this class loader has been recorded as an " 2269 "<i>initiating</i> loader. The list contains each " 2270 "reference type created by this loader and any types for which " 2271 "loading was delegated by this class loader to another class loader. " 2272 "<p>" 2273 "The visible class list has useful properties with respect to " 2274 "the type namespace. A particular type name will occur at most " 2275 "once in the list. Each field or variable declared with that " 2276 "type name in a class defined by " 2277 "this class loader must be resolved to that single type. " 2278 "<p>" 2279 "No ordering of the returned list is guaranteed. " 2280 "<p>" 2281 "See <a href=\"../jvmti.html#GetClassLoaderClasses\">JVM TI GetClassLoaderClasses</a>. " 2282 (Out 2283 (classLoaderObject classLoaderObject "The class loader object ID. ") 2284 ) 2285 (Reply 2286 (Repeat classes "The number of visible classes. " 2287 (Group ClassInfo 2288 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 2289 "of following reference type. ") 2290 (referenceTypeID typeID 2291 "A class visible to this class loader.") 2292 ) 2293 ) 2294 ) 2295 (ErrorSet 2296 (Error INVALID_OBJECT) 2297 (Error INVALID_CLASS_LOADER) 2298 (Error VM_DEAD) 2299 ) 2300 ) 2301 ) 2302 (CommandSet EventRequest=15 2303 (Command Set=1 2304 "Set an event request. When the event described by this request " 2305 "occurs, an <a href=\"#JDWP_Event\">event</a> is sent from the " 2306 "target VM. If an event occurs that has not been requested then it is not sent " 2307 "from the target VM. The two exceptions to this are the VM Start Event and " 2308 "the VM Death Event which are automatically generated events - see " 2309 "<a href=\"#JDWP_Event_Composite\">Composite Command</a> for further details." 2310 (Out 2311 (byte eventKind "Event kind to request. " 2312 "See <a href=\"#JDWP_EventKind\">JDWP.EventKind</a> " 2313 "for a complete list of events that can be requested; " 2314 "some events may require a capability in order to be requested. " 2315 ) 2316 (byte suspendPolicy 2317 "What threads are suspended when this event occurs? " 2318 "Note that the order of events and command replies " 2319 "accurately reflects the order in which threads are " 2320 "suspended and resumed. For example, if a " 2321 "<a href=\"#JDWP_VirtualMachine_Resume\">VM-wide resume</a> " 2322 "is processed before an event occurs which suspends the " 2323 "VM, the reply to the resume command will be written to " 2324 "the transport before the suspending event.") 2325 (Repeat modifiers "Constraints used to control the number " 2326 "of generated events." 2327 "Modifiers specify additional tests that " 2328 "an event must satisfy before it is placed " 2329 "in the event queue. Events are filtered by " 2330 "applying each modifier to an event in the " 2331 "order they are specified in this collection " 2332 "Only events that satisfy all modifiers " 2333 "are reported. A value of 0 means there are no " 2334 "modifiers in the request." 2335 "<p>" 2336 "Filtering can improve " 2337 "debugger performance dramatically by 2338 "reducing the " 2339 "amount of event traffic sent from the " 2340 "target VM to the debugger VM. " 2341 (Select Modifier 2342 (byte modKind "Modifier kind") 2343 (Alt Count=1 2344 "Limit the requested event to be reported at most once after a " 2345 "given number of occurrences. The event is not reported " 2346 "the first <code>count - 1</code> times this filter is reached. " 2347 "To request a one-off event, call this method with a count of 1. " 2348 "<p>" 2349 "Once the count reaches 0, any subsequent filters in this request " 2350 "are applied. If none of those filters cause the event to be " 2351 "suppressed, the event is reported. Otherwise, the event is not " 2352 "reported. In either case subsequent events are never reported for " 2353 "this request. " 2354 "This modifier can be used with any event kind." 2355 2356 (int count "Count before event. One for one-off.") 2357 ) 2358 (Alt Conditional=2 "Conditional on expression" 2359 (int exprID "For the future") 2360 ) 2361 (Alt ThreadOnly=3 2362 "Restricts reported events to " 2363 "those in the given thread. " 2364 "This modifier can be used with any event kind " 2365 "except for class unload. " 2366 2367 (threadObject thread "Required thread") 2368 ) 2369 (Alt ClassOnly=4 2370 "For class prepare events, restricts the events " 2371 "generated by this request to be the " 2372 "preparation of the given reference type and any subtypes. " 2373 "For monitor wait and waited events, restricts the events " 2374 "generated by this request to those whose monitor object " 2375 "is of the given reference type or any of its subtypes. " 2376 "For other events, restricts the events generated " 2377 "by this request to those " 2378 "whose location is in the given reference type or any of its subtypes. " 2379 "An event will be generated for any location in a reference type that can " 2380 "be safely cast to the given reference type. " 2381 "This modifier can be used with any event kind except " 2382 "class unload, thread start, and thread end. " 2383 2384 (referenceType clazz "Required class") 2385 ) 2386 (Alt ClassMatch=5 2387 "Restricts reported events to those for classes whose name " 2388 "matches the given restricted regular expression. " 2389 "For class prepare events, the prepared class name " 2390 "is matched. For class unload events, the " 2391 "unloaded class name is matched. For monitor wait " 2392 "and waited events, the name of the class of the " 2393 "monitor object is matched. For other events, " 2394 "the class name of the event's location is matched. " 2395 "This modifier can be used with any event kind except " 2396 "thread start and thread end. " 2397 2398 (string classPattern "Required class pattern. " 2399 "Matches are limited to exact matches of the " 2400 "given class pattern and matches of patterns that " 2401 "begin or end with '*'; for example, " 2402 "\"*.Foo\" or \"java.*\". " 2403 ) 2404 2405 ) 2406 (Alt ClassExclude=6 2407 "Restricts reported events to those for classes whose name " 2408 "does not match the given restricted regular expression. " 2409 "For class prepare events, the prepared class name " 2410 "is matched. For class unload events, the " 2411 "unloaded class name is matched. For monitor wait and " 2412 "waited events, the name of the class of the monitor " 2413 "object is matched. For other events, " 2414 "the class name of the event's location is matched. " 2415 "This modifier can be used with any event kind except " 2416 "thread start and thread end. " 2417 2418 (string classPattern "Disallowed class pattern. " 2419 "Matches are limited to exact matches of the " 2420 "given class pattern and matches of patterns that " 2421 "begin or end with '*'; for example, " 2422 "\"*.Foo\" or \"java.*\". " 2423 ) 2424 ) 2425 (Alt LocationOnly=7 2426 "Restricts reported events to those that occur at " 2427 "the given location. " 2428 "This modifier can be used with " 2429 "breakpoint, field access, field modification, " 2430 "step, and exception event kinds. " 2431 2432 (location loc "Required location") 2433 ) 2434 (Alt ExceptionOnly=8 2435 "Restricts reported exceptions by their class and " 2436 "whether they are caught or uncaught. " 2437 "This modifier can be used with " 2438 "exception event kinds only. " 2439 2440 (referenceType exceptionOrNull 2441 "Exception to report. Null (0) means report " 2442 "exceptions of all types. " 2443 "A non-null type restricts the reported exception " 2444 "events to exceptions of the given type or " 2445 "any of its subtypes. " 2446 ) 2447 (boolean caught "Report caught exceptions") 2448 (boolean uncaught "Report uncaught exceptions. " 2449 "Note that it " 2450 "is not always possible to determine whether an " 2451 "exception is caught or uncaught at the time it is " 2452 "thrown. See the exception event catch location under " 2453 "<a href=\"#JDWP_Event_Composite\">composite events</a> " 2454 "for more information. " 2455 ) 2456 2457 ) 2458 (Alt FieldOnly=9 2459 "Restricts reported events to those that occur for " 2460 "a given field. " 2461 "This modifier can be used with " 2462 "field access and field modification event kinds only. " 2463 2464 (referenceType declaring "Type in which field is declared.") 2465 (field fieldID "Required field") 2466 ) 2467 (Alt Step=10 2468 "Restricts reported step events " 2469 "to those which satisfy " 2470 "depth and size constraints. " 2471 "This modifier can be used with " 2472 "step event kinds only. " 2473 2474 (threadObject thread "Thread in which to step") 2475 (int size "size of each step. " 2476 "See <a href=\"#JDWP_StepSize\">JDWP.StepSize</a>") 2477 (int depth "relative call stack limit. " 2478 "See <a href=\"#JDWP_StepDepth\">JDWP.StepDepth</a>") 2479 ) 2480 (Alt InstanceOnly=11 2481 "Restricts reported events to those whose " 2482 "active 'this' object is the given object. " 2483 "Match value is the null object for static methods. " 2484 "This modifier can be used with any event kind " 2485 "except class prepare, class unload, thread start, " 2486 "and thread end. Introduced in JDWP version 1.4." 2487 2488 (object instance "Required 'this' object") 2489 ) 2490 (Alt SourceNameMatch=12 2491 "Restricts reported class prepare events to those " 2492 "for reference types which have a source name " 2493 "which matches the given restricted regular expression. " 2494 "The source names are determined by the reference type's " 2495 "<a href=\"#JDWP_ReferenceType_SourceDebugExtension\"> " 2496 "SourceDebugExtension</a>. " 2497 "This modifier can only be used with class prepare " 2498 "events. " 2499 "Since JDWP version 1.6. Requires the canUseSourceNameFilters " 2500 "capability - see " 2501 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 2502 2503 (string sourceNamePattern "Required source name pattern. " 2504 "Matches are limited to exact matches of the " 2505 "given pattern and matches of patterns that " 2506 "begin or end with '*'; for example, " 2507 "\"*.Foo\" or \"java.*\". " 2508 ) 2509 ) 2510 2511 ) 2512 ) 2513 ) 2514 (Reply 2515 (int requestID "ID of created request") 2516 ) 2517 (ErrorSet 2518 (Error INVALID_THREAD) 2519 (Error INVALID_CLASS) 2520 (Error INVALID_STRING) 2521 (Error INVALID_OBJECT) 2522 (Error INVALID_COUNT) 2523 (Error INVALID_FIELDID) 2524 (Error INVALID_METHODID) 2525 (Error INVALID_LOCATION) 2526 (Error INVALID_EVENT_TYPE) 2527 (Error NOT_IMPLEMENTED) 2528 (Error VM_DEAD) 2529 ) 2530 ) 2531 (Command Clear=2 2532 "Clear an event request. See <a href=\"#JDWP_EventKind\">JDWP.EventKind</a> " 2533 "for a complete list of events that can be cleared. Only the event request matching " 2534 "the specified event kind and requestID is cleared. If there isn't a matching event " 2535 "request the command is a no-op and does not result in an error. Automatically " 2536 "generated events do not have a corresponding event request and may not be cleared " 2537 "using this command." 2538 (Out 2539 (byte eventKind "Event kind to clear") 2540 (int requestID "ID of request to clear") 2541 ) 2542 (Reply "none" 2543 ) 2544 (ErrorSet 2545 (Error VM_DEAD) 2546 (Error INVALID_EVENT_TYPE) 2547 ) 2548 ) 2549 (Command ClearAllBreakpoints=3 2550 "Removes all set breakpoints, a no-op if there are no breakpoints set." 2551 (Out "none" 2552 ) 2553 (Reply "none" 2554 ) 2555 (ErrorSet 2556 (Error VM_DEAD) 2557 ) 2558 ) 2559 ) 2560 (CommandSet StackFrame=16 2561 (Command GetValues=1 2562 "Returns the value of one or more local variables in a " 2563 "given frame. Each variable must be visible at the frame's code index. " 2564 "Even if local variable information is not available, values can " 2565 "be retrieved if the front-end is able to " 2566 "determine the correct local variable index. (Typically, this " 2567 "index can be determined for method arguments from the method " 2568 "signature without access to the local variable table information.) " 2569 (Out 2570 (threadObject thread "The frame's thread. ") 2571 (frame frame "The frame ID. ") 2572 (Repeat slots "The number of values to get. " 2573 (Group SlotInfo 2574 (int slot "The local variable's index in the frame. ") 2575 (byte sigbyte "A <a href=\"#JDWP_Tag\">tag</a> " 2576 "identifying the type of the variable ") 2577 ) 2578 ) 2579 ) 2580 (Reply 2581 (Repeat values "The number of values retrieved, always equal to slots, " 2582 "the number of values to get." 2583 (value slotValue "The value of the local variable. ") 2584 ) 2585 ) 2586 (ErrorSet 2587 (Error INVALID_THREAD) 2588 (Error INVALID_OBJECT) 2589 (Error INVALID_FRAMEID) 2590 (Error INVALID_SLOT) 2591 (Error VM_DEAD) 2592 ) 2593 ) 2594 (Command SetValues=2 2595 "Sets the value of one or more local variables. " 2596 "Each variable must be visible at the current frame code index. " 2597 "For primitive values, the value's type must match the " 2598 "variable's type exactly. For object values, there must be a " 2599 "widening reference conversion from the value's type to the 2600 "variable's type and the variable's type must be loaded. " 2601 "<p>" 2602 "Even if local variable information is not available, values can " 2603 "be set, if the front-end is able to " 2604 "determine the correct local variable index. (Typically, this 2605 "index can be determined for method arguments from the method " 2606 "signature without access to the local variable table information.) " 2607 (Out 2608 (threadObject thread "The frame's thread. ") 2609 (frame frame "The frame ID. ") 2610 (Repeat slotValues "The number of values to set. " 2611 (Group SlotInfo 2612 (int slot "The slot ID. ") 2613 (value slotValue "The value to set. ") 2614 ) 2615 ) 2616 ) 2617 (Reply "none" 2618 ) 2619 (ErrorSet 2620 (Error INVALID_THREAD) 2621 (Error INVALID_OBJECT) 2622 (Error INVALID_FRAMEID) 2623 (Error VM_DEAD) 2624 ) 2625 ) 2626 (Command ThisObject=3 2627 "Returns the value of the 'this' reference for this frame. " 2628 "If the frame's method is static or native, the reply " 2629 "will contain the null object reference. " 2630 (Out 2631 (threadObject thread "The frame's thread. ") 2632 (frame frame "The frame ID. ") 2633 ) 2634 (Reply 2635 (tagged-object objectThis "The 'this' object for this frame. ") 2636 ) 2637 (ErrorSet 2638 (Error INVALID_THREAD) 2639 (Error INVALID_OBJECT) 2640 (Error INVALID_FRAMEID) 2641 (Error VM_DEAD) 2642 ) 2643 ) 2644 (Command PopFrames=4 2645 "Pop the top-most stack frames of the thread stack, up to, and including 'frame'. " 2646 "The thread must be suspended to perform this command. " 2647 "The top-most stack frames are discarded and the stack frame previous to 'frame' " 2648 "becomes the current frame. The operand stack is restored -- the argument values " 2649 "are added back and if the invoke was not <code>invokestatic</code>, " 2650 "<code>objectref</code> is added back as well. The Java virtual machine " 2651 "program counter is restored to the opcode of the invoke instruction." 2652 "<p>" 2653 "Since JDWP version 1.4. Requires canPopFrames capability - see " 2654 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 2655 (Out 2656 (threadObject thread "The thread object ID. ") 2657 (frame frame "The frame ID. ") 2658 ) 2659 (Reply "none" 2660 ) 2661 (ErrorSet 2662 (Error INVALID_THREAD) 2663 (Error INVALID_OBJECT "thread is not a known ID.") 2664 (Error INVALID_FRAMEID) 2665 (Error THREAD_NOT_SUSPENDED) 2666 (Error NO_MORE_FRAMES) 2667 (Error INVALID_FRAMEID) 2668 (Error NOT_IMPLEMENTED) 2669 (Error VM_DEAD) 2670 ) 2671 ) 2672 ) 2673 (CommandSet ClassObjectReference=17 2674 (Command ReflectedType = 1 2675 "Returns the reference type reflected by this class object." 2676 (Out 2677 (classObject classObject "The class object. ") 2678 ) 2679 (Reply 2680 (byte refTypeTag "<a href=\"#JDWP_TypeTag\">Kind</a> " 2681 "of following reference type. ") 2682 (referenceTypeID typeID "reflected reference type") 2683 ) 2684 (ErrorSet 2685 (Error INVALID_OBJECT) 2686 (Error VM_DEAD) 2687 ) 2688 ) 2689 ) 2690 (CommandSet ModuleReference=18 2691 (Command Name=1 2692 "Returns the name of this module." 2693 "<p>Since JDWP version 9." 2694 (Out 2695 (moduleID module "This module.") 2696 ) 2697 (Reply 2698 (string name "The module's name.") 2699 ) 2700 (ErrorSet 2701 (Error INVALID_MODULE) 2702 (Error NOT_IMPLEMENTED) 2703 (Error VM_DEAD) 2704 ) 2705 ) 2706 (Command ClassLoader=2 2707 "Returns the class loader of this module." 2708 "<p>Since JDWP version 9." 2709 (Out 2710 (moduleID module "This module.") 2711 ) 2712 (Reply 2713 (classLoaderObject classLoader "The module's class loader.") 2714 ) 2715 (ErrorSet 2716 (Error INVALID_MODULE) 2717 (Error NOT_IMPLEMENTED) 2718 (Error VM_DEAD) 2719 ) 2720 ) 2721 ) 2722 (CommandSet Event=64 2723 (Command Composite=100 2724 "Several events may occur at a given time in the target VM. " 2725 "For example, there may be more than one breakpoint request " 2726 "for a given location " 2727 "or you might single step to the same location as a " 2728 "breakpoint request. These events are delivered " 2729 "together as a composite event. For uniformity, a " 2730 "composite event is always used " 2731 "to deliver events, even if there is only one event to report. " 2732 "<P>" 2733 "The events that are grouped in a composite event are restricted in the " 2734 "following ways: " 2735 "<UL>" 2736 "<LI>Only with other thread start events for the same thread:" 2737 " <UL>" 2738 " <LI>Thread Start Event" 2739 " </UL>" 2740 "<LI>Only with other thread death events for the same thread:" 2741 " <UL>" 2742 " <LI>Thread Death Event" 2743 " </UL>" 2744 "<LI>Only with other class prepare events for the same class:" 2745 " <UL>" 2746 " <LI>Class Prepare Event" 2747 " </UL>" 2748 "<LI>Only with other class unload events for the same class:" 2749 " <UL>" 2750 " <LI>Class Unload Event" 2751 " </UL>" 2752 "<LI>Only with other access watchpoint events for the same field access:" 2753 " <UL>" 2754 " <LI>Access Watchpoint Event" 2755 " </UL>" 2756 "<LI>Only with other modification watchpoint events for the same field " 2757 "modification:" 2758 " <UL>" 2759 " <LI>Modification Watchpoint Event" 2760 " </UL>" 2761 "<LI>Only with other Monitor contended enter events for the same monitor object: " 2762 " <UL>" 2763 " <LI>Monitor Contended Enter Event" 2764 " </UL>" 2765 "<LI>Only with other Monitor contended entered events for the same monitor object: " 2766 " <UL>" 2767 " <LI>Monitor Contended Entered Event" 2768 " </UL>" 2769 "<LI>Only with other Monitor wait events for the same monitor object: " 2770 " <UL>" 2771 " <LI>Monitor Wait Event" 2772 " </UL>" 2773 "<LI>Only with other Monitor waited events for the same monitor object: " 2774 " <UL>" 2775 " <LI>Monitor Waited Event" 2776 " </UL>" 2777 "<LI>Only with other ExceptionEvents for the same exception occurrance:" 2778 " <UL>" 2779 " <LI>ExceptionEvent" 2780 " </UL>" 2781 "<LI>Only with other members of this group, at the same location " 2782 "and in the same thread: " 2783 " <UL>" 2784 " <LI>Breakpoint Event" 2785 " <LI>Step Event" 2786 " <LI>Method Entry Event" 2787 " <LI>Method Exit Event" 2788 " </UL>" 2789 "</UL>" 2790 "<P>" 2791 "The VM Start Event and VM Death Event are automatically generated events. " 2792 "This means they do not need to be requested using the " 2793 "<a href=\"#JDWP_EventRequest_Set\">EventRequest.Set</a> command. " 2794 "The VM Start event signals the completion of VM initialization. The VM Death " 2795 "event signals the termination of the VM." 2796 "If there is a debugger connected at the time when an automatically generated " 2797 "event occurs it is sent from the target VM. Automatically generated events may " 2798 "also be requested using the EventRequest.Set command and thus multiple events " 2799 "of the same event kind will be sent from the target VM when an event occurs." 2800 "Automatically generated events are sent with the requestID field " 2801 "in the Event Data set to 0. The value of the suspendPolicy field in the " 2802 "Event Data depends on the event. For the automatically generated VM Start " 2803 "Event the value of suspendPolicy is not defined and is therefore implementation " 2804 "or configuration specific. In the Sun implementation, for example, the " 2805 "suspendPolicy is specified as an option to the JDWP agent at launch-time." 2806 "The automatically generated VM Death Event will have the suspendPolicy set to " 2807 "NONE." 2808 2809 (Event "Generated event" 2810 (byte suspendPolicy 2811 "Which threads where suspended by this composite event?") 2812 (Repeat events "Events in set." 2813 (Select Events 2814 (byte eventKind "Event kind selector") 2815 (Alt VMStart=JDWP.EventKind.VM_START 2816 "Notification of initialization of a target VM. This event is " 2817 "received before the main thread is started and before any " 2818 "application code has been executed. Before this event occurs " 2819 "a significant amount of system code has executed and a number " 2820 "of system classes have been loaded. " 2821 "This event is always generated by the target VM, even " 2822 "if not explicitly requested." 2823 2824 (int requestID 2825 "Request that generated event (or 0 if this " 2826 "event is automatically generated.") 2827 (threadObject thread "Initial thread") 2828 ) 2829 (Alt SingleStep=JDWP.EventKind.SINGLE_STEP 2830 "Notification of step completion in the target VM. The step event " 2831 "is generated before the code at its location is executed. " 2832 2833 (int requestID "Request that generated event") 2834 (threadObject thread "Stepped thread") 2835 (location location "Location stepped to") 2836 ) 2837 (Alt Breakpoint=JDWP.EventKind.BREAKPOINT 2838 "Notification of a breakpoint in the target VM. The breakpoint event " 2839 "is generated before the code at its location is executed. " 2840 2841 (int requestID "Request that generated event") 2842 (threadObject thread "Thread which hit breakpoint") 2843 (location location "Location hit") 2844 ) 2845 (Alt MethodEntry=JDWP.EventKind.METHOD_ENTRY 2846 "Notification of a method invocation in the target VM. This event " 2847 "is generated before any code in the invoked method has executed. " 2848 "Method entry events are generated for both native and non-native " 2849 "methods. " 2850 "<P>" 2851 "In some VMs method entry events can occur for a particular thread " 2852 "before its thread start event occurs if methods are called " 2853 "as part of the thread's initialization. " 2854 2855 (int requestID "Request that generated event") 2856 (threadObject thread "Thread which entered method") 2857 (location location "The initial executable location in the method.") 2858 ) 2859 (Alt MethodExit=JDWP.EventKind.METHOD_EXIT 2860 "Notification of a method return in the target VM. This event " 2861 "is generated after all code in the method has executed, but the " 2862 "location of this event is the last executed location in the method. " 2863 "Method exit events are generated for both native and non-native " 2864 "methods. Method exit events are not generated if the method terminates " 2865 "with a thrown exception. " 2866 2867 (int requestID "Request that generated event") 2868 (threadObject thread "Thread which exited method") 2869 (location location "Location of exit") 2870 ) 2871 (Alt MethodExitWithReturnValue=JDWP.EventKind.METHOD_EXIT_WITH_RETURN_VALUE 2872 "Notification of a method return in the target VM. This event " 2873 "is generated after all code in the method has executed, but the " 2874 "location of this event is the last executed location in the method. " 2875 "Method exit events are generated for both native and non-native " 2876 "methods. Method exit events are not generated if the method terminates " 2877 "with a thrown exception. <p>Since JDWP version 1.6. " 2878 2879 (int requestID "Request that generated event") 2880 (threadObject thread "Thread which exited method") 2881 (location location "Location of exit") 2882 (value value "Value that will be returned by the method") 2883 ) 2884 (Alt MonitorContendedEnter=JDWP.EventKind.MONITOR_CONTENDED_ENTER 2885 "Notification that a thread in the target VM is attempting " 2886 "to enter a monitor that is already acquired by another thread. " 2887 "Requires canRequestMonitorEvents capability - see " 2888 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 2889 "<p>Since JDWP version 1.6. " 2890 2891 (int requestID 2892 "Request that generated event") 2893 (threadObject thread "Thread which is trying to enter the monitor") 2894 (tagged-object object "Monitor object reference") 2895 (location location "Location of contended monitor enter") 2896 ) 2897 (Alt MonitorContendedEntered=JDWP.EventKind.MONITOR_CONTENDED_ENTERED 2898 "Notification of a thread in the target VM is entering a monitor " 2899 "after waiting for it to be released by another thread. " 2900 "Requires canRequestMonitorEvents capability - see " 2901 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 2902 "<p>Since JDWP version 1.6. " 2903 2904 (int requestID 2905 "Request that generated event") 2906 (threadObject thread "Thread which entered monitor") 2907 (tagged-object object "Monitor object reference") 2908 (location location "Location of contended monitor enter") 2909 ) 2910 (Alt MonitorWait=JDWP.EventKind.MONITOR_WAIT 2911 "Notification of a thread about to wait on a monitor object. " 2912 "Requires canRequestMonitorEvents capability - see " 2913 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 2914 "<p>Since JDWP version 1.6. " 2915 2916 (int requestID 2917 "Request that generated event") 2918 (threadObject thread "Thread which is about to wait") 2919 (tagged-object object "Monitor object reference") 2920 (location location "Location at which the wait will occur") 2921 (long timeout "Thread wait time in milliseconds") 2922 ) 2923 (Alt MonitorWaited=JDWP.EventKind.MONITOR_WAITED 2924 "Notification that a thread in the target VM has finished waiting on " 2925 "Requires canRequestMonitorEvents capability - see " 2926 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>. " 2927 "a monitor object. " 2928 "<p>Since JDWP version 1.6. " 2929 2930 (int requestID 2931 "Request that generated event") 2932 (threadObject thread "Thread which waited") 2933 (tagged-object object "Monitor object reference") 2934 (location location "Location at which the wait occured") 2935 (boolean timed_out "True if timed out") 2936 ) 2937 (Alt Exception=JDWP.EventKind.EXCEPTION 2938 "Notification of an exception in the target VM. " 2939 "If the exception is thrown from a non-native method, " 2940 "the exception event is generated at the location where the " 2941 "exception is thrown. " 2942 "If the exception is thrown from a native method, the exception event " 2943 "is generated at the first non-native location reached after the exception " 2944 "is thrown. " 2945 2946 (int requestID "Request that generated event") 2947 (threadObject thread "Thread with exception") 2948 (location location "Location of exception throw " 2949 "(or first non-native location after throw if thrown from a native method)") 2950 (tagged-object exception "Thrown exception") 2951 (location catchLocation 2952 "Location of catch, or 0 if not caught. An exception " 2953 "is considered to be caught if, at the point of the throw, the " 2954 "current location is dynamically enclosed in a try statement that " 2955 "handles the exception. (See the JVM specification for details). " 2956 "If there is such a try statement, the catch location is the " 2957 "first location in the appropriate catch clause. " 2958 "<p>" 2959 "If there are native methods in the call stack at the time of the " 2960 "exception, there are important restrictions to note about the " 2961 "returned catch location. In such cases, " 2962 "it is not possible to predict whether an exception will be handled " 2963 "by some native method on the call stack. " 2964 "Thus, it is possible that exceptions considered uncaught " 2965 "here will, in fact, be handled by a native method and not cause " 2966 "termination of the target VM. Furthermore, it cannot be assumed that the " 2967 "catch location returned here will ever be reached by the throwing " 2968 "thread. If there is " 2969 "a native frame between the current location and the catch location, " 2970 "the exception might be handled and cleared in that native method " 2971 "instead. " 2972 "<p>" 2973 "Note that compilers can generate try-catch blocks in some cases " 2974 "where they are not explicit in the source code; for example, " 2975 "the code generated for <code>synchronized</code> and " 2976 "<code>finally</code> blocks can contain implicit try-catch blocks. " 2977 "If such an implicitly generated try-catch is " 2978 "present on the call stack at the time of the throw, the exception " 2979 "will be considered caught even though it appears to be uncaught from " 2980 "examination of the source code. " 2981 ) 2982 ) 2983 (Alt ThreadStart=JDWP.EventKind.THREAD_START 2984 "Notification of a new running thread in the target VM. " 2985 "The new thread can be the result of a call to " 2986 "<code>java.lang.Thread.start</code> or the result of " 2987 "attaching a new thread to the VM though JNI. The " 2988 "notification is generated by the new thread some time before " 2989 "its execution starts. " 2990 "Because of this timing, it is possible to receive other events " 2991 "for the thread before this event is received. (Notably, " 2992 "Method Entry Events and Method Exit Events might occur " 2993 "during thread initialization. " 2994 "It is also possible for the " 2995 "<a href=\"#JDWP_VirtualMachine_AllThreads\">VirtualMachine AllThreads</a> " 2996 "command to return " 2997 "a thread before its thread start event is received. " 2998 "<p>" 2999 "Note that this event gives no information " 3000 "about the creation of the thread object which may have happened " 3001 "much earlier, depending on the VM being debugged. " 3002 3003 (int requestID "Request that generated event") 3004 (threadObject thread "Started thread") 3005 ) 3006 (Alt ThreadDeath=JDWP.EventKind.THREAD_DEATH 3007 "Notification of a completed thread in the target VM. The " 3008 "notification is generated by the dying thread before it terminates. " 3009 "Because of this timing, it is possible " 3010 "for {@link VirtualMachine#allThreads} to return this thread " 3011 "after this event is received. " 3012 "<p>" 3013 "Note that this event gives no information " 3014 "about the lifetime of the thread object. It may or may not be collected " 3015 "soon depending on what references exist in the target VM. " 3016 3017 (int requestID "Request that generated event") 3018 (threadObject thread "Ending thread") 3019 ) 3020 (Alt ClassPrepare=JDWP.EventKind.CLASS_PREPARE 3021 "Notification of a class prepare in the target VM. See the JVM " 3022 "specification for a definition of class preparation. Class prepare " 3023 "events are not generated for primtiive classes (for example, " 3024 "java.lang.Integer.TYPE). " 3025 3026 (int requestID "Request that generated event") 3027 (threadObject thread "Preparing thread. " 3028 "In rare cases, this event may occur in a debugger system " 3029 "thread within the target VM. Debugger threads take precautions " 3030 "to prevent these events, but they cannot be avoided under some " 3031 "conditions, especially for some subclasses of " 3032 "java.lang.Error. " 3033 "If the event was generated by a debugger system thread, the " 3034 "value returned by this method is null, and if the requested " 3035 "<a href=\"#JDWP_SuspendPolicy\">suspend policy</a> " 3036 "for the event was EVENT_THREAD " 3037 "all threads will be suspended instead, and the " 3038 "composite event's suspend policy will reflect this change. " 3039 "<p>" 3040 "Note that the discussion above does not apply to system threads " 3041 "created by the target VM during its normal (non-debug) operation. " 3042 ) 3043 (byte refTypeTag "Kind of reference type. " 3044 "See <a href=\"#JDWP_TypeTag\">JDWP.TypeTag</a>") 3045 (referenceTypeID typeID "Type being prepared") 3046 (string signature "Type signature") 3047 (int status "Status of type. " 3048 "See <a href=\"#JDWP_ClassStatus\">JDWP.ClassStatus</a>") 3049 ) 3050 (Alt ClassUnload=JDWP.EventKind.CLASS_UNLOAD 3051 "Notification of a class unload in the target VM. " 3052 "<p>" 3053 "There are severe constraints on the debugger back-end during " 3054 "garbage collection, so unload information is greatly limited. " 3055 3056 (int requestID "Request that generated event") 3057 (string signature "Type signature") 3058 ) 3059 (Alt FieldAccess=JDWP.EventKind.FIELD_ACCESS 3060 "Notification of a field access in the target VM. " 3061 "Field modifications " 3062 "are not considered field accesses. " 3063 "Requires canWatchFieldAccess capability - see " 3064 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 3065 3066 (int requestID "Request that generated event") 3067 (threadObject thread "Accessing thread") 3068 (location location "Location of access") 3069 (byte refTypeTag "Kind of reference type. " 3070 "See <a href=\"#JDWP_TypeTag\">JDWP.TypeTag</a>") 3071 (referenceTypeID typeID "Type of field") 3072 (field fieldID "Field being accessed") 3073 (tagged-object object 3074 "Object being accessed (null=0 for statics") 3075 ) 3076 (Alt FieldModification=JDWP.EventKind.FIELD_MODIFICATION 3077 "Notification of a field modification in the target VM. " 3078 "Requires canWatchFieldModification capability - see " 3079 "<a href=\"#JDWP_VirtualMachine_CapabilitiesNew\">CapabilitiesNew</a>." 3080 3081 (int requestID "Request that generated event") 3082 (threadObject thread "Modifying thread") 3083 (location location "Location of modify") 3084 (byte refTypeTag "Kind of reference type. " 3085 "See <a href=\"#JDWP_TypeTag\">JDWP.TypeTag</a>") 3086 (referenceTypeID typeID "Type of field") 3087 (field fieldID "Field being modified") 3088 (tagged-object object 3089 "Object being modified (null=0 for statics") 3090 (value valueToBe "Value to be assigned") 3091 ) 3092 (Alt VMDeath=JDWP.EventKind.VM_DEATH 3093 (int requestID 3094 "Request that generated event") 3095 ) 3096 ) 3097 ) 3098 ) 3099 ) 3100 ) 3101 (ConstantSet Error 3102 (Constant NONE =0 "No error has occurred.") 3103 (Constant INVALID_THREAD =10 "Passed thread is null, is not a valid thread or has exited.") 3104 (Constant INVALID_THREAD_GROUP =11 "Thread group invalid.") 3105 (Constant INVALID_PRIORITY =12 "Invalid priority.") 3106 (Constant THREAD_NOT_SUSPENDED =13 "If the specified thread has not been " 3107 "suspended by an event.") 3108 (Constant THREAD_SUSPENDED =14 "Thread already suspended.") 3109 (Constant THREAD_NOT_ALIVE =15 "Thread has not been started or is now dead.") 3110 3111 (Constant INVALID_OBJECT =20 "If this reference type has been unloaded " 3112 "and garbage collected.") 3113 (Constant INVALID_CLASS =21 "Invalid class.") 3114 (Constant CLASS_NOT_PREPARED =22 "Class has been loaded but not yet prepared.") 3115 (Constant INVALID_METHODID =23 "Invalid method.") 3116 (Constant INVALID_LOCATION =24 "Invalid location.") 3117 (Constant INVALID_FIELDID =25 "Invalid field.") 3118 (Constant INVALID_FRAMEID =30 "Invalid jframeID.") 3119 (Constant NO_MORE_FRAMES =31 "There are no more Java or JNI frames on the " 3120 "call stack.") 3121 (Constant OPAQUE_FRAME =32 "Information about the frame is not available.") 3122 (Constant NOT_CURRENT_FRAME =33 "Operation can only be performed on current frame.") 3123 (Constant TYPE_MISMATCH =34 "The variable is not an appropriate type for " 3124 "the function used.") 3125 (Constant INVALID_SLOT =35 "Invalid slot.") 3126 (Constant DUPLICATE =40 "Item already set.") 3127 (Constant NOT_FOUND =41 "Desired element not found.") 3128 (Constant INVALID_MODULE =42 "Invalid module.") 3129 (Constant INVALID_MONITOR =50 "Invalid monitor.") 3130 (Constant NOT_MONITOR_OWNER =51 "This thread doesn't own the monitor.") 3131 (Constant INTERRUPT =52 "The call has been interrupted before completion.") 3132 (Constant INVALID_CLASS_FORMAT =60 "The virtual machine attempted to read a class " 3133 "file and determined that the file is malformed " 3134 "or otherwise cannot be interpreted as a class file.") 3135 (Constant CIRCULAR_CLASS_DEFINITION 3136 =61 "A circularity has been detected while " 3137 "initializing a class.") 3138 (Constant FAILS_VERIFICATION =62 "The verifier detected that a class file, " 3139 "though well formed, contained some sort of " 3140 "internal inconsistency or security problem.") 3141 (Constant ADD_METHOD_NOT_IMPLEMENTED 3142 =63 "Adding methods has not been implemented.") 3143 (Constant SCHEMA_CHANGE_NOT_IMPLEMENTED 3144 =64 "Schema change has not been implemented.") 3145 (Constant INVALID_TYPESTATE =65 "The state of the thread has been modified, " 3146 "and is now inconsistent.") 3147 (Constant HIERARCHY_CHANGE_NOT_IMPLEMENTED 3148 =66 "A direct superclass is different for the new class " 3149 "version, or the set of directly implemented " 3150 "interfaces is different " 3151 "and canUnrestrictedlyRedefineClasses is false.") 3152 (Constant DELETE_METHOD_NOT_IMPLEMENTED 3153 =67 "The new class version does not declare a method " 3154 "declared in the old class version " 3155 "and canUnrestrictedlyRedefineClasses is false.") 3156 (Constant UNSUPPORTED_VERSION =68 "A class file has a version number not supported " 3157 "by this VM.") 3158 (Constant NAMES_DONT_MATCH =69 "The class name defined in the new class file is " 3159 "different from the name in the old class object.") 3160 (Constant CLASS_MODIFIERS_CHANGE_NOT_IMPLEMENTED 3161 =70 "The new class version has different modifiers and " 3162 "canUnrestrictedlyRedefineClasses is false.") 3163 (Constant METHOD_MODIFIERS_CHANGE_NOT_IMPLEMENTED 3164 =71 "A method in the new class version has " 3165 "different modifiers " 3166 "than its counterpart in the old class version and " 3167 "canUnrestrictedlyRedefineClasses is false.") 3168 (Constant CLASS_ATTRIBUTE_CHANGE_NOT_IMPLEMENTED 3169 =72 "The new class version has a different NestHost, " 3170 "NestMembers, or Record class attribute and " 3171 "canUnrestrictedlyRedefineClasses is false.") 3172 (Constant NOT_IMPLEMENTED =99 "The functionality is not implemented in " 3173 "this virtual machine.") 3174 (Constant NULL_POINTER =100 "Invalid pointer.") 3175 (Constant ABSENT_INFORMATION =101 "Desired information is not available.") 3176 (Constant INVALID_EVENT_TYPE =102 "The specified event type id is not recognized.") 3177 (Constant ILLEGAL_ARGUMENT =103 "Illegal argument.") 3178 (Constant OUT_OF_MEMORY =110 "The function needed to allocate memory and " 3179 "no more memory was available for allocation.") 3180 (Constant ACCESS_DENIED =111 "Debugging has not been enabled in this " 3181 "virtual machine. JVMTI cannot be used.") 3182 (Constant VM_DEAD =112 "The virtual machine is not running.") 3183 (Constant INTERNAL =113 "An unexpected internal error has occurred.") 3184 (Constant UNATTACHED_THREAD =115 "The thread being used to call this function " 3185 "is not attached to the virtual machine. " 3186 "Calls must be made from attached threads.") 3187 (Constant INVALID_TAG =500 "object type id or class tag.") 3188 (Constant ALREADY_INVOKING =502 "Previous invoke not complete.") 3189 (Constant INVALID_INDEX =503 "Index is invalid.") 3190 (Constant INVALID_LENGTH =504 "The length is invalid.") 3191 (Constant INVALID_STRING =506 "The string is invalid.") 3192 (Constant INVALID_CLASS_LOADER =507 "The class loader is invalid.") 3193 (Constant INVALID_ARRAY =508 "The array is invalid.") 3194 (Constant TRANSPORT_LOAD =509 "Unable to load the transport.") 3195 (Constant TRANSPORT_INIT =510 "Unable to initialize the transport.") 3196 (Constant NATIVE_METHOD =511 ) 3197 (Constant INVALID_COUNT =512 "The count is invalid.") 3198 ) 3199 (ConstantSet EventKind 3200 (Constant SINGLE_STEP =1 ) 3201 (Constant BREAKPOINT =2 ) 3202 (Constant FRAME_POP =3 ) 3203 (Constant EXCEPTION =4 ) 3204 (Constant USER_DEFINED =5 ) 3205 (Constant THREAD_START =6 ) 3206 (Constant THREAD_DEATH =7 ) 3207 (Constant THREAD_END =7 "obsolete - was used in jvmdi") 3208 (Constant CLASS_PREPARE =8 ) 3209 (Constant CLASS_UNLOAD =9 ) 3210 (Constant CLASS_LOAD =10 ) 3211 (Constant FIELD_ACCESS =20 ) 3212 (Constant FIELD_MODIFICATION =21 ) 3213 (Constant EXCEPTION_CATCH =30 ) 3214 (Constant METHOD_ENTRY =40 ) 3215 (Constant METHOD_EXIT =41 ) 3216 (Constant METHOD_EXIT_WITH_RETURN_VALUE =42 ) 3217 (Constant MONITOR_CONTENDED_ENTER =43 ) 3218 (Constant MONITOR_CONTENDED_ENTERED =44 ) 3219 (Constant MONITOR_WAIT =45 ) 3220 (Constant MONITOR_WAITED =46 ) 3221 (Constant VM_START =90 ) 3222 (Constant VM_INIT =90 "obsolete - was used in jvmdi") 3223 (Constant VM_DEATH =99 ) 3224 (Constant VM_DISCONNECTED =100 "Never sent across JDWP") 3225 ) 3226 3227 (ConstantSet ThreadStatus 3228 (Constant ZOMBIE =0 ) 3229 (Constant RUNNING =1 ) 3230 (Constant SLEEPING =2 ) 3231 (Constant MONITOR =3 ) 3232 (Constant WAIT =4 ) 3233 ) 3234 3235 (ConstantSet SuspendStatus 3236 (Constant SUSPEND_STATUS_SUSPENDED = 0x1 ) 3237 ) 3238 (ConstantSet ClassStatus 3239 (Constant VERIFIED =1 ) 3240 (Constant PREPARED =2 ) 3241 (Constant INITIALIZED =4 ) 3242 (Constant ERROR =8 ) 3243 ) 3244 (ConstantSet TypeTag 3245 (Constant CLASS=1 "ReferenceType is a class. ") 3246 (Constant INTERFACE=2 "ReferenceType is an interface. ") 3247 (Constant ARRAY=3 "ReferenceType is an array. ") 3248 ) 3249 (ConstantSet Tag 3250 (Constant ARRAY = '[' "'[' - an array object (objectID size). ") 3251 (Constant BYTE = 'B' "'B' - a byte value (1 byte).") 3252 (Constant CHAR = 'C' "'C' - a character value (2 bytes).") 3253 (Constant OBJECT = 'L' "'L' - an object (objectID size).") 3254 (Constant FLOAT = 'F' "'F' - a float value (4 bytes).") 3255 (Constant DOUBLE = 'D' "'D' - a double value (8 bytes).") 3256 (Constant INT = 'I' "'I' - an int value (4 bytes).") 3257 (Constant LONG = 'J' "'J' - a long value (8 bytes).") 3258 (Constant SHORT = 'S' "'S' - a short value (2 bytes).") 3259 (Constant VOID = 'V' "'V' - a void value (no bytes).") 3260 (Constant BOOLEAN = 'Z' "'Z' - a boolean value (1 byte).") 3261 (Constant STRING = 's' "'s' - a String object (objectID size). ") 3262 (Constant THREAD = 't' "'t' - a Thread object (objectID size). ") 3263 (Constant THREAD_GROUP = 'g' 3264 "'g' - a ThreadGroup object (objectID size). ") 3265 (Constant CLASS_LOADER = 'l' 3266 "'l' - a ClassLoader object (objectID size). ") 3267 (Constant CLASS_OBJECT = 'c' 3268 "'c' - a class object object (objectID size). ") 3269 ) 3270 3271 (ConstantSet StepDepth 3272 (Constant INTO = 0 3273 "Step into any method calls that occur before the end of the step. ") 3274 (Constant OVER = 1 3275 "Step over any method calls that occur before the end of the step. ") 3276 (Constant OUT = 2 3277 "Step out of the current method. ") 3278 ) 3279 3280 (ConstantSet StepSize 3281 (Constant MIN = 0 3282 "Step by the minimum possible amount (often a bytecode instruction). ") 3283 (Constant LINE = 1 3284 "Step to the next source line unless there is no line number information in which case a MIN step is done instead.") 3285 ) 3286 3287 (ConstantSet SuspendPolicy 3288 (Constant NONE = 0 3289 "Suspend no threads when this event is encountered. ") 3290 (Constant EVENT_THREAD = 1 3291 "Suspend the event thread when this event is encountered. ") 3292 (Constant ALL = 2 3293 "Suspend all threads when this event is encountered. ") 3294 ) 3295 3296 (ConstantSet InvokeOptions 3297 "The invoke options are a combination of zero or more of the following bit flags:" 3298 (Constant INVOKE_SINGLE_THREADED = 0x01 3299 "otherwise, all threads started. ") 3300 (Constant INVOKE_NONVIRTUAL = 0x02 3301 "otherwise, normal virtual invoke (instance methods only)") 3302 )