*/
JNIEXPORT int32_t JNICALL Java_sun_reflect_ConstantPool_getSize0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool)
{
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
return cls->cpcount;
}
JNIEXPORT struct java_lang_Class* JNICALL Java_sun_reflect_ConstantPool_getClassAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_classref *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_classref*)class_getconstant(
cls, index, CONSTANT_Class);
return NULL;
}
- return (jclass)resolve_classref_eager(ref);
+ return LLNI_classinfo_wrap(resolve_classref_eager(ref));
}
{
constant_classref *ref;
classinfo *c = NULL;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_classref*)class_getconstant(
cls, index, CONSTANT_Class);
return NULL;
}
- return (jclass)c;
+ return LLNI_classinfo_wrap(c);
}
JNIEXPORT struct java_lang_reflect_Member* JNICALL Java_sun_reflect_ConstantPool_getMethodAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_FMIref *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_FMIref*)class_getconstant(
cls, index, CONSTANT_Methodref);
{
constant_FMIref *ref;
classinfo *c = NULL;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_FMIref*)class_getconstant(
cls, index, CONSTANT_Methodref);
JNIEXPORT struct java_lang_reflect_Field* JNICALL Java_sun_reflect_ConstantPool_getFieldAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_FMIref *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_FMIref*)class_getconstant(
cls, index, CONSTANT_Fieldref);
{
constant_FMIref *ref;
classinfo *c;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_FMIref*)class_getconstant(
cls, index, CONSTANT_Fieldref);
JNIEXPORT int32_t JNICALL Java_sun_reflect_ConstantPool_getIntAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_integer *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_integer*)class_getconstant(
cls, index, CONSTANT_Integer);
JNIEXPORT int64_t JNICALL Java_sun_reflect_ConstantPool_getLongAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_long *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_long*)class_getconstant(
cls, index, CONSTANT_Long);
JNIEXPORT float JNICALL Java_sun_reflect_ConstantPool_getFloatAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_float *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_float*)class_getconstant(
cls, index, CONSTANT_Float);
JNIEXPORT double JNICALL Java_sun_reflect_ConstantPool_getDoubleAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
constant_double *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (constant_double*)class_getconstant(
cls, index, CONSTANT_Double);
JNIEXPORT struct java_lang_String* JNICALL Java_sun_reflect_ConstantPool_getStringAt0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
utf *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (utf*)class_getconstant(cls, index, CONSTANT_String);
JNIEXPORT struct java_lang_String* JNICALL Java_sun_reflect_ConstantPool_getUTF8At0(JNIEnv *env, struct sun_reflect_ConstantPool* this, struct java_lang_Object* jcpool, int32_t index)
{
utf *ref;
- classinfo *cls = (classinfo*)jcpool;
+ classinfo *cls = LLNI_classinfo_unwrap(jcpool);
ref = (utf*)class_getconstant(cls, index, CONSTANT_Utf8);