adding a test case
[IRC.git] / Robust / src / ClassLibrary / System.java
1 public class System {
2   public static void printInt(int x) {
3     String s=String.valueOf(x);
4     printString(s);
5   }
6
7   public static native void gc();
8
9   public static native long currentTimeMillis();
10
11   public static native long microTimes();
12
13   public static native long getticks();
14
15   public static native void printString(String s);
16
17   public static void println(String s) {
18     System.printString(s+"\n");
19   }
20
21   public static void println(Object o) {
22     System.printString(""+o+"\n");
23   }
24
25   public static void println(int o) {
26     System.printString(""+o+"\n");
27   }
28
29   public static void println(double o) {
30     System.printString(""+o+"\n");
31   }
32
33   public static void println(long o) {
34     System.printString(""+o+"\n");
35   }
36
37   public static void println() {
38     System.printString("\n");
39   }
40
41   public static void print(String s) {
42     System.printString(s);
43   }
44
45   public static void print(Object o) {
46     System.printString(""+o);
47   }
48
49   public static void print(int o) {
50     System.printString(""+o);
51   }
52
53   public static void print(double o) {
54     System.printString(""+o);
55   }
56
57   public static void print(long o) {
58     System.printString(""+o);
59   }
60
61   public static void error() {
62     System.printString("Error (Use Breakpoint on ___System______error method for more information!)\n");
63   }
64
65   public static native void exit(int status);
66
67   public static native void printI(int status);
68
69   public static native void clearPrefetchCache();
70
71   public static native void rangePrefetch(Object o, short[] offsets);
72
73   public static native void deepArrayCopy(Object dst, Object src);
74
75   public static native void Assert(boolean status);
76
77   /* Only used for microbenchmark testing of SingleTM version */
78   public static native void logevent(int event);
79   public static native void logevent();
80
81   /* Only used for microbenchmark testing of SingleTM version */
82   public static native void initLog();
83
84   public static native void flushToFile(int threadid);
85   /* Only used for microbenchmark testing of SingleTM version */
86
87   public static native void arraycopy(Object src, int srcPos, Object dst, int destPos, int length);
88
89   // for disjoint reachability analysis
90   public static void genReach();
91 }