#include <iomanip>
#include <fstream>
#include <sstream>
+#include <signal.h>
//exception
#include <stdexcept>
#include <ctime>
#include <limits>
+/***********************************************************************/
#if defined (__APPLE__) || (__MACH__) || (linux) || (__linux)
#include <sys/wait.h>
#include <unistd.h>
+
+ #ifdef USE_READLINE
+ #include <readline/readline.h>
+ #include <readline/history.h>
+ #endif
+
+ //#include <readline/readline.h>
+ //#include <readline/history.h>
+#else
+ #include <conio.h> //allows unbuffered screen capture from stdin
#endif
using namespace std;
f.putback(d);
}
-
/***********************************************************************/
inline string getline(ifstream& fileHandle) {
}
-
-
-
/***********************************************************************/
inline bool isTrue(string f){
return extension;
}
-
+/***********************************************************************/
+inline bool isBlank(string fileName){
+
+ ifstream fileHandle;
+ fileHandle.open(fileName.c_str());
+ if(!fileHandle) {
+ mothurOut("Error: Could not open " + fileName); mothurOutEndLine();
+ return false;
+ }else {
+ //check for blank file
+ gobble(fileHandle);
+ if (fileHandle.eof()) { fileHandle.close(); return true; }
+ }
+ return false;
+}
/***********************************************************************/
inline int openInputFile(string fileName, ifstream& fileHandle){
return numSeqs;
}
+/***********************************************************************/
+inline bool inVector(string member, vector<string> group){
+
+ for (int i = 0; i < group.size(); i++) {
+ if (group[i] == member) { return true; }
+ }
+
+ return false;
+}
/***********************************************************************/
//This function parses the estimator options and puts them in a vector