Ignore:
Timestamp:
2015-06-20T23:42:21+02:00 (11 years ago)
Author:
Don-vip
Message:

checkstyle: enable relevant whitespace checks and fix them

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/imagery/WmsCache.java

    r8509 r8510  
    135135
    136136        for (Object propKey: layersIndex.keySet()) {
    137             String s = (String)propKey;
     137            String s = (String) propKey;
    138138            if (url.equals(layersIndex.getProperty(s))) {
    139139                cacheDirName = s;
     
    186186            WmsCacheType cacheEntries;
    187187            try (InputStream is = new FileInputStream(indexFile)) {
    188                 cacheEntries = (WmsCacheType)unmarshaller.unmarshal(is);
     188                cacheEntries = (WmsCacheType) unmarshaller.unmarshal(is);
    189189            }
    190190            totalFileSize = cacheEntries.getTotalFileSize();
     
    440440            drawAtLeastOnce = true;
    441441
    442             int xDiff = (int)((ce.east - east) * pixelPerDegree);
    443             int yDiff = (int)((ce.north - north) * pixelPerDegree);
    444             int size = (int)(pixelPerDegree / ce.pixelPerDegree  * tileSize);
     442            int xDiff = (int) ((ce.east - east) * pixelPerDegree);
     443            int yDiff = (int) ((ce.north - north) * pixelPerDegree);
     444            int size = (int) (pixelPerDegree / ce.pixelPerDegree  * tileSize);
    445445
    446446            int x = xDiff;
     
    467467        double deltaLat = Math.abs(ll3.lat() - ll1.lat());
    468468        double deltaLon = Math.abs(ll3.lon() - ll1.lon());
    469         int precisionLat = Math.max(0, -(int)Math.ceil(Math.log10(deltaLat)) + 1);
    470         int precisionLon = Math.max(0, -(int)Math.ceil(Math.log10(deltaLon)) + 1);
     469        int precisionLat = Math.max(0, -(int) Math.ceil(Math.log10(deltaLat)) + 1);
     470        int precisionLon = Math.max(0, -(int) Math.ceil(Math.log10(deltaLon)) + 1);
    471471
    472472        String zoom = SystemOfMeasurement.METRIC.getDistText(ll1.greatCircleDistance(ll2));
     
    493493            while (true) {
    494494                String result = String.format("%s_%." + precisionLat + "f_%." + precisionLon +"f%s.%s",
    495                         zoom, ll1.lat(), ll1.lon(), counter==0?"":"_" + counter, extension);
     495                        zoom, ll1.lat(), ll1.lon(), counter == 0 ? "" : "_" + counter, extension);
    496496                for (CacheEntry entry: projectionEntries.entries) {
    497497                    if (entry.filename.equals(result)) {
     
    528528            }
    529529            entry = new CacheEntry(pixelPerDegree, east, north,
    530                     tileSize,generateFileName(projectionEntries, pixelPerDegree, projection, east, north, mimeType));
     530                    tileSize, generateFileName(projectionEntries, pixelPerDegree, projection, east, north, mimeType));
    531531            entry.lastUsed = System.currentTimeMillis();
    532532            entry.lastModified = entry.lastUsed;
Note: See TracChangeset for help on using the changeset viewer.