mirror of
https://github.com/graphhopper/jsprit.git
synced 2020-01-24 07:45:05 +01:00
add constructor to outsource neighborhood creation
This commit is contained in:
parent
2244923575
commit
76c84ff75e
1 changed files with 16 additions and 0 deletions
|
|
@ -89,6 +89,22 @@ public final class RuinRadial extends AbstractRuinStrategy {
|
|||
jobNeighborhoods = jobNeighborhoodsImpl;
|
||||
logger.info("initialise " + this);
|
||||
}
|
||||
|
||||
public RuinRadial(VehicleRoutingProblem vrp, int noJobs2beRemoved, JobNeighborhoods neighborhoods) {
|
||||
super();
|
||||
this.vrp = vrp;
|
||||
noJobsToMemorize = noJobs2beRemoved;
|
||||
ruinShareFactory = new RuinShareFactory() {
|
||||
|
||||
@Override
|
||||
public int createNumberToBeRemoved() {
|
||||
return noJobsToMemorize;
|
||||
}
|
||||
|
||||
};
|
||||
jobNeighborhoods = neighborhoods;
|
||||
logger.info("initialise " + this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue