質問編集履歴
1
Baseクラスのフィールドのstaticを除去 BaseインスタンスのBase.~をthis.~へ変更
test
CHANGED
File without changes
|
test
CHANGED
@@ -20,21 +20,21 @@
|
|
20
20
|
|
21
21
|
public abstract class Base {
|
22
22
|
|
23
|
-
public
|
23
|
+
public int tweetId = 0;
|
24
24
|
|
25
|
-
public
|
25
|
+
public long datetime = 0;
|
26
26
|
|
27
|
-
public
|
27
|
+
public String userId = "";
|
28
28
|
|
29
29
|
|
30
30
|
|
31
31
|
public Base(int tweetId,String userId) {
|
32
32
|
|
33
|
-
|
33
|
+
this.tweetId = tweetId;
|
34
34
|
|
35
|
-
|
35
|
+
this.userId = userId;
|
36
36
|
|
37
|
-
|
37
|
+
this.datetime = getNow();
|
38
38
|
|
39
39
|
}
|
40
40
|
|
@@ -50,7 +50,7 @@
|
|
50
50
|
|
51
51
|
public int getTweetId() {
|
52
52
|
|
53
|
-
return t
|
53
|
+
return tweetId;
|
54
54
|
|
55
55
|
}
|
56
56
|
|
@@ -86,7 +86,7 @@
|
|
86
86
|
|
87
87
|
public class Reply extends Tweet{
|
88
88
|
|
89
|
-
private String target =
|
89
|
+
private String target = super.userId;
|
90
90
|
|
91
91
|
public Reply(int tweetId,String userId,String text, Tweet target) {
|
92
92
|
|