Changeset 17509 in josm for trunk/src/org


Ignore:
Timestamp:
2021-02-21T16:10:35+01:00 (3 years ago)
Author:
wiktorn
Message:

Checkstyle fixes

Location:
trunk/src/org/openstreetmap/josm
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/cache/JCSCachedTileLoaderJob.java

    r17505 r17509  
    188188     * Simple implementation. All errors should be cached as empty. Though some JDK (JDK8 on Windows for example)
    189189     * doesn't return 4xx error codes, instead they do throw an FileNotFoundException or IOException
    190      * @param responseCode
    191      * @param headerFields
     190     * @param headerFields headers sent by server
     191     * @param responseCode http status code
    192192     *
    193193     * @return true if we should put empty object into cache, regardless of what remote resource has returned
  • trunk/src/org/openstreetmap/josm/data/imagery/TMSCachedTileLoaderJob.java

    r17505 r17509  
    136136        }
    137137        if (isNotImage(headers, statusCode)) {
    138             String message = detectErrorMessage( new String(content, StandardCharsets.UTF_8));
     138            String message = detectErrorMessage(new String(content, StandardCharsets.UTF_8));
    139139            if (message != null && !message.isEmpty()) {
    140140                tile.setError(message);
     
    148148        if (statusCode == 200 && headers.containsKey("Content-Type") && !headers.get("Content-Type").isEmpty()) {
    149149            String contentType = headers.get("Content-Type").stream().findAny().get();
    150             if (contentType !=null && !contentType.startsWith("image")) {
     150            if (contentType != null && !contentType.startsWith("image")) {
    151151                Logging.warn("Image not returned for tile: " + url + " content type was: " + contentType);
    152152                // not an image - do not store response in cache, so next time it will be queried again from the server
  • trunk/src/org/openstreetmap/josm/gui/layer/AbstractTileSourceLayer.java

    r17507 r17509  
    664664                Math.pow(2d, ZOOM_OFFSET.get()) * visibileTiles // use offset to decide, how many tiles are visible
    665665                * 8);
    666         Logging.info("AbstractTileSourceLayer: estimated tiles proccessed on current zoom level: {0}, estimated cache size: {1}", visibileTiles, ret);
     666        Logging.info("AbstractTileSourceLayer: estimated tiles proccessed on current zoom level: {0}, estimated cache size: {1}",
     667                visibileTiles, ret);
    667668        return ret;
    668669    }
     
    15981599            int[] otherZooms = {1, 2, -1, -2, -3, -4, -5};
    15991600
    1600             for(int otherZoom: otherZooms) {
     1601            for (int otherZoom: otherZooms) {
    16011602                missedTiles = tryLoadFromDifferentZoom(g, displayZoomLevel, missedTiles, otherZoom);
    16021603                if (missedTiles.isEmpty()) {
Note: See TracChangeset for help on using the changeset viewer.