|
From: <mwl...@us...> - 2007-08-20 17:56:34
|
Revision: 492
http://cishell.svn.sourceforge.net/cishell/?rev=492&view=rev
Author: mwlinnem
Date: 2007-08-20 10:46:46 -0700 (Mon, 20 Aug 2007)
Log Message:
-----------
Removed System.out.printlns
Modified Paths:
--------------
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterGraph.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterPath.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/ConvResultMaker.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/AllConvsReportGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/ConvReportSubGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/AllTestsReportGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/FilePassSubGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/TestReportSubGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/convgraph/GraphReportGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/readme/ReadMeReportGenerator.java
trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/reports/FilePassReport.java
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterGraph.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterGraph.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterGraph.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -280,7 +280,6 @@
}
private void writeNodes(BufferedWriter bw, Map nodes) throws IOException{
- System.out.println("*Nodes " + nodes.size() + "\n");
writeNodeHeader(bw, nodes.size());
String[] keySet = new String[nodes.keySet().size()];
keySet = (String[])nodes.keySet().toArray(keySet);
@@ -298,14 +297,12 @@
private void writeEdges(BufferedWriter bw, TreeSet edges) throws IOException{
- System.out.println("*DirectedEdges " + edges.size());
writeEdgeHeader(bw,edges.size());
String[] edgeArray = new String[edges.size()];
edgeArray = (String[])edges.toArray(edgeArray);
for(int i = 0; i < edgeArray.length; i++){
- System.out.println(edgeArray[i]);
bw.flush();
bw.write(edgeArray[i]+"\n");
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterPath.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterPath.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/converter/graph/ConverterPath.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -54,7 +54,7 @@
boolean val = true;
if(path.contains(sr)){
- System.out.println("Path already contains " + sr.getProperty("service.pid"));
+// System.out.println("Path already contains " + sr.getProperty("service.pid"));
return false;
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/ConvResultMaker.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/ConvResultMaker.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/ConvResultMaker.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -203,7 +203,6 @@
if (fprFailure.getPhase().equals(ConvertPhaseFailure.TEST_PHASE) &&
failedConvName.equals(currentConvName)) {
//reached where the converters broke
- System.out.println("Reached the end in test phase");
break;
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/AllConvsReportGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/AllConvsReportGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/AllConvsReportGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -19,7 +19,7 @@
public static final String TEMP_FILE_PATH = "All-Converters-Report2.txt";
- private ConvReportSubGenerator convSubGen = new ConvReportSubGenerator();
+ private ConvReportSubGenerator convSubGen;
private AllConvsReport allConvsReport = null;
@@ -27,6 +27,8 @@
public AllConvsReportGenerator(LogService log) {
this.log = log;
+
+ this.convSubGen = new ConvReportSubGenerator(this.log);
}
public void generateReport(AllTestsResult atr) {
@@ -121,14 +123,12 @@
reportOutStream.close();
} catch (IOException e) {
- System.out.println("Unable to generate all converters report.");
- e.printStackTrace();
+
+ this.log.log(LogService.LOG_ERROR, "Unable to generate all converters report.", e);
try {
if (reportOutStream != null) reportOutStream.close();
} catch (IOException e2) {
- System.out.println("Unable to close all convertersreport" +
- " stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR, "Unable to generate all converters report.", e);
}
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/ConvReportSubGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/ConvReportSubGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/allconvs/ConvReportSubGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -13,11 +13,18 @@
import org.cishell.testing.convertertester.core.tester2.reportgen.results.ConvResult;
import org.cishell.testing.convertertester.core.tester2.reportgen.results.TestResult;
import org.osgi.framework.ServiceReference;
+import org.osgi.service.log.LogService;
public class ConvReportSubGenerator {
private ConvReport convReport = null;
-
+
+ private LogService log;
+
+ public ConvReportSubGenerator(LogService log) {
+ this.log = log;
+ }
+
public void generate(ConvResult cr) {
FileOutputStream reportOutStream = null;
@@ -92,15 +99,12 @@
report.flush();
reportOutStream.close();
} catch (IOException e) {
- System.out.println("Unable to generate a converter report.");
- e.printStackTrace();
+ this.log.log(LogService.LOG_ERROR, "Unable to generate a converter report.", e);
try {
if (reportOutStream != null)
reportOutStream.close();
} catch (IOException e2) {
- System.out.println("Unable to close a converter report" +
- " stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR, "Unable to close a converter report", e);
}
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/AllTestsReportGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/AllTestsReportGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/AllTestsReportGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -26,7 +26,8 @@
public AllTestsReportGenerator(LogService log) {
this.log = log;
- this.testResultSubGen = new TestReportSubGenerator();
+
+ this.testResultSubGen = new TestReportSubGenerator(this.log);
}
public void generateReport(AllTestsResult atr) {
@@ -117,8 +118,8 @@
(TestReport[]) failedTRReports.toArray(new TestReport[0]),
summary);
} catch (IOException e) {
- System.out.println("Unable to generate all tests report.");
- e.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to generate all tests report.", e);
closeStream(reportOutStream);
} finally {
closeStream(reportOutStream);
@@ -135,8 +136,8 @@
stream.close();
}
} catch (IOException e2) {
- System.out.println("Unable to close all tests report stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to close all tests report stream", e2);
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/FilePassSubGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/FilePassSubGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/FilePassSubGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -9,12 +9,18 @@
import org.cishell.testing.convertertester.core.tester2.reportgen.reports.FilePassReport;
import org.cishell.testing.convertertester.core.tester2.reportgen.results.FilePassResult;
import org.cishell.testing.convertertester.core.tester2.reportgen.results.filepass.ConvertPhaseFailure;
+import org.osgi.service.log.LogService;
public class FilePassSubGenerator {
private FilePassReport filePassReport;
-
-
+
+ private LogService log;
+
+ public FilePassSubGenerator(LogService log) {
+ this.log = log;
+ }
+
public void generateSubreport(FilePassResult fpr) {
FileOutputStream reportOutStream = null;
try {
@@ -41,8 +47,8 @@
summary);
} catch (IOException e) {
- System.out.println("Unable to generate file pass report.");
- e.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to generate file pass report.", e);
closeStream(reportOutStream);
} finally {
closeStream(reportOutStream);
@@ -95,8 +101,8 @@
if (stream != null)
stream.close();
} catch (IOException e2) {
- System.out.println("Unable to close file pass report stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to close file pass report stream", e2);
}
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/TestReportSubGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/TestReportSubGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/alltests/TestReportSubGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -14,6 +14,7 @@
import org.cishell.testing.convertertester.core.tester2.reportgen.results.FilePassResult;
import org.cishell.testing.convertertester.core.tester2.reportgen.results.TestResult;
import org.osgi.framework.ServiceReference;
+import org.osgi.service.log.LogService;
public class TestReportSubGenerator {
@@ -21,8 +22,12 @@
private FilePassSubGenerator filePassSubGen;
- public TestReportSubGenerator() {
- this.filePassSubGen = new FilePassSubGenerator();
+ private LogService log;
+
+ public TestReportSubGenerator(LogService log) {
+ this.log = log;
+
+ this.filePassSubGen = new FilePassSubGenerator(this.log);
}
public void generateSubreport(TestResult tr) {
@@ -123,8 +128,8 @@
} catch (IOException e) {
- System.out.println("Unable to generate a test report.");
- e.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to generate a test report.", e);
closeStream(reportOutStream);
} finally {
closeStream(reportOutStream);
@@ -140,8 +145,8 @@
if (stream != null)
stream.close();
} catch (IOException e2) {
- System.out.println("Unable to close a test report stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to close a test report stream", e2);
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/convgraph/GraphReportGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/convgraph/GraphReportGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/convgraph/GraphReportGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -77,13 +77,13 @@
}
} catch (IOException e) {
- System.out.println("Unable to generate Graph Report.");
- e.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to generate Graph Report.", e);
try {
if (reader != null) reader.close();
} catch (IOException e2) {
- System.out.println("Unable to close graph report stream");
- e2.printStackTrace();
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to close graph report stream", e);
}
} finally {
try {
@@ -95,7 +95,9 @@
writer.close();
}
} catch (IOException e) {
- System.out.println("Unable to close either graph report reader or writer.");
+ this.log.log(LogService.LOG_ERROR,
+ "Unable to close either graph report reader or " +
+ "writer.", e);
e.printStackTrace();
}
}
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/readme/ReadMeReportGenerator.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/readme/ReadMeReportGenerator.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/readme/ReadMeReportGenerator.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -17,8 +17,8 @@
* load a file with the report text inside it, and return it as is.
*/
public void generateReport(AllTestsResult atr) {
- String readmePath = TestFileKeeper.DEFAULT_ROOT_DIR + "ReportREADME.txt";
- System.out.println("ReadMe path is: " + readmePath);
+ String readmePath = TestFileKeeper.DEFAULT_ROOT_DIR +
+ "ReportREADME.txt";
File readmeFile = new File(readmePath);
this.readme = new ReadMeReport(readmeFile, "README", "");
Modified: trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/reports/FilePassReport.java
===================================================================
--- trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/reports/FilePassReport.java 2007-08-20 17:24:09 UTC (rev 491)
+++ trunk/testing/org.cishell.testing.convertertester.core.new/src/org/cishell/testing/convertertester/core/tester2/reportgen/reports/FilePassReport.java 2007-08-20 17:46:46 UTC (rev 492)
@@ -10,7 +10,6 @@
private String summary;
public FilePassReport (File filePassReport, String name, String summary) {
- System.out.println("File pass report constructor, name is :" + name);
this.filePassReport = filePassReport;
this.name = name;
this.summary = summary;
@@ -21,7 +20,6 @@
}
public String getName() {
- System.out.println("Returning name " + this.name);
return this.name;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|