#include "readtreecommand.h"
#include "readotucommand.h"
#include "clustercommand.h"
-#include "parselistcommand.h"
#include "collectcommand.h"
#include "collectsharedcommand.h"
#include "getgroupcommand.h"
#include "getoturepcommand.h"
#include "treegroupscommand.h"
#include "bootstrapsharedcommand.h"
-#include "concensuscommand.h"
+//#include "consensuscommand.h"
#include "distancecommand.h"
#include "aligncommand.h"
#include "matrixoutputcommand.h"
#include "reversecommand.h"
#include "trimseqscommand.h"
#include "mergefilecommand.h"
+#include "chimeraseqscommand.h"
+#include "listseqscommand.h"
+#include "getseqscommand.h"
+#include "removeseqscommand.h"
+#include "systemcommand.h"
+#include "secondarystructurecommand.h"
+#include "getsharedotucommand.h"
+#include "getlistcountcommand.h"
+#include "hclustercommand.h"
/***********************************************************/
commands["get.sabund"] = "get.sabund";
commands["get.rabund"] = "get.rabund";
commands["bootstrap.shared"] = "bootstrap.shared";
- commands["concensus"] = "concensus";
+ //commands["consensus"] = "consensus";
commands["help"] = "help";
commands["filter.seqs"] = "filter.seqs";
commands["align.seqs"] = "align.seqs";
commands["screen.seqs"] = "screen.seqs";
commands["reverse.seqs"] = "reverse.seqs";
commands["trim.seqs"] = "trim.seqs";
+ commands["chimera.seqs"] = "chimera.seqs";
+ commands["list.seqs"] = "list.seqs";
+ commands["get.seqs"] = "get.seqs";
+ commands["remove.seqs"] = "get.seqs";
+ commands["system"] = "system";
+ commands["align.check"] = "align.check";
+ commands["get.sharedotu"] = "get.sharedotu";
+ commands["get.listcount"] = "get.listcount";
commands["quit"] = "quit";
+
+ commands["hcluster"] = "hcluster";
}
/***********************************************************/
else if(commandName == "tree.shared") { command = new TreeGroupCommand(optionString); }
else if(commandName == "dist.shared") { command = new MatrixOutputCommand(optionString); }
else if(commandName == "bootstrap.shared") { command = new BootSharedCommand(optionString); }
- else if(commandName == "concensus") { command = new ConcensusCommand(optionString); }
+ //else if(commandName == "consensus") { command = new ConcensusCommand(optionString); }
else if(commandName == "dist.seqs") { command = new DistanceCommand(optionString); }
else if(commandName == "align.seqs") { command = new AlignCommand(optionString); }
else if(commandName == "summary.seqs") { command = new SeqSummaryCommand(optionString); }
else if(commandName == "screen.seqs") { command = new ScreenSeqsCommand(optionString); }
else if(commandName == "reverse.seqs") { command = new ReverseSeqsCommand(optionString); }
else if(commandName == "trim.seqs") { command = new TrimSeqsCommand(optionString); }
+ else if(commandName == "chimera.seqs") { command = new ChimeraSeqsCommand(optionString); }
+ else if(commandName == "list.seqs") { command = new ListSeqsCommand(optionString); }
+ else if(commandName == "get.seqs") { command = new GetSeqsCommand(optionString); }
+ else if(commandName == "remove.seqs") { command = new RemoveSeqsCommand(optionString); }
else if(commandName == "merge.files") { command = new MergeFileCommand(optionString); }
+ else if(commandName == "system") { command = new SystemCommand(optionString); }
+ else if(commandName == "align.check") { command = new AlignCheckCommand(optionString); }
+ else if(commandName == "get.sharedotu") { command = new GetSharedOTUCommand(optionString); }
+ else if(commandName == "get.listcount") { command = new GetListCountCommand(optionString); }
+
+ else if(commandName == "hcluster") { command = new HClusterCommand(optionString); }
else { command = new NoCommand(optionString); }
return command;
}
catch(exception& e) {
- cout << "Standard Error: " << e.what() << " has occurred in the CommandFactory class Function getCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
+ errorOut(e, "CommandFactory", "getCommand");
exit(1);
}
- catch(...) {
- cout << "An unknown error has occurred in the CommandFactory class function getCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
- exit(1);
- }
-
}
/***********************************************************************/
if ((commands.find(command)) != (commands.end())) {
return true;
}else{
- cout << command << " is not a valid command in Mothur. Valid commands are ";
+ mothurOut(command + " is not a valid command in Mothur. Valid commands are ");
for (it = commands.begin(); it != commands.end(); it++) {
- cout << it->first << ", ";
+ mothurOut(it->first + ", ");
}
- cout << endl;
+ mothurOutEndLine();
return false;
}
}
catch(exception& e) {
- cout << "Standard Error: " << e.what() << " has occurred in the CommandFactory class Function isValidCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
- exit(1);
- }
- catch(...) {
- cout << "An unknown error has occurred in the CommandFactory class function isValidCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
+ errorOut(e, "CommandFactory", "isValidCommand");
exit(1);
}
}
out << endl;
}
catch(exception& e) {
- cout << "Standard Error: " << e.what() << " has occurred in the CommandFactory class Function printCommands. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
- exit(1);
- }
- catch(...) {
- cout << "An unknown error has occurred in the CommandFactory class function printCommands. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
+ errorOut(e, "CommandFactory", "printCommands");
exit(1);
}
}