import java.util.Arrays;
public abstract class Runtime implements UsermodeConstants,Registers,Cloneable {
+ public static final String VERSION = "1.0";
+
/** True to write useful diagnostic information to stderr when things go wrong */
final static boolean STDERR_DIAG = true;
}
}
+ static byte[] getNullTerminatedBytes(String s) {
+ byte[] buf1 = getBytes(s);
+ byte[] buf2 = new byte[buf1.length+1];
+ System.arraycopy(buf1,0,buf2,0,buf1.length);
+ return buf2;
+ }
+
final static String toHex(int n) { return "0x" + Long.toString(n & 0xffffffffL, 16); }
final static int min(int a, int b) { return a < b ? a : b; }
final static int max(int a, int b) { return a > b ? a : b; }