]> git.donarmstrong.com Git - mothur.git/blob - sharedcommand.h
added groups option to read.otu, added qtrim option to trim.seqs, fixed bug in get...
[mothur.git] / sharedcommand.h
1 #ifndef SHAREDCOMMAND_H
2 #define SHAREDCOMMAND_H
3 /*
4  *  sharedcommand.h
5  *  Dotur
6  *
7  *  Created by Sarah Westcott on 1/2/09.
8  *  Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved.
9  *
10  */
11
12 #include "command.hpp"
13 #include "sharedlistvector.h"
14 #include "inputdata.h"
15 #include "readotu.h"
16
17 /* The shared() command:
18         The shared command can only be executed after a successful read.shared command.  
19         The shared command parses a .list file and separates it into groups.  
20         It outputs a .shared file containing the OTU information for each group.  
21         There are no shared command parameters.  The shared command should be in the following format: shared(). */
22
23
24 class GlobalData;
25
26 class SharedCommand : public Command {
27         
28 public:
29         SharedCommand();        
30         ~SharedCommand();
31         int execute();  
32         void help() {}
33         
34 private:
35         void printSharedData(vector<SharedRAbundVector*>);
36         void createMisMatchFile();
37         bool isValidGroup(string, vector<string>);
38         
39         GlobalData* globaldata;
40         ReadOTUFile* read;
41         SharedListVector* SharedList;
42         InputData* input;
43         GroupMap* groupMap;
44         vector<string> groups;
45         ofstream out;
46         string filename, fileroot;
47         bool firsttime;
48         map<string, ofstream*> filehandles;
49         map<string, ofstream*>::iterator it3;
50
51 };
52
53 #endif