Changeset 30737 in osm for applications/editors/josm/plugins/FixAddresses/src
- Timestamp:
- 2014-10-18T23:07:52+02:00 (10 years ago)
- Location:
- applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/AddressEditContainer.java
r30348 r30737 47 47 private Collection<? extends OsmPrimitive> workingSet; 48 48 /** The street dictionary collecting all streets to a set of unique street names. */ 49 private HashMap<String, OSMStreet> streetDict = new HashMap< String, OSMStreet>(100);49 private HashMap<String, OSMStreet> streetDict = new HashMap<>(100); 50 50 51 51 /** The unresolved (addresses without valid street name) addresses list. */ 52 private List<OSMAddress> unresolvedAddresses = new ArrayList< OSMAddress>(100);52 private List<OSMAddress> unresolvedAddresses = new ArrayList<>(100); 53 53 54 54 /** The incomplete addresses list. */ 55 private List<OSMAddress> incompleteAddresses = new ArrayList< OSMAddress>(100);55 private List<OSMAddress> incompleteAddresses = new ArrayList<>(100); 56 56 57 57 /** The shadow copy to assemble the street dict during update. */ 58 private HashMap<String, OSMStreet> shadowStreetDict = new HashMap< String, OSMStreet>(100);58 private HashMap<String, OSMStreet> shadowStreetDict = new HashMap<>(100); 59 59 /** The shadow copy to assemble the unresolved addresses during update. */ 60 private List<OSMAddress> shadowUnresolvedAddresses = new ArrayList< OSMAddress>(100);60 private List<OSMAddress> shadowUnresolvedAddresses = new ArrayList<>(100); 61 61 /** The shadow copy to assemble the incomplete addresses during update. */ 62 private List<OSMAddress> shadowIncompleteAddresses = new ArrayList< OSMAddress>(100);62 private List<OSMAddress> shadowIncompleteAddresses = new ArrayList<>(100); 63 63 64 64 /** The visited nodes cache to increase iteration speed. */ 65 private HashSet<Node> visitedNodes = new HashSet< Node>();65 private HashSet<Node> visitedNodes = new HashSet<>(); 66 66 /** The visited ways cache to increase iteration speed. */ 67 private HashSet<Way> visitedWays = new HashSet< Way>();67 private HashSet<Way> visitedWays = new HashSet<>(); 68 68 /** The tag list used within the data area. */ 69 private HashSet<String> tags = new HashSet< String>();69 private HashSet<String> tags = new HashSet<>(); 70 70 /** The tag list used within the data area. */ 71 private HashMap<String, String> values = new HashMap< String, String>();71 private HashMap<String, String> values = new HashMap<>(); 72 72 73 73 /** The list containing the problems */ 74 private List<IProblem> problems = new ArrayList< IProblem>();74 private List<IProblem> problems = new ArrayList<>(); 75 75 76 76 /** The change listeners. */ 77 private List<IAddressEditContainerListener> listeners = new ArrayList< IAddressEditContainerListener>();77 private List<IAddressEditContainerListener> listeners = new ArrayList<>(); 78 78 79 79 /** … … 115 115 protected void fireContainerChanged() { 116 116 List<IAddressEditContainerListener> shadowListeners = 117 new ArrayList< IAddressEditContainerListener>(listeners);117 new ArrayList<>(listeners); 118 118 119 119 for (IAddressEditContainerListener listener : shadowListeners) { … … 129 129 130 130 List<IAddressEditContainerListener> shadowListeners = 131 new ArrayList< IAddressEditContainerListener>(listeners);131 new ArrayList<>(listeners); 132 132 133 133 for (IAddressEditContainerListener listener : shadowListeners) { … … 336 336 */ 337 337 public List<OSMStreet> getStreetList() { 338 ArrayList<OSMStreet> sortedList = new ArrayList< OSMStreet>(streetDict.values());338 ArrayList<OSMStreet> sortedList = new ArrayList<>(streetDict.values()); 339 339 Collections.sort(sortedList); 340 340 return sortedList; … … 417 417 */ 418 418 public List<OSMAddress> getAllAddressesToFix() { 419 List<OSMAddress> all = new ArrayList< OSMAddress>(incompleteAddresses);419 List<OSMAddress> all = new ArrayList<>(incompleteAddresses); 420 420 421 421 for (OSMAddress aNode : unresolvedAddresses) { … … 453 453 return true; 454 454 } 455 455 456 456 if (streetName != null && shadowStreetDict.containsKey(streetName)) { 457 457 OSMStreet sNode = shadowStreetDict.get(streetName); … … 467 467 */ 468 468 public void resolveAddresses() { 469 List<OSMAddress> resolvedAddresses = new ArrayList< OSMAddress>();469 List<OSMAddress> resolvedAddresses = new ArrayList<>(); 470 470 for (OSMAddress node : shadowUnresolvedAddresses) { 471 471 if (assignAddressToStreet(node)) { … … 513 513 } 514 514 } 515 515 516 516 // match streets with addresses... 517 517 resolveAddresses(); … … 521 521 522 522 // put results from shadow copy into real lists 523 incompleteAddresses = new ArrayList< OSMAddress>(shadowIncompleteAddresses);524 unresolvedAddresses = new ArrayList< OSMAddress>(shadowUnresolvedAddresses);525 streetDict = new HashMap< String, OSMStreet>(shadowStreetDict);523 incompleteAddresses = new ArrayList<>(shadowIncompleteAddresses); 524 unresolvedAddresses = new ArrayList<>(shadowUnresolvedAddresses); 525 streetDict = new HashMap<>(shadowStreetDict); 526 526 // remove temp data 527 527 shadowStreetDict.clear(); … … 568 568 public void attachToDataSet(Collection<? extends OsmPrimitive> osmDataToWorkOn) { 569 569 if (osmDataToWorkOn != null && !osmDataToWorkOn.isEmpty()) { 570 workingSet = new ArrayList< OsmPrimitive>(osmDataToWorkOn);570 workingSet = new ArrayList<>(osmDataToWorkOn); 571 571 } else { 572 572 detachFromDataSet(); // drop old stuff, if present … … 643 643 CheckParameterUtil.ensureParameterNotNull(entity, "entity"); 644 644 645 List<IProblem> problemsToRemove = new ArrayList< IProblem>();645 List<IProblem> problemsToRemove = new ArrayList<>(); 646 646 for (IProblem problem : problems) { 647 647 if (problem.getSource() == entity) { … … 673 673 if (maxEntries < 1) maxEntries = 1; 674 674 675 List<StreetScore> scores = new ArrayList< StreetScore>();676 List<String> matches = new ArrayList< String>();675 List<StreetScore> scores = new ArrayList<>(); 676 List<String> matches = new ArrayList<>(); 677 677 678 678 // Find the longest common sub string -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/AddressProblem.java
r30348 r30737 56 56 private void lazyCreateSolutions() { 57 57 if (solutions == null) { 58 solutions = new ArrayList< ISolution>();58 solutions = new ArrayList<>(); 59 59 } 60 60 } -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/GuessAddressRunnable.java
r30348 r30737 25 25 public class GuessAddressRunnable extends PleaseWaitRunnable { 26 26 private List<OSMAddress> addressesToGuess; 27 private List<IProgressMonitorFinishedListener> finishListeners = new ArrayList< IProgressMonitorFinishedListener>();27 private List<IProgressMonitorFinishedListener> finishListeners = new ArrayList<>(); 28 28 private boolean isRunning = false; 29 29 private boolean canceled; 30 30 31 private GuessedValueHandler[] wayGuessers = new GuessedValueHandler[]{new GuessStreetValueHandler(TagUtils.ADDR_STREET_TAG)}; 31 private GuessedValueHandler[] wayGuessers = new GuessedValueHandler[]{new GuessStreetValueHandler(TagUtils.ADDR_STREET_TAG)}; 32 32 private GuessedValueHandler[] nodeGuessers = new GuessedValueHandler[]{ 33 33 new GuessedValueHandler(TagUtils.ADDR_POSTCODE_TAG, 500.0), … … 99 99 protected void fireFinished() { 100 100 for (IProgressMonitorFinishedListener l : finishListeners) { 101 l.finished(); 101 l.finished(); 102 102 } 103 103 // this event is fired only once, then we disconnect all listeners … … 130 130 progressMonitor.setTicksCount(addressesToGuess.size()); 131 131 132 List<OSMAddress> shadowCopy = new ArrayList< OSMAddress>(addressesToGuess);132 List<OSMAddress> shadowCopy = new ArrayList<>(addressesToGuess); 133 133 for (OSMAddress aNode : shadowCopy) { 134 134 if (!aNode.needsGuess()) { // nothing to do … … 148 148 for (int i = 0; i < wayGuessers.length; i++) { 149 149 GuessedValueHandler guesser = wayGuessers[i]; 150 150 151 151 guesser.setAddressNode(aNode); 152 152 … … 156 156 break; 157 157 } 158 way.accept(guesser); 159 } 160 158 way.accept(guesser); 159 } 160 161 161 String guessedVal = guesser.getCurrentValue(); 162 162 if (guessedVal != null) { … … 164 164 } 165 165 } 166 166 167 167 // Run node-related guessers 168 168 for (int i = 0; i < nodeGuessers.length; i++) { 169 169 GuessedValueHandler guesser = nodeGuessers[i]; 170 170 171 171 guesser.setAddressNode(aNode); 172 172 … … 176 176 break; 177 177 } 178 node.accept(guesser); 179 } 180 178 node.accept(guesser); 179 } 180 181 181 String guessedVal = guesser.getCurrentValue(); 182 182 if (guessedVal != null) { … … 214 214 OSMAddress aNode = getAddressNode(); 215 215 String newVal = TagUtils.getNameValue(w); 216 216 217 217 if (newVal != null) { 218 218 double dist = OsmUtils.getMinimumDistanceToWay(aNode.getCoor(), w); 219 219 220 220 if (dist < minDist && dist < getMaxDistance()) { 221 221 minDist = dist; -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/OSMAddress.java
r30348 r30737 27 27 28 28 /** The dictionary containing guessed values. */ 29 private HashMap<String, String> guessedValues = new HashMap< String, String>();29 private HashMap<String, String> guessedValues = new HashMap<>(); 30 30 /** The dictionary containing guessed objects. */ 31 private HashMap<String, OsmPrimitive> guessedObjects = new HashMap< String, OsmPrimitive>();31 private HashMap<String, OsmPrimitive> guessedObjects = new HashMap<>(); 32 32 /** The dictionary containing indirect values. */ 33 private HashMap<String, String> derivedValues = new HashMap< String, String>();33 private HashMap<String, String> derivedValues = new HashMap<>(); 34 34 35 35 public OSMAddress(OsmPrimitive osmObject) { … … 49 49 * Checks if the underlying address node has all tags usually needed to 50 50 * describe an address. 51 * 51 * 52 52 * @return 53 53 */ … … 72 72 /** 73 73 * Gets the name of the street associated with this address. 74 * 74 * 75 75 * @return 76 76 */ … … 83 83 * this method looks for an appropriate guess. If both, real value and 84 84 * guess, are missing, a question mark is returned. 85 * 85 * 86 86 * @param tag 87 87 * the tag … … 115 115 /** 116 116 * Returns <tt>true</tt>, if this address node has a street name. 117 * 117 * 118 118 * @return 119 119 */ … … 124 124 /** 125 125 * Returns the street name guessed by the nearest-neighbor search. 126 * 126 * 127 127 * @return the guessedStreetName 128 128 */ … … 133 133 /** 134 134 * Sets the guessed street name. 135 * 135 * 136 136 * @param guessedStreetName 137 137 * the guessedStreetName to set … … 146 146 /** 147 147 * Checks for a guessed street name. 148 * 148 * 149 149 * @return true, if this instance has a guessed street name. 150 150 */ … … 162 162 /** 163 163 * Sets the guessed post code. 164 * 164 * 165 165 * @param guessedPostCode 166 166 * the guessedPostCode to set … … 174 174 /** 175 175 * Checks for a guessed post code. 176 * 176 * 177 177 * @return true, if this instance has a guessed post code. 178 178 */ … … 190 190 /** 191 191 * Sets the guessed city. 192 * 192 * 193 193 * @param guessedCity 194 194 * the guessedCity to set … … 202 202 /** 203 203 * Checks for a guessed city name. 204 * 204 * 205 205 * @return true, if this instance has a guessed city name. 206 206 */ … … 211 211 /** 212 212 * Returns true, if this instance has guesses regarding address tags. 213 * 213 * 214 214 * @return 215 215 */ … … 233 233 /** 234 234 * Apply the guessed value for the given tag. 235 * 235 * 236 236 * @param tag 237 237 * the tag to apply the guessed value for. … … 248 248 /** 249 249 * Gets the name of the post code associated with this address. 250 * 250 * 251 251 * @return 252 252 */ … … 263 263 /** 264 264 * Checks if this instance has a valid postal code. 265 * 265 * 266 266 * @return true, if successful 267 267 */ … … 272 272 /** 273 273 * Checks for post code tag. 274 * 274 * 275 275 * @return true, if successful 276 276 */ … … 281 281 /** 282 282 * Gets the name of the house number associated with this address. 283 * 283 * 284 284 * @return 285 285 */ … … 297 297 /** 298 298 * Checks for house number. 299 * 299 * 300 300 * @return true, if successful 301 301 */ … … 305 305 } 306 306 307 public String getName() { 307 @Override 308 public String getName() { 308 309 String name = TagUtils.getNameValue(osmObject); 309 310 if (!StringUtils.isNullOrEmpty(name)) { … … 316 317 /** 317 318 * Checks if this address is part of a address interpolation. 318 * 319 * 319 320 * @return true, if is part of interpolation 320 321 */ … … 325 326 /** 326 327 * Checks if this address is part of an 'associated street' relation. 327 * 328 * 328 329 * @return true, if is part of interpolation 329 330 */ … … 334 335 /** 335 336 * Gets the name of the city associated with this address. 336 * 337 * 337 338 * @return 338 339 */ … … 343 344 /** 344 345 * Checks for city tag. 345 * 346 * 346 347 * @return true, if a city tag is present or available via referrer. 347 348 */ … … 352 353 /** 353 354 * Gets the name of the state associated with this address. 354 * 355 * 355 356 * @return 356 357 */ … … 361 362 /** 362 363 * Checks for state tag. 363 * 364 * 364 365 * @return true, if a state tag is present or available via referrer. 365 366 */ … … 370 371 /** 371 372 * Gets the name of the country associated with this address. 372 * 373 * 373 374 * @return 374 375 */ … … 379 380 /** 380 381 * Checks for country tag. 381 * 382 * 382 383 * @return true, if a country tag is present or available via referrer. 383 384 */ … … 401 402 * Checks if the associated OSM object has the given tag or if the tag is 402 403 * available via a referrer. 403 * 404 * 404 405 * @param tag 405 406 * the tag to look for. … … 467 468 /** 468 469 * Applies the street name from the specified street node. 469 * 470 * 470 471 * @param node 471 472 */ … … 483 484 /** 484 485 * Gets the guessed value for the given tag. 485 * 486 * 486 487 * @param tag 487 488 * The tag to get the guessed value for. … … 499 500 /** 500 501 * Gets the guessed object. 501 * 502 * 502 503 * @param tag 503 504 * the guessed tag … … 516 517 * Gets all guessed objects or an empty list, if no guesses have been made 517 518 * yet. 518 * 519 * 519 520 * @return the guessed objects. 520 521 */ … … 529 530 * Check if this instance needs guessed values. This is the case, if the 530 531 * underlying OSM node has either no street name, post code or city. 531 * 532 * 532 533 * @return true, if this instance needs at least one guessed value. 533 534 */ … … 542 543 /** 543 544 * Check if this instance needs guessed value for a given tag. 544 * 545 * 545 546 * @return true, if successful 546 547 */ … … 559 560 * Checks if given tag has a guessed value (tag exists and has a non-empty 560 561 * value). 561 * 562 * 562 563 * @param tag 563 564 * the tag … … 573 574 /** 574 575 * Sets the guessed value with the given tag. 575 * 576 * 576 577 * @param tag 577 578 * the tag to set the guess for … … 596 597 * Checks if given tag has a derived value (value is available via a 597 598 * referrer). 598 * 599 * 599 600 * @param tag 600 601 * the tag … … 610 611 /** 611 612 * Returns true, if this instance has derived values from any referrer. 612 * 613 * 613 614 * @return 614 615 */ … … 619 620 /** 620 621 * Gets the derived value for the given tag. 621 * 622 * 622 623 * @param tag 623 624 * The tag to get the derived value for. … … 633 634 /** 634 635 * Sets the value known indirectly via a referrer with the given tag. 635 * 636 * 636 637 * @param tag 637 638 * the tag to set the derived value for … … 645 646 /** 646 647 * Sets the street name of the address node. 647 * 648 * 648 649 * @param streetName 649 650 */ … … 657 658 /** 658 659 * Sets the state of the address node. 659 * 660 * 660 661 * @param state 661 662 */ … … 669 670 /** 670 671 * Sets the country of the address node. 671 * 672 * 672 673 * @param country 673 674 */ … … 681 682 /** 682 683 * Sets the post code of the address node. 683 * 684 * 684 685 * @param postCode 685 686 */ … … 755 756 /** 756 757 * Adds the guess value solution to a problem. 757 * 758 * 758 759 * @param p 759 760 * the problem to add the solution to. … … 771 772 /** 772 773 * Adds the remove address tags solution entry to a problem. 773 * 774 * 774 775 * @param problem 775 776 * the problem … … 790 791 /** 791 792 * Gets the formatted string representation of the given node. 792 * 793 * 793 794 * @param node 794 795 * the node -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/OSMEntityBase.java
r30348 r30737 28 28 public class OSMEntityBase implements IOSMEntity, Comparable<IOSMEntity> { 29 29 public static final String ANONYMOUS = tr("No name"); 30 private static List<IAddressEditContainerListener> containerListeners = new ArrayList< IAddressEditContainerListener>();31 private List<ICommandListener> cmdListeners = new ArrayList< ICommandListener>();30 private static List<IAddressEditContainerListener> containerListeners = new ArrayList<>(); 31 private List<ICommandListener> cmdListeners = new ArrayList<>(); 32 32 33 33 protected OsmPrimitive osmObject; … … 81 81 * @param listener 82 82 */ 83 public void addCommandListener(ICommandListener listener) { 83 @Override 84 public void addCommandListener(ICommandListener listener) { 84 85 CheckParameterUtil.ensureParameterNotNull(listener, "listener"); 85 86 cmdListeners.add(listener); … … 90 91 * @param listener 91 92 */ 92 public void removeCommandListener(ICommandListener listener) { 93 @Override 94 public void removeCommandListener(ICommandListener listener) { 93 95 CheckParameterUtil.ensureParameterNotNull(listener, "listener"); 94 96 cmdListeners.remove(listener); … … 112 114 } 113 115 114 public OsmPrimitive getOsmObject() { 116 @Override 117 public OsmPrimitive getOsmObject() { 115 118 return osmObject; 116 119 } … … 148 151 protected void setOSMTag(String tag, String newValue) { 149 152 CheckParameterUtil.ensureParameterNotNull(tag, "tag"); 150 153 151 154 152 155 if (osmObject != null) { … … 156 159 return; 157 160 } 158 161 159 162 if ((osmObject.hasKey(tag) && newValue == null) || newValue != null) { 160 163 fireCommandIssued(new ChangePropertyCommand(osmObject, tag, newValue)); -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/OSMStreet.java
r30348 r30737 26 26 } 27 27 28 public List<IOSMEntity> getChildren() { 28 @Override 29 public List<IOSMEntity> getChildren() { 29 30 return children; 30 31 } … … 46 47 private void lazyCreateChildren() { 47 48 if (children == null) { 48 children = new ArrayList< IOSMEntity>();49 children = new ArrayList<>(); 49 50 } 50 51 } … … 65 66 private void lazyCreateAddresses() { 66 67 if (addresses == null) { 67 addresses = new ArrayList< OSMAddress>();68 addresses = new ArrayList<>(); 68 69 } 69 70 } … … 118 119 */ 119 120 public String getType() { 120 List<String> types = new ArrayList< String>();121 List<String> types = new ArrayList<>(); 121 122 122 123 for (IOSMEntity seg : getChildren()) { -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/OsmFactory.java
r30348 r30737 8 8 9 9 public class OsmFactory { 10 private static HashMap<String, OSMAddress> addressCache = new HashMap< String, OSMAddress>();10 private static HashMap<String, OSMAddress> addressCache = new HashMap<>(); 11 11 12 12 /** -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/PostalCodeChecker.java
r30348 r30737 11 11 */ 12 12 public class PostalCodeChecker { 13 private static HashMap<String, String> postalCodePatternMap = new HashMap< String, String>();13 private static HashMap<String, String> postalCodePatternMap = new HashMap<>(); 14 14 15 15 static { -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/AddressEditModel.java
r30348 r30737 10 10 import javax.swing.tree.TreeNode; 11 11 12 import org.openstreetmap.josm.plugins.fixAddresses.IOSMEntity; 12 13 import org.openstreetmap.josm.plugins.fixAddresses.OSMAddress; 13 import org.openstreetmap.josm.plugins.fixAddresses.IOSMEntity;14 14 import org.openstreetmap.josm.plugins.fixAddresses.OSMStreet; 15 15 … … 17 17 private List<OSMStreet> streets; 18 18 private List<OSMAddress> unresolvedAddresses; 19 private List<OSMAddress> incompleteAddresses = new ArrayList< OSMAddress>();19 private List<OSMAddress> incompleteAddresses = new ArrayList<>(); 20 20 private DefaultMutableTreeNode streetRoot; 21 21 private DefaultMutableTreeNode unresolvedRoot; -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/AddressEditSelectionEvent.java
r30348 r30737 153 153 int[] selRows = unresolvedAddressTable.getSelectedRows(); 154 154 155 unresolvedCache = new ArrayList< OSMAddress>();155 unresolvedCache = new ArrayList<>(); 156 156 for (int i = 0; i < selRows.length; i++) { 157 157 if (selRows[i] >= 0 && selRows[i] < addressContainer.getNumberOfUnresolvedAddresses()) { … … 177 177 int[] selRows = incompleteAddressTable.getSelectedRows(); 178 178 179 incompleteCache = new ArrayList< OSMAddress>();179 incompleteCache = new ArrayList<>(); 180 180 for (int i = 0; i < selRows.length; i++) { 181 181 if (selRows[i] >= 0 && selRows[i] < addressContainer.getNumberOfIncompleteAddresses()) { -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/IncompleteAddressesDialog.java
r30348 r30737 64 64 incompleteAddr.getSelectionModel().addListSelectionListener(this); 65 65 66 LinkedList<SideButton> buttons = new LinkedList< SideButton>();66 LinkedList<SideButton> buttons = new LinkedList<>(); 67 67 // Link actions with address container 68 68 for (AbstractAddressEditAction action : actions) { -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/actions/AbstractAddressEditAction.java
r30348 r30737 166 166 } 167 167 168 commands = new ArrayList< Command>();168 commands = new ArrayList<>(); 169 169 if (StringUtils.isNullOrEmpty(txName)) { 170 170 throw new RuntimeException("Transaction must have a name"); -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/actions/ApplyAllGuessesAction.java
r30348 r30737 13 13 14 14 import org.openstreetmap.josm.plugins.fixAddresses.AddressEditContainer; 15 import org.openstreetmap.josm.plugins.fixAddresses.IOSMEntity; 15 16 import org.openstreetmap.josm.plugins.fixAddresses.OSMAddress; 16 import org.openstreetmap.josm.plugins.fixAddresses.IOSMEntity;17 17 import org.openstreetmap.josm.plugins.fixAddresses.StringUtils; 18 18 import org.openstreetmap.josm.plugins.fixAddresses.gui.AddressEditSelectionEvent; … … 70 70 private void applyGuesses(List<OSMAddress> addrToFix) { 71 71 beginTransaction(tr("Applied guessed values")); 72 List<OSMAddress> addrToFixShadow = new ArrayList< OSMAddress>(addrToFix);72 List<OSMAddress> addrToFixShadow = new ArrayList<>(addrToFix); 73 73 for (OSMAddress aNode : addrToFixShadow) { 74 74 beginObjectTransaction(aNode); -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/actions/SelectAddressesInMapAction.java
r30348 r30737 62 62 if (addrToSel == null) return; 63 63 64 List<OsmPrimitive> sel = new ArrayList< OsmPrimitive>();64 List<OsmPrimitive> sel = new ArrayList<>(); 65 65 66 66 getCurrentDataSet().clearSelection(); -
applications/editors/josm/plugins/FixAddresses/src/org/openstreetmap/josm/plugins/fixAddresses/gui/actions/SelectIncompleteAddressesAction.java
r30348 r30737 30 30 31 31 if (addressEditContainer.getIncompleteAddresses() != null) { 32 List<OsmPrimitive> osms = new ArrayList< OsmPrimitive>();32 List<OsmPrimitive> osms = new ArrayList<>(); 33 33 34 34 for (OSMAddress aNode : addressEditContainer.getIncompleteAddresses()) {
Note:
See TracChangeset
for help on using the changeset viewer.