Ignore:
Timestamp:
2013-09-22T18:36:07+02:00 (11 years ago)
Author:
Don-vip
Message:

Sonar/FindBugs - various bugfixes / violation fixes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/dialogs/properties/TagEditHelper.java

    r6113 r6246  
    3838import java.util.List;
    3939import java.util.Map;
    40 import java.util.Vector;
    4140
    4241import javax.swing.AbstractAction;
     
    374373                    }
    375374                }
    376                 Collection<Command> commands=new Vector<Command>();
     375                Collection<Command> commands = new ArrayList<Command>();
    377376                commands.add(new ChangePropertyCommand(sel, key, null));
    378377                if (value.equals(tr("<different>"))) {
    379                     HashMap<String, Vector<OsmPrimitive>> map=new HashMap<String, Vector<OsmPrimitive>>();
     378                    Map<String, ArrayList<OsmPrimitive>> map = new HashMap<String, ArrayList<OsmPrimitive>>();
    380379                    for (OsmPrimitive osm: sel) {
    381                         String val=osm.get(key);
    382                         if(val != null)
    383                         {
     380                        String val = osm.get(key);
     381                        if (val != null) {
    384382                            if (map.containsKey(val)) {
    385383                                map.get(val).add(osm);
    386384                            } else {
    387                                 Vector<OsmPrimitive> v = new Vector<OsmPrimitive>();
     385                                ArrayList<OsmPrimitive> v = new ArrayList<OsmPrimitive>();
    388386                                v.add(osm);
    389387                                map.put(val, v);
     
    391389                        }
    392390                    }
    393                     for (Map.Entry<String, Vector<OsmPrimitive>> e: map.entrySet()) {
     391                    for (Map.Entry<String, ArrayList<OsmPrimitive>> e: map.entrySet()) {
    394392                        commands.add(new ChangePropertyCommand(e.getValue(), newkey, e.getKey()));
    395393                    }
Note: See TracChangeset for help on using the changeset viewer.