Package weave.geometrystream

Examples of weave.geometrystream.GeometryStreamConverter


        importDBF(
            configConnectionName, password, fileNameWithoutExtension, sqlSchema, dbfTableName,
            sqlOverwrite, nullValues);
      }

      GeometryStreamConverter converter = new GeometryStreamConverter(new SQLGeometryStreamDestination(
          conn, sqlSchema, sqlTablePrefix, sqlOverwrite));
      for (String file : fileNameWithoutExtension)
      {
        // convert shape data to streaming sql format
        String shpfile = getUploadPath() + file + ".shp";
        SHPGeometryStreamUtils.convertShapefile(converter, shpfile, Arrays.asList(keyColumns));
      }
      converter.flushAndCommitAll();
    }
    catch (Exception e)
    {
      e.printStackTrace();
      throw new RemoteException("Shapefile import failed", e);
View Full Code Here


    String pass = "<PASSWORD>";
    String sqlSchema = "shp_convert";
    String sqlTablePrefix = "shptest";
   
    Connection conn = SQLUtils.getConnection(SQLUtils.getConnectString(dbms, ip, port, database, user, pass));
    GeometryStreamConverter converter = new GeometryStreamConverter(new SQLGeometryStreamDestination(conn, sqlSchema, sqlTablePrefix, true));
    for (String file : files)
      SHPGeometryStreamUtils.convertShapefile(converter, file, attributes);
    converter.flushAndCommitAll();
  }
View Full Code Here

TOP

Related Classes of weave.geometrystream.GeometryStreamConverter

Copyright © 2018 www.massapicom. 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.