Package ch.epfl.lbd.etl.extractors

Examples of ch.epfl.lbd.etl.extractors.TrajectoryExtractor


public class ETLStage extends Tester {
  public static void main(String[] args){
    //create ETL internal stages
    POILoader     load_POI = new POILoader();
    RAWGPSLoader   load_GPS = new RAWGPSLoader();
    TrajectoryExtractor extract_TRAJECTORIES = new TrajectoryExtractor();
   
    //run stages
    try{
      //Transfer POI table
      //Load POI Table
      //load_POI.run();
     
      //Transfer GPS RAW data table
      //Load GPS Raw Points
      //load_GPS.run();
     
      //create GPS geometries
      /*PostgreSqlConnection destinationConnection = new PostgreSqlConnection("connections.properties","connection4");
      destinationConnection.openConnection();
      DecimalFormat twoPlaces = new DecimalFormat("0.00");
      double i = 0;
      /String query = "update milan_gmd3 SET geom = geomfromtext ('POINT(' || latitude || ' ' || longitude || ')',4030) where geom is null limit 100";
      while(true){
        i++;
        destinationConnection.executeSQLQuery(query);
        System.out.println(twoPlaces.format((i/2075213)*100)+"% done...");
      }*/
     
      //create POI geometries
      /*PostgreSqlConnection destinationConnection = new PostgreSqlConnection("connections.properties","connection4");
      destinationConnection.openConnection();
      DecimalFormat twoPlaces = new DecimalFormat("0.00");
      double i = 0;
      int rows = 39776;
      String query = "update milan_map_poi SET geom = geomfromtext ('POINT(' || latitude || ' ' || longitude || ')',4030) where geom is null";
      System.out.println("running query");
      destinationConnection.executeSQLQuery(query);
      System.out.println("query ended");*/
     
      //create and populate trajectories
      extract_TRAJECTORIES.run();
    }
    catch(Exception e){
      e.printStackTrace();
    }
   
View Full Code Here

TOP

Related Classes of ch.epfl.lbd.etl.extractors.TrajectoryExtractor

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.