[512] in java-interest
Native methods
daemon@ATHENA.MIT.EDU (Yuri Rzhanov)
Tue Jun 27 07:42:20 1995
Date: Tue, 27 Jun 1995 12:01:16 +0100 (BST)
From: Yuri Rzhanov <yuri@cee.hw.ac.uk>
To: java-interest@java.sun.com
Hi Java Team,
could you please answer some questions about native methods:
o Where are execute_method() and other routines of this type? Doesn't
seem to be in the libraries supplied with hotjava distribution. Should
I link something special?
o If I want to call from C some java method which looks like
String getString(int i) {
...
}
what will be its signature? I gather the correspondent bit in C must be:
Hjava_lang_String *s = (Hjava_lang_String *) execute_method(0,
this, "getString(I)Ljava/lang/String", i);
Is that so?
And if the method is:
int getInt(String s) {
...
}
C must have:
Hjava_lang_String *s = ...;
long i = (long) execute_method(0,
this, "getInt(Ljava/lang/String)I", s);
o How to get toplevel shell from Frame? Say, if I have
'struct Hawt_Frame *frame' as an argument in some C-routine, I could
find
struct FrameData *fdata = PDATA(FrameData, frame);
What is the difference between 'fdata->winData.shell' and 'fdata->winData.w' ?
Thanks for your time,
Yuri
************************************************
* Yuri Rzhanov, Project INTERACT *
* Dept of Computing and Electrical Engineering *
* Heriot-Watt University, Edinburgh, Scotland *
* tel 031 - 449 5111 x4188 *
************************************************
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com