Changeset 4240 in josm for trunk/src/org/openstreetmap/josm/io/imagery
- Timestamp:
- 2011-07-14T12:48:27+02:00 (13 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/io/imagery
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/io/imagery/OsmosnimkiOffsetServer.java
r4126 r4240 26 26 public boolean isLayerSupported(ImageryInfo info) { 27 27 try { 28 URL url = new URL(this.url + "action=CheckAvailability&id=" + URLEncoder.encode(info.get FullUrl(), "UTF-8"));28 URL url = new URL(this.url + "action=CheckAvailability&id=" + URLEncoder.encode(info.getUrl(), "UTF-8")); 29 29 System.out.println(tr("Querying offset availability: {0}", url)); 30 30 final BufferedReader rdr = new BufferedReader(new InputStreamReader(url.openConnection().getInputStream(), "UTF-8")); … … 42 42 LatLon ll = Main.getProjection().eastNorth2latlon(en); 43 43 try { 44 URL url = new URL(this.url + "action=GetOffsetForPoint&lat=" + ll.lat() + "&lon=" + ll.lon() + "&id=" + URLEncoder.encode(info.get FullUrl(), "UTF-8"));44 URL url = new URL(this.url + "action=GetOffsetForPoint&lat=" + ll.lat() + "&lon=" + ll.lon() + "&id=" + URLEncoder.encode(info.getUrl(), "UTF-8")); 45 45 System.out.println(tr("Querying offset: {0}", url.toString())); 46 46 final BufferedReader rdr = new BufferedReader(new InputStreamReader(url.openConnection().getInputStream(), "UTF-8")); -
trunk/src/org/openstreetmap/josm/io/imagery/WMSGrabber.java
r4228 r4240 19 19 import java.text.NumberFormat; 20 20 import java.util.ArrayList; 21 import java.util.List; 21 22 import java.util.Map.Entry; 22 23 import java.util.Locale; … … 47 48 protected String baseURL; 48 49 private final boolean urlWithPatterns; 50 private List<String> serverProjections; 49 51 private Map<String, String> props = new HashMap<String, String>(); 50 52 … … 52 54 super(mv, layer); 53 55 this.baseURL = layer.getInfo().getUrl(); 56 this.serverProjections = layer.getServerProjections(); 54 57 /* URL containing placeholders? */ 55 58 urlWithPatterns = ImageryInfo.isUrlWithPatterns(baseURL); … … 139 142 } else { 140 143 str += "bbox=" + bbox 141 + srs142 + "&width=" + wi + "&height=" + ht;144 + srs 145 + "&width=" + wi + "&height=" + ht; 143 146 if (!(baseURL.endsWith("&") || baseURL.endsWith("?"))) { 144 147 System.out.println(tr("Warning: The base URL ''{0}'' for a WMS service doesn't have a trailing '&' or a trailing '?'.", baseURL));
Note:
See TracChangeset
for help on using the changeset viewer.