Skip to content

Commit e660dfc

Browse files
zepfredtriceo
authored andcommitted
chore: minor fix
1 parent 4449959 commit e660dfc

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/main/java/ai/timefold/solver/benchmarks/micro/scoredirector/problems/ProblemInitializer.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,12 @@ private static <Solution_> Solution_ initialize(Example example, Solution_ unini
7474
var config = new ConstructionHeuristicPhaseConfig()
7575
.withConstructionHeuristicType(ConstructionHeuristicType.FIRST_FIT);
7676
var factory = new DefaultConstructionHeuristicPhaseFactory<Solution_>(config);
77-
var policy = new HeuristicConfigPolicy.Builder<>(EnvironmentMode.REPRODUCIBLE,
78-
null, null, null, null, new Random(0), scoreDirectorFactory.getInitializingScoreTrend(),
79-
scoreDirectorFactory.getSolutionDescriptor(), ClassInstanceCache.create())
77+
var policy = new HeuristicConfigPolicy.Builder<Solution_>()
78+
.withEnvironmentMode(EnvironmentMode.REPRODUCIBLE)
79+
.withRandom(new Random(0))
80+
.withInitializingScoreTrend(scoreDirectorFactory.getInitializingScoreTrend())
81+
.withSolutionDescriptor(scoreDirectorFactory.getSolutionDescriptor())
82+
.withClassInstanceCache(ClassInstanceCache.create())
8083
.build();
8184
var bestSolutionRecaller =
8285
BestSolutionRecallerFactory.create().<Solution_> buildBestSolutionRecaller(EnvironmentMode.REPRODUCIBLE);

0 commit comments

Comments
 (0)