public static class SwapStudentSelection.SwapStudentNeighbour extends Object implements Neighbour<Request,Enrollment>
| Constructor and Description |
|---|
SwapStudentNeighbour(double value,
Enrollment enrollment,
List<Enrollment> swaps)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
assign(Assignment<Request,Enrollment> assignment,
long iteration)
Perform the move.
|
Map<Request,Enrollment> |
assignments()
Return assignments to be done.
|
Student |
getStudent() |
String |
toString() |
double |
value(Assignment<Request,Enrollment> assignment)
Difference in the evaluation function, if this neighnour is assigned.
|
public SwapStudentNeighbour(double value, Enrollment enrollment, List<Enrollment> swaps)
value - cost of the moveenrollment - the enrollment which is to be assigned to the given
studentswaps - enrollment swapspublic double value(Assignment<Request,Enrollment> assignment)
Neighbourvalue in interface Neighbour<Request,Enrollment>assignment - current assignmentpublic Student getStudent()
public void assign(Assignment<Request,Enrollment> assignment, long iteration)
assign in interface Neighbour<Request,Enrollment>assignment - current assignmentiteration - current iterationpublic Map<Request,Enrollment> assignments()
Neighbourassignments in interface Neighbour<Request,Enrollment>