]> git.donarmstrong.com Git - mothur.git/commitdiff
add debugout to mothurout.cpp
authorDon Armstrong <don@donarmstrong.com>
Mon, 16 Dec 2013 20:22:19 +0000 (12:22 -0800)
committerDon Armstrong <don@donarmstrong.com>
Mon, 16 Dec 2013 20:22:19 +0000 (12:22 -0800)
mothurout.cpp

index 0f24cb2dc362c679dd16ed0eb7c50444f07e7a6e..2046adc854ae3a1227520311462559709ffb3d78 100644 (file)
@@ -348,6 +348,30 @@ void MothurOut::mothurOut(string output) {
        }
 }
 /*********************************************************************************************/
+void MothurOut::debugOut(string output) {
+  try {
+    if (debug) {
+      mothurOut("[DEBUG]: "+output+"\n");
+        }
+       }
+  catch(exception& e) {
+    errorOut(e, "MothurOut", "MothurOut");
+    exit(1);
+  }
+}
+/*********************************************************************************************/
+void MothurOut::debugOut(string output,ofstream& outputFile) {
+  try {
+    if(debug) {
+      mothurOut("[DEBUG]: "+output+"\n",outputFile);
+    }
+  }
+  catch(exception& e) {
+    errorOut(e,"MothurOut","MothurOut");
+    exit(1);
+  }
+}
+/*********************************************************************************************/
 void MothurOut::mothurOutJustToScreen(string output) {
        try {