add day struct
This commit is contained in:
parent
aae662de56
commit
9f2b775601
1 changed files with 9 additions and 1 deletions
|
@ -1,9 +1,10 @@
|
||||||
|
#[derive(Debug)]
|
||||||
pub struct Course {
|
pub struct Course {
|
||||||
/// Professor's name
|
/// Professor's name
|
||||||
pub professor: String,
|
pub professor: String,
|
||||||
|
|
||||||
/// List of rooms where the course takes place
|
/// List of rooms where the course takes place
|
||||||
pub room: Box<String>,
|
pub room: Vec<String>,
|
||||||
|
|
||||||
/// Time the course starts, as a number :
|
/// Time the course starts, as a number :
|
||||||
/// - 0 => first possible class of the day
|
/// - 0 => first possible class of the day
|
||||||
|
@ -14,3 +15,10 @@ pub struct Course {
|
||||||
/// Number of time slots the course takes up in the timetable
|
/// Number of time slots the course takes up in the timetable
|
||||||
pub size: i8,
|
pub size: i8,
|
||||||
}
|
}
|
||||||
|
#[derive(Debug)]
|
||||||
|
pub struct Day {
|
||||||
|
/// Day's name
|
||||||
|
pub name: String,
|
||||||
|
/// Ordered list of all the courses of the day
|
||||||
|
pub courses: Vec<Option<Course>>,
|
||||||
|
}
|
||||||
|
|
Reference in a new issue