This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Where to find a CNI-Tutorial?
- From: Jeff Sturm <jsturm at one-point dot com>
- To: Clemens Eisserer <linuxhippy at web dot de>
- Cc: java at gcc dot gnu dot org
- Date: Mon, 25 Aug 2003 10:44:39 -0400 (EDT)
- Subject: Re: Where to find a CNI-Tutorial?
On Mon, 25 Aug 2003, Clemens Eisserer wrote:
> 1.) Does anybody know good tutorials for CNI?
> The only tutorials I read where not really helpful, because they mostly
> coverd how to access java from c, not how to access c from java.
Native methods in CNI are C++, so they can call other C/C++ code. If
you're accessing C code, the headers will have to be C++-safe.
Post an example if you're stuck.
> 2.) Is there a platform-independent way to store pointer-values in java
> variables using CNI. With JNI this isnt possible as far as I know,
> because storing pointer-values into "int" only works of cource on 32-bit
> machines.
That's what gnu.gcj.RawData is for.
Jeff