diff --git a/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java b/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java index 2ed5a67d..a24a94d5 100644 --- a/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java +++ b/src/main/java/de/dhbwstuttgart/core/JavaTXCompiler.java @@ -44,12 +44,14 @@ import java.io.FileOutputStream; import java.io.FileWriter; import java.io.IOException; import java.io.Writer; +import java.io.OutputStreamWriter; import java.net.URL; import java.net.URLClassLoader; import java.util.*; import java.util.function.Function; import java.util.stream.Collectors; -//import org.apache.commons.io.output.NullOutputStream; +import org.apache.commons.io.output.NullOutputStream; + public class JavaTXCompiler { @@ -478,11 +480,11 @@ public class JavaTXCompiler { final ConstraintSet cons = getConstraints(); Set> results = new HashSet<>(); try { - Writer logFile = // new OutputStreamWriter(new NullOutputStream()); + Writer logFile = new OutputStreamWriter(new NullOutputStream()); // new FileWriter(new // File(System.getProperty("user.dir")+"/src/test/resources/logFiles/"+"log_"+sourceFiles.keySet().iterator().next().getName())); - new FileWriter(new File(System.getProperty("user.dir") + "/logFiles/" + "log_" - + sourceFiles.keySet().iterator().next().getName())); + //new FileWriter(new File(System.getProperty("user.dir") + "/logFiles/" + "log_" + // + sourceFiles.keySet().iterator().next().getName())); IFiniteClosure finiteClosure = UnifyTypeFactory.generateFC(allClasses, logFile, classLoader); System.out.println(finiteClosure); ConstraintSet unifyCons = UnifyTypeFactory.convert(cons); diff --git a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java index 8e940d70..b1cae201 100644 --- a/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java +++ b/src/main/java/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java @@ -172,9 +172,9 @@ public class TypeUnifyTask extends RecursiveTask>> { thNo = totalnoOfThread; writeLog("thNo2 " + thNo); try { - this.logFile = //new OutputStreamWriter(new NullOutputStream()); + this.logFile = new OutputStreamWriter(new NullOutputStream()); //new FileWriter(new File(System.getProperty("user.dir")+"/src/test/resources/logFiles/"+"Thread_"+thNo)); - new FileWriter(new File(System.getProperty("user.dir")+"/logFiles/"+"Thread_"+thNo)); + //new FileWriter(new File(System.getProperty("user.dir")+"/logFiles/"+"Thread_"+thNo)); logFile.write(""); } catch (IOException e) {