swig/Examples/test-suite/java/frob_runme.java
2004-01-21 00:46:08 +00:00

24 lines
No EOL
556 B
Java

import frob.*;
import java.lang.reflect.*;
public class frob_runme
{
static {
try {
System.loadLibrary("frob");
} catch (UnsatisfiedLinkError e) {
System.err.println("Native code library failed to load. See the chapter on Dynamic Linking Problems in the SWIG Java documentation for help.\n" + e);
System.exit(1);
}
}
public static void main(String args[])
{
Bravo foo = new Bravo();
String s = foo.abs_method();
if (!s.equals("Bravo::abs_method()"))
throw new RuntimeException( "error" );
}
}