blob: ec3d30c518003848d5d738b6e37619d5094d5d8a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
package test.misc;
import java.io.IOException;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.Map.Entry;
public class ExtTest<E> extends ArrayList<E> {
public static void main(String[] args) {
Date d = new Date(); Timestamp t = new Timestamp(d.getTime());
System.out.println(d.after(t));
System.out.println((int)-1);
System.out.println((int)1);
System.out.println((Integer)1);
System.out.println((Integer)1);
Class c = String.class;
Integer Integer = 0;
Integer = (Integer)-1;
int z = 0;
z = z+++(++z);
Entry ent = (Entry)new HashMap().entrySet().iterator().next();
label1: {
System.out.println("1");
if(Math.random() > 4) {
break label1;
}
System.out.println("2");
}
System.out.println("3");
}
public <T extends E> void test(T o) {
}
public void testException() throws IOException {
// if(true) {
// throw new RuntimeException();
// } else {
// throw new IOException();
// }
// throw true?new IOException():new IOException();
// throw true?new ClassCastException():new IOException();
}
public static int ttt() {
Object obj = new Integer(5);
synchronized (new Integer(3)) {
System.out.println(obj);
obj = null;
}
System.out.println("1");
if(Math.random() > 1) {
System.out.println("2");
} else {
System.out.println("3");
}
System.out.println("4");
int a = 0;
try {
a = 2;
return a;
} finally {
a = 4;
}
}
}
|