Changeset 30737 in osm for applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/DownloadSVGTask.java
- Timestamp:
- 2014-10-18T23:07:52+02:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/DownloadSVGTask.java
r29854 r30737 104 104 private void createWay(String svg) { 105 105 String[] SVGpaths = new SVGParser().getClosedPaths(svg); 106 ArrayList<Double> fitViewBox = new ArrayList< Double>();107 ArrayList<ArrayList<EastNorth>> eastNorths = new ArrayList< ArrayList<EastNorth>>();106 ArrayList<Double> fitViewBox = new ArrayList<>(); 107 ArrayList<ArrayList<EastNorth>> eastNorths = new ArrayList<>(); 108 108 for (int i=0; i< SVGpaths.length; i++) { 109 ArrayList<EastNorth> eastNorth = new ArrayList< EastNorth>();109 ArrayList<EastNorth> eastNorth = new ArrayList<>(); 110 110 fitViewBox.add( createNodes(SVGpaths[i], eastNorth) ); 111 111 eastNorths.add(eastNorth); … … 114 114 Double min = Collections.min(fitViewBox); 115 115 int bestPath = fitViewBox.indexOf(min); 116 List<Node> nodeList = new ArrayList< Node>();116 List<Node> nodeList = new ArrayList<>(); 117 117 for (EastNorth eastNorth : eastNorths.get(bestPath)) { 118 118 nodeList.add(new Node(Main.getProjection().eastNorth2latlon(eastNorth))); 119 119 } 120 120 Way wayToAdd = new Way(); 121 Collection<Command> cmds = new LinkedList< Command>();121 Collection<Command> cmds = new LinkedList<>(); 122 122 for (Node node : nodeList) { 123 123 cmds.add(new AddCommand(node));
Note:
See TracChangeset
for help on using the changeset viewer.