X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=filterseqscommand.h;h=848d08a30e29c665f028a31c9f9dd97e0a113c5d;hb=e189982e0a9b7352ad57cc38ccee675f128be22e;hp=3cc007c059c63de5f28eee57ac0afcf78d00dc33;hpb=30f2d98fffb579b870c8969ddcc1dfc61ccbb70a;p=mothur.git diff --git a/filterseqscommand.h b/filterseqscommand.h index 3cc007c..848d08a 100644 --- a/filterseqscommand.h +++ b/filterseqscommand.h @@ -1,54 +1,60 @@ -#ifndef FILTERSEQSCOMMAND_H -#define FILTERSEQSCOMMAND_H - -/* - * filterseqscommand.h - * Mothur - * - * Created by Thomas Ryabin on 5/4/09. - * Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved. - * - */ - -#include "command.hpp" -#include "filters.h" -#include "mpi.h" - -class Sequence; -class FilterSeqsCommand : public Command { - -public: - FilterSeqsCommand(string); - ~FilterSeqsCommand() {}; - int execute(); - void help(); - -private: - struct linePair { - int start; - int numSeqs; - linePair(long int i, int j) : start(i), numSeqs(j) {} - }; - vector lines; - - - string vertical, filter, fasta, hard, outputDir, filterFileName; - vector fastafileNames; - int alignmentLength, processors; - vector bufferSizes; - - char trump; - bool abort; - float soft; - int numSeqs; - - string createFilter(); - int createProcessesCreateFilter(Filters&, string); - int driverCreateFilter(Filters&, string, linePair*); - int MPICreateFilter(Filters&, string); - int setLines(string); - int parseBuffer(string, vector&); - -}; - -#endif +#ifndef FILTERSEQSCOMMAND_H +#define FILTERSEQSCOMMAND_H + +/* + * filterseqscommand.h + * Mothur + * + * Created by Thomas Ryabin on 5/4/09. + * Copyright 2009 Schloss Lab UMASS Amherst. All rights reserved. + * + */ + +#include "command.hpp" +#include "filters.h" + +class Sequence; +class FilterSeqsCommand : public Command { + +public: + FilterSeqsCommand(string); + ~FilterSeqsCommand() {}; + int execute(); + void help(); + +private: + struct linePair { + int start; + int num; + linePair(long int i, long int j) : start(i), num(j) {} + }; + vector lines; + vector processIDS; + + string vertical, filter, fasta, hard, outputDir, filterFileName; + vector fastafileNames; + int alignmentLength, processors; + vector bufferSizes; + vector outputNames; + + char trump; + bool abort; + float soft; + int numSeqs; + + string createFilter(); + int filterSequences(); + int createProcessesCreateFilter(Filters&, string); + int createProcessesRunFilter(string, string); + int driverRunFilter(string, string, string, linePair*); + int driverCreateFilter(Filters& F, string filename, linePair* line); + #ifdef USE_MPI + int driverMPIRun(int, int, MPI_File&, MPI_File&, vector&); + int MPICreateFilter(int, int, Filters&, MPI_File&, vector&); + #endif + int setLines(string); + + +}; + +#endif