Changeset 31145 in osm
- Timestamp:
- 2015-05-24T22:49:30+02:00 (10 years ago)
- Location:
- applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/OsmTileLoader.java
r31077 r31145 41 41 42 42 InputStream input = null; 43 boolean force = false; 43 44 44 45 public void run() { … … 52 53 try { 53 54 URLConnection conn = loadTileFromOsm(tile); 55 if (force) { 56 conn.setUseCaches(false); 57 } 54 58 loadTileMetadata(tile, conn); 55 59 if ("no-tile".equals(tile.getValue("tile-info"))) { … … 89 93 @Override 90 94 public void submit() { 91 run();95 submit(false); 92 96 93 97 } 98 99 @Override 100 public void submit(boolean force) { 101 this.force = force; 102 run(); 103 } 104 94 105 }; 95 106 } … … 102 113 prepareHttpUrlConnection((HttpURLConnection)urlConn); 103 114 } 104 urlConn.setReadTimeout(30000); // 30 seconds read timeout105 115 return urlConn; 106 116 } -
applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/interfaces/TileJob.java
r31077 r31145 23 23 */ 24 24 void submit(); 25 26 /** 27 * submits download job to backend. 28 * @param true if the load should skip all the caches (local & remote) 29 */ 30 void submit(boolean force); 31 25 32 }
Note:
See TracChangeset
for help on using the changeset viewer.