8 * Created by Pat Schloss on 10/23/08.
9 * Copyright 2008 Patrick D. Schloss. All rights reserved.
13 /*This class is a parent to all the command classes. */
17 #include "optionparser.h"
18 #include "validparameter.h"
19 #include "mothurout.h"
20 #include "commandparameter.h"
26 Command() { m = MothurOut::getInstance(); }
29 virtual string getCommandName() = 0;
30 virtual string getCommandCategory() = 0;
31 virtual string getHelpString() = 0;
32 virtual string getCitation() = 0;
34 virtual map<string, vector<string> > getOutputFiles() { return outputTypes; }
35 virtual vector<string> setParameters() = 0; //to fill parameters
36 virtual vector<CommandParameter> getParameters() { return parameters; }
38 virtual int execute() = 0;
39 virtual void help() = 0;
40 void citation() { m->mothurOutEndLine(); m->mothurOut(getCitation()); m->mothurOutEndLine(); }
41 virtual ~Command() { }
47 map<string, vector<string> > outputTypes;
48 vector<CommandParameter> parameters;
50 map<string, vector<string> >::iterator itTypes;