Examples of GpxImporter


Examples of org.openstreetmap.josm.io.GpxImporter

    });
    return cargar;
  }

  private void cargarGpx(File file) throws IOException {
    GpxImporter importer = new GpxImporter();
    if (!importer.acceptFile(file)) {
      new IOException("Gpx inaccesible.");
    }
    final String absolutePath = file.getAbsolutePath();

    for (Layer l : capasActuales) {
      if (l.name.equals(file.getAbsolutePath()))
        return;
    }

    importer.importData(file);
    GpxLayer layer = new MyGpxLayer(importer.getLastData(), absolutePath,
        this.mapView);

    Main.pref.putColor("layer " + layer.name,
        Color.decode(LogicConstants.getNextColor()));
    addCapa(layer);
View Full Code Here

Examples of org.openstreetmap.josm.io.GpxImporter

    }
    return file;
  }

  private GpxLayer cargarGpx(File file, String name) {
    GpxImporter importer = new GpxImporter();
    GpxLayer layer = null;
    try {
      if (!importer.acceptFile(file)) {
        new IOException("Gpx inaccesible.");
      }
      importer.importData(file);
      layer = new MyGpxLayer(importer.getLastData(),
          file.getAbsolutePath(), true, this.mapView);
      layer.name = name;
      addCapa(layer);
    } catch (Throwable t) {
      log.error("Error al cargar la capa", t);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.