Contents Previous Next

Chapter   2

VirtualMachine Command Set


This command set is numbered (1) to match the equivalent JDWP command set.

 AllClasses Command (3)

Returns reference types for all classes currently loaded by the target VM.

Out Data

(None)

Reply Data
TABLE 2  –  Structure of Reply Data for AllClasses Command
int
classes
Number of reference types that follow. 
Repeated classes times:
byte
refTypeTag
Kind of following reference type.  
referenceTypeID
typeID
Loaded reference type 
string
signature
The JNI signature of the loaded reference type 
int
status
The current class status.  

 AllThreads Command (4)

Returns all threads currently running in the target VM. The returned list contains threads created through java.lang.Thread. Threads that have not yet been started and threads that have completed their execution are not included in the returned list.

Out Data

(None)

Reply Data
TABLE 3  –  Structure of Reply Data for AllThreads Command
int
threads
Number of threads that follow. 
Repeated threads times:
threadID
thread
A running thread 

 Suspend Command (8)

Suspends the execution of the application running in the target VM. All Java threads currently running are suspended.

Unlike java.lang.Thread.suspend, suspends of both the virtual machine and individual threads are counted. Before a thread can run again, it must be resumed through the VM-level suspend command or the thread-level suspend command the same number of times it has been suspended.

Out Data

(None)

Reply Data

(None)

 Resume Command (9)

Resumes execution of the application after the suspend command or an event has stopped it. Suspensions of the Virtual Machine and individual threads are counted. If a particular thread is suspended n times, it must be resumed n times before it can continue.

Out Data

(None)

Reply Data

(None)

 Exit Command (10)

Terminates the target VM with the given exit code. All ids previously returned from the target VM become invalid. Threads running in the VM are abruptly terminated. A thread death exception is not thrown and finally blocks are not run.

Out Data
TABLE 4  –  Structure of Out Data for Exit Command
int
exitCode
The exit code 

Reply Data

(None)

 


Contents Previous Next KDWP Specification
KVM Debug Wire Protocol, 1.0