|
@@ -8,10 +8,7 @@ import com.steerinfo.inPlantNavigation.service.IIPMMSVertexEdgeService;
|
|
import com.steerinfo.inPlantNavigation.service.IIPMMSVertexService;
|
|
import com.steerinfo.inPlantNavigation.service.IIPMMSVertexService;
|
|
import com.steerinfo.inPlantNavigation.service.impl.IPMMSVertexServiceImpl;
|
|
import com.steerinfo.inPlantNavigation.service.impl.IPMMSVertexServiceImpl;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
-import org.springframework.web.bind.annotation.GetMapping;
|
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
|
-import org.springframework.web.bind.annotation.ResponseBody;
|
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import java.util.ArrayList;
|
|
import java.util.ArrayList;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
@@ -28,11 +25,11 @@ public class IPMMSVertexController extends BaseRESTfulController {
|
|
|
|
|
|
|
|
|
|
@GetMapping("/getObtainTheOptimalPath")
|
|
@GetMapping("/getObtainTheOptimalPath")
|
|
- public RESTfulResult getObtainTheOptimalPath(){
|
|
|
|
|
|
+ public RESTfulResult getObtainTheOptimalPath(@RequestParam("startPoint") String startPoint,@RequestParam("endPoint") String endPoint){
|
|
|
|
|
|
Map<String, List<IPMMSVertexEdge>> vertexEdgeList= ipmmsVertexEdgeService.initVertexEdge();
|
|
Map<String, List<IPMMSVertexEdge>> vertexEdgeList= ipmmsVertexEdgeService.initVertexEdge();
|
|
Map<String, IPMMSVertex> vertexList = ipmmsVertexService.initIPMMSVertex();
|
|
Map<String, IPMMSVertex> vertexList = ipmmsVertexService.initIPMMSVertex();
|
|
- ArrayList<IPMMSVertex> obtainTheOptimalPath= ipmmsVertexService.getObtainTheOptimalPath("2","0",vertexEdgeList,vertexList);
|
|
|
|
|
|
+ ArrayList<IPMMSVertex> obtainTheOptimalPath= ipmmsVertexService.getObtainTheOptimalPath(startPoint,endPoint,vertexEdgeList,vertexList);
|
|
return success(obtainTheOptimalPath);
|
|
return success(obtainTheOptimalPath);
|
|
}
|
|
}
|
|
|
|
|