PageRenderTime 18ms CodeModel.GetById 11ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/trunk/Examples/test-suite/java/director_ignore_runme.java

#
Java | 40 lines | 34 code | 5 blank | 1 comment | 4 complexity | 6aec4371a7ce94a1722a3458ecb63210 MD5 | raw file
 1import director_ignore.*;
 2
 3public class director_ignore_runme {
 4  static {
 5    try {
 6        System.loadLibrary("director_ignore");
 7    } catch (UnsatisfiedLinkError e) {
 8      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);
 9      System.exit(1);
10    }
11  }
12
13  public static void main(String argv[]) 
14  {
15    // Just check the classes can be instantiated and other methods work as expected
16    DIgnoresDerived a = new DIgnoresDerived();
17    if (a.Triple(5) != 15)
18      throw new RuntimeException("Triple failed");
19    DAbstractIgnoresDerived b = new DAbstractIgnoresDerived();
20    if (b.Quadruple(5) != 20)
21      throw new RuntimeException("Quadruple failed");
22  }
23}
24
25class DIgnoresDerived extends DIgnores
26{
27  public DIgnoresDerived()
28  {
29    super();
30  }
31}
32
33class DAbstractIgnoresDerived extends DAbstractIgnores
34{
35  public DAbstractIgnoresDerived()
36  {
37    super();
38  }
39}
40