github.com/thommil/tge-mobile@v0.0.0-20190308225214-66a08abd51aa/bind/testdata/universe.java.golden (about) 1 // Java class go.error is a proxy for talking to a Go program. 2 // gobind -lang=java 3 // 4 // File is generated by gobind. Do not edit. 5 package go; 6 7 import go.Seq; 8 9 public interface error { 10 public String error(); 11 12 } 13 14 // Java class go.Universe is a proxy for talking to a Go program. 15 // gobind -lang=java 16 // 17 // File is generated by gobind. Do not edit. 18 package go; 19 20 import go.Seq; 21 22 public abstract class Universe { 23 static { 24 Seq.touch(); // for loading the native library 25 _init(); 26 } 27 28 private Universe() {} // uninstantiable 29 30 // touch is called from other bound packages to initialize this package 31 public static void touch() {} 32 33 private static native void _init(); 34 35 private static final class proxyerror extends Exception implements Seq.Proxy, error { 36 private final int refnum; 37 38 @Override public final int incRefnum() { 39 Seq.incGoRef(refnum, this); 40 return refnum; 41 } 42 43 proxyerror(int refnum) { this.refnum = refnum; Seq.trackGoRef(refnum, this); } 44 45 @Override public String getMessage() { return error(); } 46 47 public native String error(); 48 } 49 50 51 }