1 /* src/native/vm/VMVirtualMachine.c - jdwp->jvmti interface
3 Copyright (C) 1996-2005 R. Grafl, A. Krall, C. Kruegel, C. Oates,
4 R. Obermaisser, M. Platter, M. Probst, S. Ring, E. Steiner,
5 C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich, J. Wenninger,
6 Institut f. Computersprachen - TU Wien
8 This file is part of CACAO.
10 This program is free software; you can redistribute it and/or
11 modify it under the terms of the GNU General Public License as
12 published by the Free Software Foundation; either version 2, or (at
13 your option) any later version.
15 This program is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
25 Contact: cacao@complang.tuwien.ac.at
27 Authors: Martin Platter
32 $Id: VMVirtualMachine.c 3593 2005-11-06 16:16:07Z motse $
36 #include "toolbox/logging.h"
37 #include "native/jni.h"
38 #include "native/include/java_lang_Thread.h"
39 #include "native/include/java_nio_ByteBuffer.h"
40 #include "native/include/java_lang_Class.h"
41 #include "native/include/java_lang_ClassLoader.h"
42 #include "native/include/java_lang_reflect_Method.h"
43 #include "native/include/gnu_classpath_jdwp_event_EventRequest.h"
44 #include "native/include/gnu_classpath_jdwp_VMVirtualMachine.h"
45 #include "native/jvmti/jvmti.h"
49 * Class: gnu_classpath_jdwp_VMVirtualMachine
50 * Method: suspendThread
51 * Signature: (Ljava/lang/Thread;)V
53 JNIEXPORT void JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_suspendThread(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1)
55 remotedbgjvmtienv->SuspendThread(remotedbgjvmtienv, (jthread) par1);
59 * Class: gnu_classpath_jdwp_VMVirtualMachine
60 * Method: resumeThread
61 * Signature: (Ljava/lang/Thread;)V
63 JNIEXPORT void JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_resumeThread(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1)
65 remotedbgjvmtienv->ResumeThread(remotedbgjvmtienv, (jthread) par1);
70 * Class: gnu_classpath_jdwp_VMVirtualMachine
71 * Method: getSuspendCount
72 * Signature: (Ljava/lang/Thread;)I
74 JNIEXPORT s4 JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getSuspendCount(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1) {
75 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
80 * Class: gnu_classpath_jdwp_VMVirtualMachine
81 * Method: getAllLoadedClassesCount
84 JNIEXPORT s4 JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getAllLoadedClassesCount(JNIEnv *env, jclass clazz) {
88 remotedbgjvmtienv->GetLoadedClasses(remotedbgjvmtienv, &count, &classes);
92 /* Class: gnu/classpath/jdwp/VMVirtualMachine
93 * Method: getClassStatus
94 * Signature: (Ljava/lang/Class;)I
96 JNIEXPORT s4 JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getClassStatus(JNIEnv *env, jclass clazz, struct java_lang_Class* par1) {
97 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
103 * Class: gnu/classpath/jdwp/VMVirtualMachine
105 * Signature: (Ljava/lang/Thread;II)Ljava/util/ArrayList;
107 JNIEXPORT struct java_util_ArrayList* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getFrames(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1, s4 par2, s4 par3) {
108 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
114 * Class: gnu/classpath/jdwp/VMVirtualMachine
116 * Signature: (Ljava/lang/Thread;Ljava/nio/ByteBuffer;)Lgnu/classpath/jdwp/VMFrame;
118 JNIEXPORT struct gnu_classpath_jdwp_VMFrame* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getFrame(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1, struct java_nio_ByteBuffer* par2) {
119 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
125 * Class: gnu/classpath/jdwp/VMVirtualMachine
126 * Method: getFrameCount
127 * Signature: (Ljava/lang/Thread;)I
129 JNIEXPORT s4 JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getFrameCount(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1) {
130 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
136 * Class: gnu/classpath/jdwp/VMVirtualMachine
137 * Method: getThreadStatus
138 * Signature: (Ljava/lang/Thread;)I
140 JNIEXPORT s4 JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getThreadStatus(JNIEnv *env, jclass clazz, struct java_lang_Thread* par1) {
141 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
147 * Class: gnu/classpath/jdwp/VMVirtualMachine
148 * Method: getLoadRequests
149 * Signature: (Ljava/lang/ClassLoader;)Ljava/util/ArrayList;
151 JNIEXPORT struct java_util_ArrayList* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getLoadRequests(JNIEnv *env, jclass clazz, struct java_lang_ClassLoader* par1) {
152 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
158 * Class: gnu/classpath/jdwp/VMVirtualMachine
159 * Method: executeMethod
160 * Signature: (Ljava/lang/Object;Ljava/lang/Thread;Ljava/lang/Class;Ljava/lang/reflect/Method;[Ljava/lang/Object;Z)Lgnu/classpath/jdwp/util/MethodResult;
162 JNIEXPORT struct gnu_classpath_jdwp_util_MethodResult* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_executeMethod(JNIEnv *env, jclass clazz, struct java_lang_Object* par1, struct java_lang_Thread* par2, struct java_lang_Class* par3, struct java_lang_reflect_Method* par4, java_objectarray* par5, s4 par6) {
163 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
169 * Class: gnu/classpath/jdwp/VMVirtualMachine
170 * Method: getVarTable
171 * Signature: (Ljava/lang/Class;Ljava/lang/reflect/Method;)Lgnu/classpath/jdwp/util/VariableTable;
173 JNIEXPORT struct gnu_classpath_jdwp_util_VariableTable* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getVarTable(JNIEnv *env, jclass clazz, struct java_lang_Class* par1, struct java_lang_reflect_Method* par2) {
174 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
180 * Class: gnu/classpath/jdwp/VMVirtualMachine
181 * Method: getLineTable
182 * Signature: (Ljava/lang/Class;Ljava/lang/reflect/Method;)Lgnu/classpath/jdwp/util/LineTable;
184 JNIEXPORT struct gnu_classpath_jdwp_util_LineTable* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getLineTable(JNIEnv *env, jclass clazz, struct java_lang_Class* par1, struct java_lang_reflect_Method* par2) {
185 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
191 * Class: gnu/classpath/jdwp/VMVirtualMachine
192 * Method: getSourceFile
193 * Signature: (Ljava/lang/Class;)Ljava/lang/String;
195 JNIEXPORT struct java_lang_String* JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_getSourceFile(JNIEnv *env, jclass clazz, struct java_lang_Class* par1) {
196 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
202 * Class: gnu/classpath/jdwp/VMVirtualMachine
203 * Method: registerEvent
204 * Signature: (Lgnu/classpath/jdwp/event/EventRequest;)V
206 JNIEXPORT void JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_registerEvent(JNIEnv *env, jclass clazz, struct gnu_classpath_jdwp_event_EventRequest* par1) {
207 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
212 * Class: gnu/classpath/jdwp/VMVirtualMachine
213 * Method: unregisterEvent
214 * Signature: (Lgnu/classpath/jdwp/event/EventRequest;)V
216 JNIEXPORT void JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_unregisterEvent(JNIEnv *env, jclass clazz, struct gnu_classpath_jdwp_event_EventRequest* par1) {
217 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
222 * Class: gnu/classpath/jdwp/VMVirtualMachine
223 * Method: clearEvents
226 JNIEXPORT void JNICALL Java_gnu_classpath_jdwp_VMVirtualMachine_clearEvents(JNIEnv *env, jclass clazz, s4 par1) {
227 log_text ("JVMTI-Call: IMPLEMENT ME!!!");
232 * These are local overrides for various environment variables in Emacs.
233 * Please do not remove this and leave it at the end of the file, where
234 * Emacs will automagically detect them.
235 * ---------------------------------------------------------------------
238 * indent-tabs-mode: t