Classes | |
union | ConstPoolEntry |
The constant pool entry descriptor. More... | |
struct | ConstantPool |
The constant pool of a class and related operations. More... | |
struct | Class |
VM representation of Java class. More... | |
struct | Class.Class_Super |
struct | Class.InnerClass |
Defines | |
#define | CLASSFILE_MAGIC 0xCAFEBABE |
#define | CLASSFILE_MAJOR_MIN 45 |
#define | CLASSFILE_MAJOR_MAX 50 |
#define | CLASSFILE_MINOR_MAX 0 |
Enumerations | |
enum | ConstPoolTags { CONSTANT_Tags = 0, CONSTANT_Utf8 = 1, CONSTANT_Integer = 3, CONSTANT_Float = 4, CONSTANT_Long = 5, CONSTANT_Double = 6, CONSTANT_Class = 7, CONSTANT_String = 8, CONSTANT_Fieldref = 9, CONSTANT_Methodref = 10, CONSTANT_InterfaceMethodref = 11, CONSTANT_NameAndType = 12, CONSTANT_Last = CONSTANT_NameAndType, CONSTANT_UnusedEntry = CONSTANT_Last + 1 } |
Types of constant pool entries. More... | |
enum | Class_State { ST_Start, ST_LoadingAncestors, ST_Loaded, ST_BytecodesVerified, ST_InstanceSizeComputed, ST_Prepared, ST_ConstraintsVerified, ST_Initializing, ST_Initialized, ST_Error } |
The state of the Java class. More... | |
enum | AccessAndPropertiesFlags { ACC_PUBLIC = 0x0001, ACC_PRIVATE = 0x0002, ACC_PROTECTED = 0x0004, ACC_STATIC = 0x0008, ACC_FINAL = 0x0010, ACC_SUPER = 0x0020, ACC_SYNCHRONIZED = 0x0020, ACC_BRIDGE = 0x0040, ACC_VOLATILE = 0x0040, ACC_VARARGS = 0x0080, ACC_TRANSIENT = 0x0080, ACC_NATIVE = 0x0100, ACC_INTERFACE = 0x0200, ACC_ABSTRACT = 0x0400, ACC_STRICT = 0x0800, ACC_SYNTHETIC = 0x1000, ACC_ANNOTATION = 0x2000, ACC_ENUM = 0x4000 } |
Access and properties flags for Class, Field and Method. More... | |
Functions | |
VMEXPORT String * | class_name_get_java_name (const String *class_name) |
Converts a class name from an internal (VM) form to the Java form. | |
ManagedObject * | struct_Class_to_java_lang_Class (Class *clss) |
Gets instance of java/lang/Class associated with this class. | |
jclass | struct_Class_to_jclass (Class *clss) |
Gets handle of java/lang/Class instance associated with this class. | |
Class * | jclass_to_struct_Class (jclass jc) |
Gets native class from the java/lang/Class handle. | |
Class * | jobject_to_struct_Class (jobject jobj) |
Gets native class for any given object handle. | |
jobject | struct_Class_to_java_lang_Class_Handle (Class *clss) |
Gets pointer to instance of java/lang/Class associated with the class. | |
Class * | java_lang_Class_to_struct_Class (ManagedObject *jlc) |
Gets native class from instance of java/lang/Class. | |
Field * | class_lookup_field_recursive (Class *clss, const char *name, const char *desc) |
Looks up field in class and its superclasses. | |
VMEXPORT Method * | class_lookup_method_recursive (Class *clss, const String *name, const String *desc) |
Looks up method in class and its superclasses. | |
Method * | class_lookup_method_recursive (Class *clss, const char *name, const char *desc) |
Looks up method in class and its superclasses. | |
Method * | class_lookup_method (Class *clss, const char *name, const char *desc) |
Looks up method in the given class only. | |
Method * | class_get_method_from_vt_offset (VTable *vt, unsigned offset) |
Gets method given its offset in the vtable. | |
Field * | class_resolve_nonstatic_field (Class *clss, unsigned cp_index) |
Resolves non-static field at the specified index in the constant pool of the class. | |
Class * | class_load_verify_prepare_by_loader_jni (Global_Env *env, const String *classname, ClassLoader *cl) |
Loads a class and performs the first two parts of the link process: verify and prepare. | |
Class * | class_load_verify_prepare_from_jni (Global_Env *env, const String *classname) |
Loads a class with bootstrap class loader and performs the first two parts of the link process: verify and prepare. | |
void | class_initialize_from_jni (Class *clss) |
Executes static initializer of class. | |
void | class_initialize_ex (Class *clss) |
Executes static initializer of class. | |
VMEXPORT void | class_initialize (Class *clss) |
Executes static initializer of class. | |
bool | class_register_methods (Class_Handle klass, const JNINativeMethod *methods, int num_methods) |
Registers a number of native methods to a given class. | |
bool | class_unregister_methods (Class_Handle klass) |
Unregisters a native methods off a given class. | |
Class * | resolve_class_new_env (Global_Env *env, Class *clss, unsigned cp_index, bool raise_exn) |
Method * | resolve_special_method_env (Global_Env *env, Class_Handle curr_clss, unsigned index, bool raise_exn) |
Method * | resolve_static_method_env (Global_Env *env, Class *clss, unsigned cp_index, bool raise_exn) |
Method * | resolve_virtual_method_env (Global_Env *env, Class *clss, unsigned cp_index, bool raise_exn) |
Method * | resolve_interface_method_env (Global_Env *env, Class *clss, unsigned cp_index, bool raise_exn) |
Field * | resolve_static_field_env (Global_Env *env, Class *clss, unsigned cp_index, bool putfield, bool is_runtume) |
Field * | resolve_nonstatic_field_env (Global_Env *env, Class *clss, unsigned cp_index, unsigned putfield, bool raise_exn) |
#define CLASSFILE_MAGIC 0xCAFEBABE |
#define CLASSFILE_MAJOR_MIN 45 |
#define CLASSFILE_MAJOR_MAX 50 |
#define CLASSFILE_MINOR_MAX 0 |
enum ConstPoolTags |
Types of constant pool entries.
These entry types are defined by a seperate byte array that the first constant pool entry points at.
CONSTANT_Tags |
pointer to the tags array.
|
CONSTANT_Utf8 |
The next 11 tag values are taken from The Java Virtual Machine Specification, Chapter 4, The Constant Pool section.
|
CONSTANT_Integer | |
CONSTANT_Float | |
CONSTANT_Long | |
CONSTANT_Double | |
CONSTANT_Class | |
CONSTANT_String | |
CONSTANT_Fieldref | |
CONSTANT_Methodref | |
CONSTANT_InterfaceMethodref | |
CONSTANT_NameAndType | |
CONSTANT_Last | |
CONSTANT_UnusedEntry | used to mark second entry of Long and Double |
enum Class_State |
The state of the Java class.
Access and properties flags for Class, Field and Method.
ACC_PUBLIC | Public access modifier. |
ACC_PRIVATE | Private access modifier. |
ACC_PROTECTED | Protected access modifier. |
ACC_STATIC | Static modifier. |
ACC_FINAL | Final modifier. |
ACC_SUPER |
Super modifier.
Valid for Class. |
ACC_SYNCHRONIZED |
Synchronized modifier.
Valid for Method. |
ACC_BRIDGE |
Bridge modifier.
Valid for Method (since J2SE 5.0). |
ACC_VOLATILE |
Volatile modifier.
Valid for Field. |
ACC_VARARGS |
Varargs modifier.
Valid for Method (since J2SE 5.0). |
ACC_TRANSIENT |
Transient modifier.
Valid for Field. |
ACC_NATIVE |
Native modifier.
Valid for Method. |
ACC_INTERFACE |
Interface modifier.
Valid for Class. |
ACC_ABSTRACT | Abstract modifier. |
ACC_STRICT |
Strict modifier.
Valid for Method. |
ACC_SYNTHETIC | Synthetic modifier. |
ACC_ANNOTATION |
Annotation modifier.
Valid for Class (since J2SE 5.0). |
ACC_ENUM | Enum modifier. |
Converts a class name from an internal (VM) form to the Java form.
[in] | class_name | - the class name in an internal form |
ManagedObject* struct_Class_to_java_lang_Class | ( | Class * | clss | ) |
Gets instance of java/lang/Class associated with this class.
[in] | clss | - class to retrieve java/lang/Class instance for. |
Gets handle of java/lang/Class instance associated with this class.
[in] | clss | - class to retrieve handle with java/lang/Class instance for. |
Gets native class for any given object handle.
[in] | jobj | - object to retrieve class for. |
Gets pointer to instance of java/lang/Class associated with the class.
[in] | clss | - class to retrieve pointer to instance of java/lang/Class for. |
Class* java_lang_Class_to_struct_Class | ( | ManagedObject * | jlc | ) |
Gets native class from instance of java/lang/Class.
[in] | jlc | - instance of java/lang/Class to retrieve class from. |
Looks up field in class and its superclasses.
[in] | clss | - class to lookup field in. |
[in] | name | - name of the field. |
[in] | desc | - descriptor of the field. |
NULL
otherwise. VMEXPORT Method* class_lookup_method_recursive | ( | Class * | clss, | |
const String * | name, | |||
const String * | desc | |||
) |
Looks up method in class and its superclasses.
[in] | clss | - class to lookup method in. |
[in] | name | - name of the method as VM String. |
[in] | desc | - descriptor of the method as VM String. |
NULL
otherwise. Looks up method in class and its superclasses.
[in] | clss | - class to lookup method in. |
[in] | name | - name of the method. |
[in] | desc | - descriptor of the method. |
NULL
otherwise. Looks up method in the given class only.
[in] | clss | - class to lookup method in. |
[in] | name | - name of the method. |
[in] | desc | - descriptor of the method. |
NULL
otherwise. Gets method given its offset in the vtable.
[in] | vt | - vtable containing method. |
[in] | offset | - offset of the method in the vtable. |
Resolves non-static field at the specified index in the constant pool of the class.
[in] | clss | - class to resolve field in. |
[in] | cp_index | - index in the constant pool of the class. |
NULL
otherwise. Class* class_load_verify_prepare_by_loader_jni | ( | Global_Env * | env, | |
const String * | classname, | |||
ClassLoader * | cl | |||
) |
Loads a class and performs the first two parts of the link process: verify and prepare.
[in] | env | - VM environment. |
[in] | classname | - name of a class to load. |
[in] | cl | - class loader to load class with. |
NULL
otherwise. Class* class_load_verify_prepare_from_jni | ( | Global_Env * | env, | |
const String * | classname | |||
) |
Loads a class with bootstrap class loader and performs the first two parts of the link process: verify and prepare.
[in] | env | - VM environment. |
[in] | classname | - name of a class to load. |
[in] | cl | - class loader to load class with. |
NULL
otherwise. void class_initialize_from_jni | ( | Class * | clss | ) |
Executes static initializer of class.
[in] | clss | - class to initialize. |
void class_initialize_ex | ( | Class * | clss | ) |
Executes static initializer of class.
[in] | clss | - class to initialize. |
VMEXPORT void class_initialize | ( | Class * | clss | ) |
Executes static initializer of class.
[in] | clss | - class to initialize. |
bool class_register_methods | ( | Class_Handle | klass, | |
const JNINativeMethod * | methods, | |||
int | num_methods | |||
) |
Registers a number of native methods to a given class.
[in] | klass | - a specified class |
[in] | methods | - an array of methods |
[in] | num_methods | - a number of methods |
false
, if methods resistration is successful; otherwise true
. NoSuchMethodError
with the method name in exception message, if one of the methods in the JNINativeMethod*
array is not present in a specified class. bool class_unregister_methods | ( | Class_Handle | klass | ) |
Unregisters a native methods off a given class.
[in] | klass | - specified class |
false
, if methods unresistration is successful; otherwise true
. Class* resolve_class_new_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
bool | raise_exn | |||
) |
Method* resolve_special_method_env | ( | Global_Env * | env, | |
Class_Handle | curr_clss, | |||
unsigned | index, | |||
bool | raise_exn | |||
) |
Method* resolve_static_method_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
bool | raise_exn | |||
) |
Method* resolve_virtual_method_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
bool | raise_exn | |||
) |
Method* resolve_interface_method_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
bool | raise_exn | |||
) |
Field* resolve_static_field_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
bool | putfield, | |||
bool | is_runtume | |||
) |
Field* resolve_nonstatic_field_env | ( | Global_Env * | env, | |
Class * | clss, | |||
unsigned | cp_index, | |||
unsigned | putfield, | |||
bool | raise_exn | |||
) |
Genereated on Tue Mar 11 19:25:56 2008 by Doxygen.
(c) Copyright 2005, 2008 The Apache Software Foundation or its licensors, as applicable.