-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTopic.java
40 lines (31 loc) · 952 Bytes
/
Topic.java
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
import java.io.Serializable;
import java.util.ArrayList;
public class Topic implements Serializable {
/**
*
*/
private static final long serialVersionUID = -3667146219519736893L;
private ArrayList<Subject> subjectArrayList;
private String topicName;
@Override
public String toString() {
return "Topic{" +
"subjectArrayList=" + subjectArrayList +
", topicName='" + topicName + '\'' +
'}';
}
public Topic(){}
public Topic(String topicName) {
this.topicName = topicName;
this.subjectArrayList = new ArrayList<>();
}
public ArrayList<Subject> getSubjectArrayList() {
return subjectArrayList;
}
public void setSubjectArrayList(Subject subject) {
this.subjectArrayList.add(subject);
}
public String getTopicName() {
return topicName;
}
}