1
我有下面的類在Java中僞造方法描述符中的Android JNI
package com.artifex.mupdf.data;
public class FzTextSpan {
FzRect bbox;
int len, cap;
FzTextChar[] mFzTextChars;
public FzTextSpan(FzRect bbox, int len, int cap, FzTextChar[] mFzTextChars) {
super();
this.bbox = bbox;
this.len = len;
this.cap = cap;
this.mFzTextChars = mFzTextChars;
}
}
我試圖使用FOLL代碼
jclass jFzSpanClass;
jmethodID jFzSpanCtor;
jFzSpanClass = (*env)->FindClass(env, "com/artifex/mupdf/data/FzTextSpan");
if (jFzSpanClass==NULL) return NULL;
jFzSpanCtor = (*env)->GetMethodID(env, jFzSpanClass, "<init>",
"(Lcom/artifex/mupdf/data/FzRect;II;[Lcom/artifex/mupdf/data/FzTextChar;)V");
調用從JNI構造我得到
Bogus Method Descriptor: "(Lcom/artifex/mupdf/data/FzRect;II;[Lcom/artifex/mupdf/data/FzTextChar;)V");
@slaadvak更準確地說'包含'com.'的目錄中的'javap -s com.artifex.mupdf.data.FzTextSpan' – EJP