public override byte[] Solve(byte[] partialData, TimeSpan timeout) { State = TaskSolverState.Solving; var tspSolver = new RecurentTspSolver(); var partialProblem = DvrpProblemData.Deserialize(partialData); Route route = tspSolver.SolveRecurent(partialProblem); State = TaskSolverState.Idle; OnProblemSolvingFinished(this); return((new DvrpSolutionData() { Routes = new List <Route>() { route }, Distance = route.Distance }).Serialize()); }
DvrpSolutionData solution;//to be removed public DvrpTaskSolver(byte[] problemData) : base(problemData) { this.problem = DvrpProblemData.Deserialize(problemData); }