public class SuggestionSelection.Selection extends BranchBoundSelection.Selection
BranchBoundSelection.Selection
including checking of
required free times and sections.iAssignment, iBestAssignment, iBestValue, iCurrentAssignment, iStudent, iT0, iT1, iTimeoutReached, iTimesToAvoid, iValues
Constructor and Description |
---|
Selection(Student student,
Assignment<Request,Enrollment> assignment) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
canLeaveUnassigned(Request request)
Returns true if the given request can be left unassigned
|
Enrollment |
firstConflict(int idx,
Enrollment enrollment)
First conflicting enrollment
|
protected double |
getBound(Request r)
Return bound of a request
|
protected double |
getWeight(Enrollment enrollment,
Set<DistanceConflict.Conflict> distanceConflicts,
Set<TimeOverlapsCounter.Conflict> timeOverlappingConflicts)
Deprecated.
|
boolean |
inConflict(int idx,
Enrollment enrollment)
True if the enrollment is conflicting
|
boolean |
isAllowed(int idx,
Enrollment enrollment)
Check if the given enrollment is allowed
|
protected List<Enrollment> |
values(CourseRequest request)
Returns list of available enrollments for a course request
|
backTrack, canAssign, getAssignmentPenalty, getBestAssignment, getBestNrAssigned, getBestValue, getBound, getDistanceConflicts, getNrAssigned, getNrAssignedBound, getPenalty, getPenaltyBound, getStudentQualityConflicts, getTime, getTimeOverlappingConflicts, getValue, getWeight, isTimeoutReached, saveBest, select
public Selection(Student student, Assignment<Request,Enrollment> assignment)
public boolean isAllowed(int idx, Enrollment enrollment)
idx
- enrollment indexenrollment
- enrollmentpublic boolean inConflict(int idx, Enrollment enrollment)
BranchBoundSelection.Selection
inConflict
in class BranchBoundSelection.Selection
idx
- index of requestenrollment
- enrollment in questionpublic Enrollment firstConflict(int idx, Enrollment enrollment)
BranchBoundSelection.Selection
firstConflict
in class BranchBoundSelection.Selection
idx
- index of requestenrollment
- enrollment in questionprotected boolean canLeaveUnassigned(Request request)
BranchBoundSelection.Selection
canLeaveUnassigned
in class BranchBoundSelection.Selection
request
- given requestprotected List<Enrollment> values(CourseRequest request)
BranchBoundSelection.Selection
values
in class BranchBoundSelection.Selection
request
- given request@Deprecated protected double getWeight(Enrollment enrollment, Set<DistanceConflict.Conflict> distanceConflicts, Set<TimeOverlapsCounter.Conflict> timeOverlappingConflicts)
BranchBoundSelection.Selection
StudentWeights.getWeight(Assignment, Enrollment, Set, Set)
, only count this side of distance conflicts and time overlaps.getWeight
in class BranchBoundSelection.Selection
enrollment
- an enrollmentdistanceConflicts
- set of distance conflictstimeOverlappingConflicts
- set of time overlapping conflictsprotected double getBound(Request r)
BranchBoundSelection.Selection
getBound
in class BranchBoundSelection.Selection
r
- a request