forked from raghaddmahgoub/OOP-Project
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathReply.java
More file actions
32 lines (25 loc) · 652 Bytes
/
Reply.java
File metadata and controls
32 lines (25 loc) · 652 Bytes
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
import java.time.LocalDateTime;
import java.util.List;
public class Reply extends Text{
/////////////////////////////////////////ATTRIBUTES//////////////////////////////////
private static int Id=0;
public void setReplyId(int replyId) {
this.replyId = replyId;
}
private int replyId;
public Reply(String content) {
replyId=Id;
Id++;
this.content=content;
}
public int getId() {
return replyId;}
@Override
public void addReact() {
cntReacts++;
}
@Override
public int getReacts() {
return cntReacts;
}
}