]> git.donarmstrong.com Git - mothur.git/blob - binsequencecommand.h
fe83f20f59b0e6f4db7d765f9b1aa5dc17618252
[mothur.git] / binsequencecommand.h
1 #ifndef BINSEQCOMMAND_H
2 #define BINSEQCOMMAND_H
3 /*
4  *  binsequencecommand.h
5  *  Mothur
6  *
7  *  Created by Sarah Westcott on 4/3/09.
8  *  Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
9  *
10  */
11
12 /* The bin.seqs command outputs a .fasta file for each distance you specify appending the OTU number to each name. */
13
14 #include "command.hpp"
15 #include "inputdata.h"
16 #include "listvector.hpp"
17 #include "fastamap.h"
18 #include "groupmap.h"
19
20 class BinSeqCommand : public Command {
21         
22 public:
23         BinSeqCommand(string);  
24         BinSeqCommand();
25         ~BinSeqCommand();
26         
27         vector<string> setParameters();
28         string getCommandName()                 { return "bin.seqs";                    }
29         string getCommandCategory()             { return "Sequence Processing"; }
30         string getHelpString(); 
31         
32         int execute(); 
33         void help() { m->mothurOut(getHelpString()); }          
34         
35 private:
36         
37         ListVector* list;
38         InputData* input;
39         FastaMap* fasta;
40         GroupMap* groupMap;
41         bool abort, allLines;
42         set<string> labels; //holds labels to be used
43         string filename, fastafile, listfile, namesfile, groupfile, label, outputDir;
44         ofstream out;
45         ifstream in, inNames;
46         vector<string> outputNames;
47         
48         void readNamesFile();
49         int process(ListVector*);
50 };
51
52 #endif