diff --git a/src/inputCodeBeautifier/BlankLineRemover.java b/src/codeBeautifier/BlankLineRemover.java similarity index 91% rename from src/inputCodeBeautifier/BlankLineRemover.java rename to src/codeBeautifier/BlankLineRemover.java index 01d4636..54c9f57 100644 --- a/src/inputCodeBeautifier/BlankLineRemover.java +++ b/src/codeBeautifier/BlankLineRemover.java @@ -1,4 +1,4 @@ -package inputCodeBeautifier; +package codeBeautifier; import java.util.ArrayList; diff --git a/src/inputCodeBeautifier/CmdExecutor.java b/src/codeBeautifier/CmdExecutor.java similarity index 98% rename from src/inputCodeBeautifier/CmdExecutor.java rename to src/codeBeautifier/CmdExecutor.java index 331e887..3c9c2c8 100644 --- a/src/inputCodeBeautifier/CmdExecutor.java +++ b/src/codeBeautifier/CmdExecutor.java @@ -1,4 +1,4 @@ -package inputCodeBeautifier; +package codeBeautifier; import java.io.BufferedReader; import java.io.BufferedWriter; diff --git a/src/inputCodeBeautifier/CodeBeautifier.java b/src/codeBeautifier/CodeBeautifier.java similarity index 97% rename from src/inputCodeBeautifier/CodeBeautifier.java rename to src/codeBeautifier/CodeBeautifier.java index 956e3ac..cfac1ca 100644 --- a/src/inputCodeBeautifier/CodeBeautifier.java +++ b/src/codeBeautifier/CodeBeautifier.java @@ -1,4 +1,4 @@ -package inputCodeBeautifier; +package codeBeautifier; import java.io.File; import java.util.ArrayList; diff --git a/src/inputCodeBeautifier/CommentRemover.java b/src/codeBeautifier/CommentRemover.java similarity index 98% rename from src/inputCodeBeautifier/CommentRemover.java rename to src/codeBeautifier/CommentRemover.java index 8e88583..1b93595 100644 --- a/src/inputCodeBeautifier/CommentRemover.java +++ b/src/codeBeautifier/CommentRemover.java @@ -1,4 +1,4 @@ -package inputCodeBeautifier; +package codeBeautifier; import java.util.ArrayList; diff --git a/src/inputCodeBeautifier/LineRemover.java b/src/codeBeautifier/LineRemover.java similarity index 98% rename from src/inputCodeBeautifier/LineRemover.java rename to src/codeBeautifier/LineRemover.java index 7c0b2c8..c8170af 100644 --- a/src/inputCodeBeautifier/LineRemover.java +++ b/src/codeBeautifier/LineRemover.java @@ -1,4 +1,4 @@ -package inputCodeBeautifier; +package codeBeautifier; import java.io.File; import java.io.IOException; diff --git a/src/codeBeautifier/package-info.java b/src/codeBeautifier/package-info.java new file mode 100644 index 0000000..a04ffb2 --- /dev/null +++ b/src/codeBeautifier/package-info.java @@ -0,0 +1,8 @@ +/** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka + * + */ +package codeBeautifier; \ No newline at end of file diff --git a/src/controlFlowGraphBuilder/package-info.java b/src/controlFlowGraphBuilder/package-info.java index aa4ff5c..ca9f24a 100644 --- a/src/controlFlowGraphBuilder/package-info.java +++ b/src/controlFlowGraphBuilder/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed - * - */ package controlFlowGraphBuilder; \ No newline at end of file diff --git a/src/database/package-info.java b/src/database/package-info.java index ea2187b..7070f5f 100644 --- a/src/database/package-info.java +++ b/src/database/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ package database; \ No newline at end of file diff --git a/src/inputCodeBeautifier/package-info.java b/src/inputCodeBeautifier/package-info.java deleted file mode 100644 index 8698f6b..0000000 --- a/src/inputCodeBeautifier/package-info.java +++ /dev/null @@ -1,8 +0,0 @@ -/** - * - */ -/** - * @author Sajed49 - * - */ -package inputCodeBeautifier; \ No newline at end of file diff --git a/src/io/package-info.java b/src/io/package-info.java index 1fa3890..ab9ff7f 100644 --- a/src/io/package-info.java +++ b/src/io/package-info.java @@ -1,11 +1,8 @@ -/** - * - */ /** * @author Sajed Jalil - * @mail bsse0714@iit.du.ac.bd - * @university University of Dhaka + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * - * */ package io; \ No newline at end of file diff --git a/src/main/MainController.java b/src/main/MainController.java index d02f24a..cdeea2a 100644 --- a/src/main/MainController.java +++ b/src/main/MainController.java @@ -18,7 +18,7 @@ public class MainController { @FXML Button openResultButton; @FXML Text openFilePath; - @FXML ProgressBar runProgress; + public @FXML ProgressBar runProgress; @FXML Text resultDirectory; @FXML @@ -47,8 +47,9 @@ private void selectFiles() { @FXML private void runFiles() { + runProgress.setProgress(0.0); Start.run(); - + runProgress.setProgress(1.0); runButton.setText("Re-Run"); openResultButton.setVisible(true); diff --git a/src/main/Start.java b/src/main/Start.java index c88e3ed..5bdf2fa 100644 --- a/src/main/Start.java +++ b/src/main/Start.java @@ -15,8 +15,8 @@ import java.util.ArrayList; import java.util.Comparator; +import codeBeautifier.CodeBeautifier; import database.DatabaseLoader; -import inputCodeBeautifier.CodeBeautifier; import io.InputFileCopyMachine; public class Start extends Application{ @@ -35,8 +35,6 @@ public static void main(String[] args) { loadNecessaryStuffs(); - //System.out.println("E:"+'\\'+"GitHub"+'\\'+"C-Path-Finder"+'\\'+"test"); - //new DatabaseLoader(); launch(args); } @@ -83,23 +81,25 @@ public static void run(){ database(); - try { - Files.walk( Paths.get(outputPath) ).sorted(Comparator.reverseOrder()) - .map(Path::toFile) - .forEach(File::delete); - }catch (IOException e) { - e.printStackTrace(); - } new InputFileCopyMachine(inputPath, outputPath); + //for memorized execution dbloader.directorySearcher( new File(outputPath) ); new CodeBeautifier( new File(outputPath)); dbloader.loadIntoFileTable(); - + new CParser(dbloader.getChangedFiles()); dbloader.selectAllFile(); + + try { + Files.walk( Paths.get(outputPath) ).sorted(Comparator.reverseOrder()) + .map(Path::toFile) + .forEach(File::delete); + }catch (IOException e) { + e.printStackTrace(); + } } diff --git a/src/main/package-info.java b/src/main/package-info.java index f4832fc..e2b7967 100644 --- a/src/main/package-info.java +++ b/src/main/package-info.java @@ -1,8 +1,9 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ + package main; \ No newline at end of file diff --git a/src/parser/CParser.java b/src/parser/CParser.java index 3c1e096..082e1eb 100644 --- a/src/parser/CParser.java +++ b/src/parser/CParser.java @@ -23,7 +23,7 @@ public CParser(File file) { } public CParser(ArrayList changedFiles) { - + for(String s: changedFiles) { File file = new File(s); diff --git a/src/parser/components/package-info.java b/src/parser/components/package-info.java index 495bbf8..b473040 100644 --- a/src/parser/components/package-info.java +++ b/src/parser/components/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ package parser.components; \ No newline at end of file diff --git a/src/parser/package-info.java b/src/parser/package-info.java index 16d9c7c..d10a0df 100644 --- a/src/parser/package-info.java +++ b/src/parser/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ package parser; \ No newline at end of file diff --git a/src/result/package-info.java b/src/result/package-info.java index edb4dd2..e871775 100644 --- a/src/result/package-info.java +++ b/src/result/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ package result; \ No newline at end of file diff --git a/src/symbolicSolver/package-info.java b/src/symbolicSolver/package-info.java index f92a055..f82c989 100644 --- a/src/symbolicSolver/package-info.java +++ b/src/symbolicSolver/package-info.java @@ -1,8 +1,8 @@ /** + * @author Sajed Jalil + * @email bsse0714@iit.du.ac.bd + * @year 2018 + * @location Dhaka * */ -/** - * @author Sajed49 - * - */ package symbolicSolver; \ No newline at end of file