logo       

Re: How can I map "C" unsigned char[] to byte[] in Java ?: msg#00139

programming.swig

Subject: Re: How can I map "C" unsigned char[] to byte[] in Java ?

Tom Lueders (MT641) wrote:
Hi folks,
anyone can help me?

I have a methode in "C++" with following signature:
unsigned long read( unsigned char byteBuffer[], unsigned long bytesToRead ) ;

I simply want a byte array (byte[]) as argument on the Java site?

SWIG by default maps const unsigned char& and unsigned char[] to short[]!

What I have to do?

Look up multiple argument typemaps in the documentation and the arrays_java.i library file should be a useful reference. Also the Examples/java/multimap example.

William
_______________________________________________
Swig maillist - Swig@xxxxxxxxxxxxxxx
http://mailman.cs.uchicago.edu/mailman/listinfo/swig



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise