public void doStep() {
WorkingMemory workingMemory = greedyFitSolverPhaseScope.getWorkingMemory();
FactHandle factHandle = workingMemory.getFactHandle(planningEntity);
for (Map.Entry<PlanningVariableDescriptor, Object> entry : variableToValueMap.entrySet()) {
PlanningVariableDescriptor planningVariableDescriptor = entry.getKey();
Object value = entry.getValue();
planningVariableDescriptor.setValue(planningEntity, value);
}
workingMemory.update(factHandle, planningEntity);
// there is no need to recalculate the score, but we still need to set it
greedyFitSolverPhaseScope.getWorkingSolution().setScore(score);
}