OptaPlanner core 6.0.0.Beta3

org.optaplanner.core.impl.solver
Interface ProblemFactChange


public interface ProblemFactChange

A ProblemFactChange represents a change in 1 or more problem facts of a Solution. Problem facts used by a Solver must not be changed while it is solving, but by scheduling this command to the Solver, you can change them when the time is right.

Note that the Solver clones a Solution at will. So any change must be done on the problem facts and planning entities referenced by the Solution of the ScoreDirector. On each change it should also notify the ScoreDirector accordingly.


Method Summary
 void doChange(ScoreDirector scoreDirector)
          Does the change on the Solution of the ScoreDirector and notifies the ScoreDirector accordingly.
 

Method Detail

doChange

void doChange(ScoreDirector scoreDirector)
Does the change on the Solution of the ScoreDirector and notifies the ScoreDirector accordingly. Every modification to the Solution, must be correctly notified to the ScoreDirector, otherwise the Score calculation will be corrupted.

Parameters:
scoreDirector - never null Contains the working Solution which contains the planning facts (and planning entities) to change. Also needs to get notified of those changes.

OptaPlanner core 6.0.0.Beta3

Copyright © 2006-2013 JBoss by Red Hat. All Rights Reserved.