]> git.donarmstrong.com Git - mothur.git/blob - readseqscommand.cpp
*** empty log message ***
[mothur.git] / readseqscommand.cpp
1 /*
2  *  readseqscommand.cpp
3  *  Mothur
4  *
5  *  Created by Thomas Ryabin on 4/13/09.
6  *  Copyright 2009 __MyCompanyName__. All rights reserved.
7  *
8  */
9
10 #include "readseqscommand.h"
11
12 //**********************************************************************************************************************
13 ReadSeqsCommand::ReadSeqsCommand(){
14         try {
15                 globaldata = GlobalData::getInstance();
16                 
17         }
18         catch(exception& e) {
19                 cout << "Standard Error: " << e.what() << " has occurred in the ReadOtuCommand class Function ReadOtuCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
20                 exit(1);
21         }
22         catch(...) {
23                 cout << "An unknown error has occurred in the ReadOtuCommand class function ReadOtuCommand. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
24                 exit(1);
25         }
26 }
27
28 //**********************************************************************************************************************
29
30 ReadSeqsCommand::~ReadSeqsCommand(){
31         //delete readFasta->getDB();
32 //      delete readNexus->getDB();
33 //      delete readClustal->getDB();
34 //      delete readPhylip->getDB();
35 }
36
37 //**********************************************************************************************************************
38
39 int ReadSeqsCommand::execute(){
40         try {
41                 filebuf fb;
42                 
43                 //fb.open ("fasta.txt",ios::out);
44 //              readFasta->read();
45 //              SequenceDB* db = readFasta->getDB();
46                 
47                 //fb.open("nexus.txt",ios::out);
48 //              readNexus->read();
49 //              SequenceDB* db = readNexus->getDB();    
50
51                 //fb.open("clustal.txt",ios::out);
52 //              readClustal->read();
53 //              SequenceDB* db = readClustal->getDB();
54                 
55                 //fb.open("phylip.txt",ios::out);
56 //              readPhylip->read();
57 //              SequenceDB* db = readPhylip->getDB();
58
59                 
60                 
61                 //for(int i = 0; i < db->size(); i++) {
62 //                      cout << db->get(i).getLength() << "\n" << db->get(i).getName() << ": " << db->get(i).getUnaligned() << "\n\n";
63 //              }
64
65                 //ostream os(&fb);
66 //              db->print(os);
67 //              fb.close();
68
69                 return 0;
70         }
71         catch(exception& e) {
72                 cout << "Standard Error: " << e.what() << " has occurred in the ReadOtuCommand class Function execute. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
73                 exit(1);
74         }
75         catch(...) {
76                 cout << "An unknown error has occurred in the ReadOtuCommand class function execute. Please contact Pat Schloss at pschloss@microbio.umass.edu." << "\n";
77                 exit(1);
78         }
79 }
80 //**********************************************************************************************************************