Bug in JNI RegisterNatives?

Bryce McKinlay mckinlay@redhat.com
Tue May 30 19:40:00 GMT 2006


Juerg Lehni wrote:
> The way these are defined in jni.h, it seems to not be possible to 
> forward declare them in Class.h. A possible solution is to include 
> jni.h there, but before I go ahead I'd like to hear your opinion on 
> this. Another possibility is a function calld _Jv_GetClassName in 
> jni.cc that is declared friend in Class.h and does nothing else than 
> returning the name.

How about adding an inline member function in Class.h to access the name 
field - eg getNameUtf8(). This is probably the cleanest approach.
Bryce


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /