]> git.donarmstrong.com Git - mothur.git/blob - splitgroupscommand.h
added command descriptions
[mothur.git] / splitgroupscommand.h
1 #ifndef SPLITGROUPSCOMMAND_H
2 #define SPLITGROUPSCOMMAND_H
3
4 /*
5  *  splitgroupscommand.h
6  *  Mothur
7  *
8  *  Created by westcott on 9/20/10.
9  *  Copyright 2010 Schloss Lab. All rights reserved.
10  *
11  */
12
13
14 /* split.groups - given a group file, split sequences and names files in to separate files *.group1.fasta and .group1.names. */
15
16
17 #include "command.hpp"
18 #include "groupmap.h"
19 #include "sequence.hpp"
20
21 /***************************************************************************************/
22
23 class SplitGroupCommand : public Command {
24         
25 public:
26         SplitGroupCommand(string);      
27         SplitGroupCommand();
28         ~SplitGroupCommand() {}
29         
30         vector<string> setParameters();
31         string getCommandName()                 { return "split.group";                         }
32         string getCommandCategory()             { return "Sequence Processing";         }
33         string getHelpString(); 
34         string getCitation() { return "http://www.mothur.org/wiki/Split.group"; }
35         string getDescription()         { return "split a name or fasta file by group"; }
36
37         
38         int execute(); 
39         void help() { m->mothurOut(getHelpString()); }  
40         
41 private:
42         int readNames(); 
43         int splitFasta(); 
44         
45         vector<string> outputNames;
46         map<string, vector<string> > nameMap;
47         map<string, vector<string> >::iterator itNames;
48         GroupMap* groupMap;
49         
50         string outputDir, namefile, groupfile, groups, fastafile;
51         vector<string> Groups;
52         bool abort;
53 };
54
55 /***************************************************************************************/
56
57 #endif
58
59
60