Ignore:
Timestamp:
2014-10-18T23:07:52+02:00 (11 years ago)
Author:
donvip
Message:

[josm_plugins] fix Java 7 / unused code warnings

Location:
applications/editors/josm/plugins/OsmInspectorPlugin/src/org/openstreetmap/josm/plugins/osminspector
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/OsmInspectorPlugin/src/org/openstreetmap/josm/plugins/osminspector/GeoFabrikWFSClient.java

    r30701 r30737  
    9595                String getCapabilities = "http://tools.geofabrik.de/osmi/view/routing_non_eu/wxs?SERVICE=WFS&VERSION=1.0.0&REQUEST=GetCapabilities";
    9696                @SuppressWarnings("rawtypes")
    97                 Map<String, Comparable> connectionParameters = new HashMap<String, Comparable>();
     97                Map<String, Comparable> connectionParameters = new HashMap<>();
    9898                connectionParameters.put("WFSDataStoreFactory:GET_CAPABILITIES_URL",
    9999                                getCapabilities);
  • applications/editors/josm/plugins/OsmInspectorPlugin/src/org/openstreetmap/josm/plugins/osminspector/OSMIFeatureTracker.java

    r29854 r30737  
    1616        public OSMIFeatureTracker(
    1717                        FeatureCollection<SimpleFeatureType, SimpleFeature> featuresIn) {
    18                 hashFeatures = new HashMap<Long, SimpleFeature>();
     18                hashFeatures = new HashMap<>();
    1919                features = new MemoryFeatureCollection(featuresIn.getSchema());
    2020
  • applications/editors/josm/plugins/OsmInspectorPlugin/src/org/openstreetmap/josm/plugins/osminspector/OsmInspectorLayer.java

    r29854 r30737  
    200200
    201201                        bugId = idx;
    202                         attributes = new HashMap<String, String>();
     202                        attributes = new HashMap<>();
    203203                        Collection<Property> properties = next.getProperties();
    204204                        Iterator<Property> it = properties.iterator();
     
    261261
    262262                public BugIndex(Map<BugInfo, Long> bugs) {
    263                         osmBugs = new ArrayList<BugInfo>(bugs.keySet());
     263                        osmBugs = new ArrayList<>(bugs.keySet());
    264264                        nextIndex = 0;
    265265                        previousIndex = -1;
     
    267267
    268268                public BugIndex(Map<BugInfo, Long> bugs, int n, int p) {
    269                         osmBugs = new ArrayList<BugInfo>(bugs.keySet());
     269                        osmBugs = new ArrayList<>(bugs.keySet());
    270270                        nextIndex = n;
    271271                        previousIndex = p;
     
    345345                super("OsmInspector");
    346346
    347                 arrFeatures = new ArrayList<OSMIFeatureTracker>();
    348                 osmiBugInfo = new LinkedHashMap<BugInfo, Long>();
    349                 selectGeomType = new ArrayList<GeomType>();
     347                arrFeatures = new ArrayList<>();
     348                osmiBugInfo = new LinkedHashMap<>();
     349                selectGeomType = new ArrayList<>();
    350350
    351351                // Step 3 - discovery; enhance to iterate over all types with bounds
     
    360360                for (int idx = 1; idx < typeNames.length; ++idx) {
    361361                        String typeName = typeNames[idx];
    362                         Set<FeatureId> selectedFeatures = new HashSet<FeatureId>();
     362                        Set<FeatureId> selectedFeatures = new HashSet<>();
    363363
    364364                        FeatureCollection<SimpleFeatureType, SimpleFeature> features = wfsClient
     
    417417                for (int idx = 1; idx < typeNames.length; ++idx) {
    418418                        String typeName = typeNames[idx];
    419                         Set<FeatureId> selectedFeatures = new HashSet<FeatureId>();
     419                        Set<FeatureId> selectedFeatures = new HashSet<>();
    420420
    421421                        monitor.setProgress(100 / typeNames.length * idx);
     
    621621                                FeatureIterator<SimpleFeature> iter = selectedFeatures
    622622                                                .features();
    623                                 Set<FeatureId> IDs = new HashSet<FeatureId>();
     623                                Set<FeatureId> IDs = new HashSet<>();
    624624
    625625                                System.out.println("Selected features "
Note: See TracChangeset for help on using the changeset viewer.