public boolean isMoveDoable(WorkingMemory workingMemory) { return !ObjectUtils.equals(cloudAssignment.getCloudComputer(), toCloudComputer); }
public Move createUndoMove(WorkingMemory workingMemory) { return new CloudComputerChangeMove(cloudAssignment, cloudAssignment.getCloudComputer()); }
public static void moveCloudComputer( WorkingMemory workingMemory, CloudAssignment cloudAssignment, CloudComputer toCloudComputer) { FactHandle factHandle = workingMemory.getFactHandle(cloudAssignment); cloudAssignment.setCloudComputer(toCloudComputer); workingMemory.update(factHandle, cloudAssignment); }