Ignore:
Timestamp:
2017-08-23T00:34:13+02:00 (9 years ago)
Author:
donvip
Message:

fix #josm15178 - use new HTTPS links from French cadastre - requires JOSM 12623+ to load Certigna certificate from platform keystore (not included in JRE keystore)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/cadastre-fr/src/cadastre_fr/CadastreGrabber.java

    r33392 r33514  
    77import java.io.IOException;
    88import java.io.InputStream;
    9 import java.net.HttpURLConnection;
    109import java.net.MalformedURLException;
    1110import java.net.URL;
     
    1514import org.openstreetmap.josm.Main;
    1615import org.openstreetmap.josm.data.coor.EastNorth;
    17 import org.openstreetmap.josm.gui.progress.NullProgressMonitor;
    1816import org.openstreetmap.josm.io.OsmTransferException;
    19 import org.openstreetmap.josm.io.ProgressInputStream;
    2017
    2118public class CadastreGrabber {
     
    8683
    8784    private BufferedImage grab(URL url) throws IOException, OsmTransferException {
    88         wmsInterface.urlConn = (HttpURLConnection) url.openConnection();
    89         wmsInterface.urlConn.setRequestProperty("Connection", "close");
    90         wmsInterface.urlConn.setRequestMethod("GET");
    91         wmsInterface.setCookie();
    92         try (InputStream is = new ProgressInputStream(wmsInterface.urlConn, NullProgressMonitor.INSTANCE)) {
     85        try (InputStream is = wmsInterface.getContent(url)) {
    9386            return ImageIO.read(is);
    9487        }
Note: See TracChangeset for help on using the changeset viewer.