upm/src/zfm20/javaupm_zfm20.i
Stefan Andritoiu dddba3e8a4 java: Added auto load library code in upm SWIG interfaces
Signed-off-by: Stefan Andritoiu <stefan.andritoiu@intel.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
2015-11-24 14:36:17 -08:00

28 lines
586 B
OpenEdge ABL

%module javaupm_zfm20
%include "../upm.i"
%include "stdint.i"
%include "typemaps.i"
%include "arrays_java.i";
%include "../java_buffer.i";
%apply uint16_t *OUTPUT { uint16_t *id, uint16_t *score };
%{
#include "zfm20.h"
speed_t int_B57600 = B57600;
%}
%include "zfm20.h"
speed_t int_B57600 = B57600;
%pragma(java) jniclasscode=%{
static {
try {
System.loadLibrary("javaupm_zfm20");
} catch (UnsatisfiedLinkError e) {
System.err.println("Native code library failed to load. \n" + e);
System.exit(1);
}
}
%}