Changeset 6889 in josm for trunk/src/org/openstreetmap/josm/actions/CombineWayAction.java
- Timestamp:
- 2014-02-27T01:41:49+01:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/CombineWayAction.java
r6679 r6889 4 4 import static org.openstreetmap.josm.gui.help.HelpUtil.ht; 5 5 import static org.openstreetmap.josm.tools.I18n.tr; 6 import static org.openstreetmap.josm.tools.I18n.trc;7 6 import static org.openstreetmap.josm.tools.I18n.trn; 8 7 … … 258 257 * A pair of nodes. 259 258 */ 260 static public class NodePair {259 public static class NodePair { 261 260 private final Node a; 262 261 private final Node b; … … 376 375 } 377 376 378 static public class NodeGraph {379 static public List<NodePair> buildNodePairs(Way way, boolean directed) {377 public static class NodeGraph { 378 public static List<NodePair> buildNodePairs(Way way, boolean directed) { 380 379 List<NodePair> pairs = new ArrayList<NodePair>(); 381 380 for (Pair<Node,Node> pair: way.getNodePairs(false /* don't sort */)) { … … 388 387 } 389 388 390 static public List<NodePair> buildNodePairs(List<Way> ways, boolean directed) {389 public static List<NodePair> buildNodePairs(List<Way> ways, boolean directed) { 391 390 List<NodePair> pairs = new ArrayList<NodePair>(); 392 391 for (Way w: ways) { … … 396 395 } 397 396 398 static public List<NodePair> eliminateDuplicateNodePairs(List<NodePair> pairs) {397 public static List<NodePair> eliminateDuplicateNodePairs(List<NodePair> pairs) { 399 398 List<NodePair> cleaned = new ArrayList<NodePair>(); 400 399 for(NodePair p: pairs) { … … 406 405 } 407 406 408 static public NodeGraph createDirectedGraphFromNodePairs(List<NodePair> pairs) {407 public static NodeGraph createDirectedGraphFromNodePairs(List<NodePair> pairs) { 409 408 NodeGraph graph = new NodeGraph(); 410 409 for (NodePair pair: pairs) { … … 414 413 } 415 414 416 static public NodeGraph createDirectedGraphFromWays(Collection<Way> ways) {415 public static NodeGraph createDirectedGraphFromWays(Collection<Way> ways) { 417 416 NodeGraph graph = new NodeGraph(); 418 417 for (Way w: ways) { … … 422 421 } 423 422 424 static public NodeGraph createUndirectedGraphFromNodeList(List<NodePair> pairs) {423 public static NodeGraph createUndirectedGraphFromNodeList(List<NodePair> pairs) { 425 424 NodeGraph graph = new NodeGraph(); 426 425 for (NodePair pair: pairs) {
Note:
See TracChangeset
for help on using the changeset viewer.