]> git.donarmstrong.com Git - mothur.git/blobdiff - trimseqscommand.h
worked on trim.seqs
[mothur.git] / trimseqscommand.h
index 565d5283329124a65aca975d51a9588cb791670d..a4a4215277fadbdb5857dea6d9e9319e233cad01 100644 (file)
 
 #include "mothur.h"
 #include "command.hpp"
-#include "globaldata.hpp"
 #include "sequence.hpp"
 
 class TrimSeqsCommand : public Command {
 public:
-       TrimSeqsCommand();
+       TrimSeqsCommand(string);
        ~TrimSeqsCommand();
        int execute();
+       void help();
        
 private:
-       void getOligos();
-       bool stripBarcode(Sequence&, string&);
-       bool stripForward(Sequence&);
+
+       struct linePair {
+               int start;
+               int num;
+               linePair(long int i, int j) : start(i), num(j) {}
+       };
+
+       void getOligos(vector<string>&);
+       bool stripQualThreshold(Sequence&, ifstream&);
+       bool cullQualAverage(Sequence&, ifstream&);
+       int stripBarcode(Sequence&, int&);
+       int stripForward(Sequence&);
        bool stripReverse(Sequence&);
-       
-       GlobalData* globaldata;
+       bool cullLength(Sequence&);
+       bool cullHomoP(Sequence&);
+       bool cullAmbigs(Sequence&);
+       bool compareDNASeq(string, string);
+       int countDiffs(string, string);//, int, int&, int);
 
-       int totalBarcodeCount, matchBarcodeCount; // to be removed
-       int totalFPrimerCount, matchFPrimerCount; // to be removed
-       int totalRPrimerCount, matchRPrimerCount; // to be removed
+       bool abort;
+       string fastaFile, oligoFile, qFileName, outputDir;
+       
+       bool flip, allFiles, qtrim;
+       int numFPrimers, numRPrimers, maxAmbig, maxHomoP, minLength, maxLength, qThreshold, qAverage, processors, tdiffs, bdiffs, pdiffs;
+       vector<string> forPrimer, revPrimer, outputNames;
+       map<string, int> barcodes;
+       vector<string> groupVector;
+       
+       vector<int> processIDS;   //processid
+       vector<linePair*> lines;
+       vector<linePair*> qLines;
+       
+       int driverCreateTrim(string, string, string, string, string, vector<string>, linePair*, linePair*);     
+       int createProcessesCreateTrim(string, string, string, string, string, vector<string>);
+       int setLines(string, vector<linePair*>&);
        
-       bool oligos, flip;
-       int numFPrimers, numRPrimers;
-       vector<string> forPrimer, revPrimer;
-       map<string, string> barcodes;
 };
 
 #endif