-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLecture.java
77 lines (59 loc) · 1.31 KB
/
Lecture.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
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
/*
* Default agent lecture class
*/
public class Lecture {
String weeks;
String day;
String time;
String place;
String priority;
// Constructor which parses string obtained from config file
public Lecture(String details){
String[] lectureDetails = details.split(";");
this.weeks = lectureDetails[0];
lectureDetails = lectureDetails[1].split(",");
this.day = Integer.toString(Tools.day(lectureDetails[0]));
this.time = lectureDetails[1];
this.place = lectureDetails[2];
}
public Lecture(String day, String time, String place, String weeks) {
super();
this.day = day;
this.time = time;
this.place = place;
this.weeks = weeks;
}
public String getWeeks() {
return weeks;
}
public void setWeeks(String weeks) {
this.weeks = weeks;
}
public String getDay() {
return day;
}
public void setDay(String day) {
this.day = day;
}
public String getTime() {
return time;
}
public void setTime(String time) {
this.time = time;
}
public String getPlace() {
return place;
}
public void setPlace(String place) {
this.place = place;
}
public String getPriority() {
return priority;
}
public void setPriority(String priority) {
this.priority = priority;
}
public void printInfo() {
System.out.println(weeks+";"+day+","+time+","+place + "," + priority);
}
}