Ignore:
Timestamp:
2014-06-14T14:05:38+02:00 (11 years ago)
Author:
bastik
Message:

update to [josm7248]

Location:
applications/editors/josm/plugins/canvec_helper/src/org/openstreetmap/josm/plugins/canvec_helper
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/canvec_helper/src/org/openstreetmap/josm/plugins/canvec_helper/CanVecTile.java

    r29989 r30495  
    1313import org.openstreetmap.josm.gui.MapView;
    1414import org.openstreetmap.josm.io.IllegalDataException;
    15 import org.openstreetmap.josm.io.MirroredInputStream;
     15import org.openstreetmap.josm.io.CachedFile;
    1616import java.awt.Graphics2D;
    1717import java.awt.Polygon;
     
    183183                File download_path = new File(layer.plugin_self.getPluginDir() + File.separator);
    184184                download_path.mkdir();
    185                 MirroredInputStream tile_zip;
    186                 tile_zip = new MirroredInputStream(getDownloadUrl(),download_path.toString());
     185                CachedFile tile_zip = new CachedFile(getDownloadUrl()).setDestDir(download_path.toString());
    187186                return new ZipFile(tile_zip.getFile());
    188187        }
  • applications/editors/josm/plugins/canvec_helper/src/org/openstreetmap/josm/plugins/canvec_helper/CanvecLayer.java

    r29989 r30495  
    99import java.awt.Toolkit;
    1010import java.io.BufferedReader;
     11import java.io.InputStream;
    1112import java.io.InputStreamReader;
    1213import java.io.IOException;
     
    2728import org.openstreetmap.josm.gui.layer.Layer;
    2829import org.openstreetmap.josm.gui.MapView;
    29 import org.openstreetmap.josm.io.MirroredInputStream;
     30import org.openstreetmap.josm.io.CachedFile;
    3031import static org.openstreetmap.josm.tools.I18n.tr;
    3132
     
    5152                        long start = System.currentTimeMillis();
    5253                        Pattern p = Pattern.compile("(\\d\\d\\d)([A-Z]\\d\\d).*");
    53                         MirroredInputStream index = new MirroredInputStream("http://ftp2.cits.rncan.gc.ca/OSM/pub/ZippedOsm.txt");
     54                        InputStream index = new CachedFile("http://ftp2.cits.rncan.gc.ca/OSM/pub/ZippedOsm.txt").getInputStream();
    5455                        BufferedReader br = new BufferedReader(new InputStreamReader(index));
    5556                        String line;
Note: See TracChangeset for help on using the changeset viewer.