-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathExamInfo.java
54 lines (42 loc) · 1.15 KB
/
ExamInfo.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
package com.deange.uwaterlooapi.model.courses;
import android.os.Parcel;
import android.os.Parcelable;
import com.deange.uwaterlooapi.model.BaseModel;
import com.google.gson.annotations.SerializedName;
import java.util.List;
public class ExamInfo
extends BaseModel
implements
Parcelable {
@SerializedName("course")
String mCourse;
@SerializedName("sections")
List<ExamSection> mSections;
protected ExamInfo(final Parcel in) {
super(in);
mCourse = in.readString();
mSections = in.createTypedArrayList(ExamSection.CREATOR);
}
@Override
public void writeToParcel(final Parcel dest, final int flags) {
super.writeToParcel(dest, flags);
dest.writeString(mCourse);
dest.writeTypedList(mSections);
}
public static final Creator<ExamInfo> CREATOR = new Creator<ExamInfo>() {
@Override
public ExamInfo createFromParcel(final Parcel in) {
return new ExamInfo(in);
}
@Override
public ExamInfo[] newArray(final int size) {
return new ExamInfo[size];
}
};
public String getCourse() {
return mCourse;
}
public List<ExamSection> getSections() {
return mSections;
}
}