Die Datei: AbstractStack.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23public
24abstract
25class AbstractStack {
26
27
28
29
30
31
32
33 public
34 abstract
35 boolean isEmpty();
36
37 public
38 abstract
39 Object top();
40
41 public
42 abstract
43 void push(Object o);
44
45 public
46 abstract
47 void pop();
48
49
50
51
52
53
54
55
56
57 public
58 final
59 boolean prePop() {
60 return
61 ! isEmpty();
62 }
63
64 public
65 final
66 boolean preTop() {
67 return
68 ! isEmpty();
69 }
70
71}
72
73
Die Quelle: AbstractStack.java