Name: mm8553 Date: 04/05/99
We have the following interface:
package MITI.util;
public interface MIRIterator extends ListIterator
{
// some methods, none of which called hasNext
}
Then, we retieve a handle to the interface "MITI/util/MIRIterator" and when we try to get a handle to "hasNext" using JNIEnv::GetMethodID we fail. We call GetMethodID as follows:
env->GetMethodID(interface_id,"hasNext","()Z");
The method returns NULL and throws the exception NoSuchMethodError.
If we specify "java/util/ListIterator" for the interface this method works.
The JNI 1.1 documentation specifies that GetMethodID can retrieve methods for both classes and interfaces and that it can retrieve inherited methods. Has this changed for Hotspot ?
We tested our code in the following JVMs:
* 'Classic VM (build JDK-1.2fcs-S, native threads)',
'Classic VM (build JDK-1.2-V, native threads)'
-> GetMethodID works
* 'HotSpot VM (1.0rc1, mixed mode, build F)',
'HotSpot VM (1.0rc2, mixed mode, build E)'
-> GetMethodID does not work
(Review ID: 56319)
======================================================================