Exemplo n.º 1
0
  public static void main(String[] args) throws SQLException {

    String dirPath = "src\\testInputFiles\\";

    File dir = new File(dirPath);
    File[] directoryListing = dir.listFiles();

    if (directoryListing != null) {
      for (File child : directoryListing) {
        System.out.println(
            "==========================================================================");
        System.out.println(child.getName());
        System.out.println(
            "==========================================================================");

        if ((child.getName().toLowerCase().equals("common.properties"))) {
          FileGrepper fg = new FileGrepper(new GreppedFile(child));
          fg.printTokenSet();
          // fg.printLineList();
          // fg.setTokensToDb();
          // fg.dbconn.get("*", "captionkey","");
        }
      }
    }
  }
Exemplo n.º 2
0
 public static void setTokensToDb(FileGrepper fg) throws SQLException {
   try {
     fg.setTokensToDb();
   } catch (SQLException ex) {
     Logger.getLogger(FileTokenizerTest.class.getName()).log(Level.SEVERE, null, ex);
   }
 }