]> git.donarmstrong.com Git - mothur.git/blobdiff - screenseqscommand.h
added checks to make sure windows processes completed their tasks.
[mothur.git] / screenseqscommand.h
index b0d7c7c18f3852dd40395b0f699749fc885cc14b..6f4e8aca688cd3342c13400aff588f4f3eaec24a 100644 (file)
@@ -23,8 +23,9 @@ public:
        vector<string> setParameters();
        string getCommandName()                 { return "screen.seqs";                         }
        string getCommandCategory()             { return "Sequence Processing";         }
-       string getOutputFileNameTag(string, string);
+       
        string getHelpString(); 
+    string getOutputPattern(string);   
        string getCitation() { return "http://www.mothur.org/wiki/Screen.seqs"; }
        string getDescription()         { return "enables you to keep sequences that fulfill certain user defined criteria"; }
 
@@ -148,9 +149,11 @@ static DWORD WINAPI MySumThreadFunction(LPVOID lpParam){
                        in.seekg(pDataArray->start-1); pDataArray->m->gobble(in); 
                }
                
-               pDataArray->count = pDataArray->end;
+               
                for(int i = 0; i < pDataArray->end; i++){ //end is the number of sequences to process
                        
+            pDataArray->count++;
+            
                        if (pDataArray->m->control_pressed) { in.close();  pDataArray->count = 1; return 1; }
                        
                        Sequence current(in); pDataArray->m->gobble(in); 
@@ -212,9 +215,10 @@ static DWORD WINAPI MySumScreenThreadFunction(LPVOID lpParam){
                        in.seekg(pDataArray->start-1); pDataArray->m->gobble(in); 
                }
                
-               pDataArray->count = pDataArray->end;
                for(int i = 0; i < pDataArray->end; i++){ //end is the number of sequences to process
                        
+            pDataArray->count++;
+            
                        if (pDataArray->m->control_pressed) { in.close(); badAccnosFile.close(); goodFile.close(); pDataArray->count = 1; return 1; }
                        
                        Sequence currSeq(in); pDataArray->m->gobble(in);