public class StudentSectioningModel.StudentSectioningModelContext extends Object implements AssignmentConstraintContext<Request,Enrollment>, InfoProvider<Request,Enrollment>
Constructor and Description |
---|
StudentSectioningModelContext(Assignment<Request,Enrollment> assignment) |
StudentSectioningModelContext(StudentSectioningModel.StudentSectioningModelContext parent) |
Modifier and Type | Method and Description |
---|---|
void |
add(Assignment<Request,Enrollment> assignment,
DistanceConflict.Conflict c) |
void |
add(Assignment<Request,Enrollment> assignment,
StudentQuality.Conflict c) |
void |
add(Assignment<Request,Enrollment> assignment,
TimeOverlapsCounter.Conflict c) |
void |
assigned(Assignment<Request,Enrollment> assignment,
Enrollment enrollment)
Called after an enrollment was assigned to a request.
|
double |
getAssignedCourseRequestWeight() |
double |
getAssignedCriticalCourseRequestWeight(Request.RequestPriority rp) |
Set<Student> |
getCompleteStudents()
Students with complete schedules (see
Student.isComplete(Assignment) ) |
void |
getInfo(Assignment<Request,Enrollment> assignment,
Map<String,String> info)
Adds some information into the table with information about the solution
|
void |
getInfo(Assignment<Request,Enrollment> assignment,
Map<String,String> info,
Collection<Request> variables)
Adds some information into the table with information about the solution,
only consider variables from the given set
|
int |
getNrAssignedLastLikeRequests()
Number of requests from projected (
Student.isDummy() equals true)
students that are assigned. |
int |
getNrCompleteLastLikeStudents()
Number of last like (
Student.isDummy() equals true) students with
a complete schedule (Student.isComplete(Assignment) equals true). |
double |
getTotalValue()
Overall solution value
|
int |
nrComplete()
Number of students with complete schedule
|
void |
remove(Assignment<Request,Enrollment> assignment,
DistanceConflict.Conflict c) |
void |
remove(Assignment<Request,Enrollment> assignment,
StudentQuality.Conflict c) |
void |
remove(Assignment<Request,Enrollment> assignment,
TimeOverlapsCounter.Conflict c) |
void |
requestWeightsChanged(Assignment<Request,Enrollment> assignment)
Recompute cached request weights
|
void |
unassigned(Assignment<Request,Enrollment> assignment,
Enrollment enrollment)
Called before an enrollment was unassigned from a request.
|
public StudentSectioningModelContext(StudentSectioningModel.StudentSectioningModelContext parent)
public StudentSectioningModelContext(Assignment<Request,Enrollment> assignment)
public void assigned(Assignment<Request,Enrollment> assignment, Enrollment enrollment)
assigned
in interface AssignmentConstraintContext<Request,Enrollment>
assignment
- current assignment (with which this context is associated)enrollment
- assigned valuepublic void unassigned(Assignment<Request,Enrollment> assignment, Enrollment enrollment)
unassigned
in interface AssignmentConstraintContext<Request,Enrollment>
assignment
- current assignment (with which this context is associated)enrollment
- unassigned valuepublic void add(Assignment<Request,Enrollment> assignment, DistanceConflict.Conflict c)
public void remove(Assignment<Request,Enrollment> assignment, DistanceConflict.Conflict c)
public void add(Assignment<Request,Enrollment> assignment, TimeOverlapsCounter.Conflict c)
public void remove(Assignment<Request,Enrollment> assignment, TimeOverlapsCounter.Conflict c)
public void add(Assignment<Request,Enrollment> assignment, StudentQuality.Conflict c)
public void remove(Assignment<Request,Enrollment> assignment, StudentQuality.Conflict c)
public Set<Student> getCompleteStudents()
Student.isComplete(Assignment)
)public int nrComplete()
public void requestWeightsChanged(Assignment<Request,Enrollment> assignment)
assignment
- curent assignmentpublic double getTotalValue()
public int getNrCompleteLastLikeStudents()
Student.isDummy()
equals true) students with
a complete schedule (Student.isComplete(Assignment)
equals true).public int getNrAssignedLastLikeRequests()
Student.isDummy()
equals true)
students that are assigned.public void getInfo(Assignment<Request,Enrollment> assignment, Map<String,String> info)
InfoProvider
getInfo
in interface InfoProvider<Request,Enrollment>
assignment
- current assignmentinfo
- info tablepublic void getInfo(Assignment<Request,Enrollment> assignment, Map<String,String> info, Collection<Request> variables)
InfoProvider
getInfo
in interface InfoProvider<Request,Enrollment>
assignment
- current assignmentinfo
- info tablevariables
- sub-problempublic double getAssignedCourseRequestWeight()
public double getAssignedCriticalCourseRequestWeight(Request.RequestPriority rp)