Beispiel #1
0
 public UClass(int id, UCourse course, string instructorName, IEnumerable <DayOfWeek> days, TimeSpan startTime, TimeSpan endTime, int section, int capacity, int numberOfRegisteredStudents)
 {
     Id                         = id;
     Course                     = course;
     InstructorName             = instructorName;
     Days                       = days.Distinct().ToArray();
     StartTime                  = startTime;
     EndTime                    = endTime;
     Section                    = section;
     Capacity                   = capacity;
     NumberOfRegisteredStudents = numberOfRegisteredStudents;
 }
Beispiel #2
0
 public UClass(UCourse course, string instructorName, IEnumerable <DayOfWeek> days, TimeSpan startTime, TimeSpan endTime, int section, int capacity = 0, int numberOfRegisteredStudents = 0)
 {
     //course id length is 5
     Id                         = Identify(course.Id, section);
     Course                     = course;
     InstructorName             = instructorName;
     Days                       = days.Distinct().ToArray();
     StartTime                  = startTime;
     EndTime                    = endTime;
     Section                    = section;
     Capacity                   = capacity;
     NumberOfRegisteredStudents = numberOfRegisteredStudents;
 }