ff2db150522dad0f7ac9f8331435491e24ee9f09
[cacao.git] / src / native / vm / java_lang_Class.h
1 /* src/native/vm/java_lang_Class.h - java/lang/Class functions
2
3    Copyright (C) 2006 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
7
8    This file is part of CACAO.
9
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.
14
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.
19
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., 51 Franklin Street, Fifth Floor, Boston, MA
23    02110-1301, USA.
24
25    Contact: cacao@cacaojvm.org
26
27    Authors: Christian Thalinger
28
29    $Id: java_lang_VMClass.c 6131 2006-12-06 22:15:57Z twisti $
30
31 */
32
33
34 #ifndef _JV_JAVA_LANG_CLASS_H
35 #define _JV_JAVA_LANG_CLASS_H
36
37 #include "config.h"
38 #include "vm/types.h"
39
40 #include "native/jni.h"
41 #include "native/include/java_lang_Class.h"
42 #include "native/include/java_lang_ClassLoader.h"
43 #include "native/include/java_lang_Object.h"
44 #include "native/include/java_lang_String.h"
45 #include "native/include/java_lang_Throwable.h"
46 #include "native/include/java_lang_reflect_Constructor.h"
47 #include "native/include/java_lang_reflect_Method.h"
48
49
50 /* function prototypes ********************************************************/
51
52 s4                             _Jv_java_lang_Class_isInstance(java_lang_Class *klass, java_lang_Object *o);
53 s4                             _Jv_java_lang_Class_isAssignableFrom(java_lang_Class *klass, java_lang_Class *c);
54 s4                             _Jv_java_lang_Class_isInterface(java_lang_Class *klass);
55 s4                             _Jv_java_lang_Class_isPrimitive(java_lang_Class *klass);
56 java_lang_String              *_Jv_java_lang_Class_getName(java_lang_Class *klass);
57 java_lang_Class               *_Jv_java_lang_Class_getSuperclass(java_lang_Class *klass);
58 java_objectarray              *_Jv_java_lang_Class_getInterfaces(java_lang_Class *klass);
59 java_lang_Class               *_Jv_java_lang_Class_getComponentType(java_lang_Class *klass);
60 s4                             _Jv_java_lang_Class_getModifiers(java_lang_Class *klass, s4 ignoreInnerClassesAttrib);
61 java_lang_Class               *_Jv_java_lang_Class_getDeclaringClass(java_lang_Class *klass);
62 java_objectarray              *_Jv_java_lang_Class_getDeclaredClasses(java_lang_Class *klass, s4 publicOnly);
63 java_objectarray              *_Jv_java_lang_Class_getDeclaredFields(java_lang_Class *klass, s4 publicOnly);
64 java_objectarray              *_Jv_java_lang_Class_getDeclaredMethods(java_lang_Class *klass, s4 publicOnly);
65 java_objectarray              *_Jv_java_lang_Class_getDeclaredConstructors(java_lang_Class *klass, s4 publicOnly);
66 java_lang_ClassLoader         *_Jv_java_lang_Class_getClassLoader(java_lang_Class *klass);
67 java_lang_Class               *_Jv_java_lang_Class_forName(java_lang_String *name, s4 initialize, java_lang_ClassLoader *loader);
68 s4                             _Jv_java_lang_Class_isArray(java_lang_Class *klass);
69 void                           _Jv_java_lang_Class_throwException(java_lang_Throwable *t);
70
71 #if 0
72 java_objectarray              *_Jv_java_lang_Class_getDeclaredAnnotations(java_lang_Class* klass);
73 #endif
74
75 java_lang_Class               *_Jv_java_lang_Class_getEnclosingClass(java_lang_Class *klass);
76 java_lang_reflect_Constructor *_Jv_java_lang_Class_getEnclosingConstructor(java_lang_Class *klass);
77 java_lang_reflect_Method      *_Jv_java_lang_Class_getEnclosingMethod(java_lang_Class *klass);
78
79 java_lang_String              *_Jv_java_lang_Class_getClassSignature(java_lang_Class* klass);
80
81 #if 0
82 s4                             _Jv_java_lang_Class_isAnonymousClass(JNIEnv *env, jclass clazz, struct java_lang_Class* par1);
83 JNIEXPORT s4 JNICALL Java_java_lang_VMClass_isLocalClass(JNIEnv *env, jclass clazz, struct java_lang_Class* par1);
84 JNIEXPORT s4 JNICALL Java_java_lang_VMClass_isMemberClass(JNIEnv *env, jclass clazz, struct java_lang_Class* par1);
85 #endif
86
87 #endif /* _JV_JAVA_LANG_CLASS_H */
88
89
90 /*
91  * These are local overrides for various environment variables in Emacs.
92  * Please do not remove this and leave it at the end of the file, where
93  * Emacs will automagically detect them.
94  * ---------------------------------------------------------------------
95  * Local variables:
96  * mode: c
97  * indent-tabs-mode: t
98  * c-basic-offset: 4
99  * tab-width: 4
100  * End:
101  * vim:noexpandtab:sw=4:ts=4:
102  */