|
@@ -9,21 +9,17 @@ import java.util.Map;
|
9
|
9
|
* @author leon on 10/12/2018.
|
10
|
10
|
*/
|
11
|
11
|
public class Student {
|
12
|
|
- private Map<String, LabStatus> map;
|
|
12
|
+ private HashMap<String, LabStatus> map = new HashMap<String, LabStatus>() {
|
|
13
|
+ };
|
13
|
14
|
|
14
|
15
|
public Student() {
|
15
|
16
|
}
|
16
|
17
|
|
17
|
|
- public Student(Map<String, LabStatus> map) {
|
18
|
|
- this.map = map;
|
19
|
|
- }
|
20
|
|
-
|
21
|
18
|
public void setLabStatus(Lab lab, LabStatus labStatus) {
|
22
|
19
|
map.put(lab.labName, labStatus);
|
23
|
20
|
|
24
|
21
|
}
|
25
|
22
|
|
26
|
|
-
|
27
|
23
|
public void forkLab(Lab lab) {
|
28
|
24
|
setLabStatus(lab, LabStatus.PENDING);
|
29
|
25
|
}
|