Ignore:
Timestamp:
2015-07-15T22:19:15+02:00 (10 years ago)
Author:
floscher
Message:

Move all API-URLs into the classes resposible for downloading from the respective parts

Also changed all accesses to MapillaryLayer.data to point to the Getter-method (encapsulation/data hiding).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/mapillary/test/unit/org/openstreetmap/josm/plugins/mapillary/MapillarySequenceDownloadThreadTest.java

    r31347 r31381  
    4848
    4949        ExecutorService ex = Executors.newSingleThreadExecutor();
    50         String url = String.format(
     50        String queryString = String.format(
    5151            Locale.UK,
    52             "%ssearch/s?max_lat=%.8f&max_lon=%.8f&min_lat=%.8f&min_lon=%.8f&limit=10&client_id=%s",
    53             MapillaryDownloader.BASE_URL,
     52            "?max_lat=%.8f&max_lon=%.8f&min_lat=%.8f&min_lon=%.8f&limit=10&client_id=%s",
    5453            maxLatLon.lat(),
    5554            maxLatLon.lon(),
     
    6362        while (!ex.isShutdown() && MapillaryLayer.getInstance().getMapillaryData().getImages().size() <= 0 && page < 50) {
    6463            System.out.println("Sending sequence-request "+page+" to Mapillary-servers…");
    65             Thread downloadThread = new MapillarySequenceDownloadThread(ex, url+"&page="+page, MapillaryLayer.getInstance(), null);
     64            Thread downloadThread = new MapillarySequenceDownloadThread(ex, queryString+"&page="+page, MapillaryLayer.getInstance(), null);
    6665            downloadThread.start();
    6766            downloadThread.join();
Note: See TracChangeset for help on using the changeset viewer.