4 * Copyright (c) 2007 Des Higgins, Julie Thompson and Toby Gibson.
7 * The class AlignmentOutput is used to output the Alignment in all the different
8 * formats that have been selected. It will output all the different file types if
9 * these have been selected from the menu or the commandline.
10 * To use this class we must call openAlignmentOutput first. Then we call the function
11 * createAlignmentOutput with an Alignment to be output and the first and last sequence
12 * to be output as well.
14 #ifndef ALIGNMENTOUTPUT_H
15 #define ALIGNMENTOUTPUT_H
24 #include "Alignment.h"
30 typedef struct rangeNum
36 typedef struct outputRegion
49 bool openAlignmentOutput(string path);
50 bool QTOpenFilesForOutput(AlignmentFileNames fileNames);
51 void createAlignmentOutput(Alignment* alignPtr, int firstSeq, int lastSeq);
52 void printSecStructMask(int prfLength, vector<char>* mask, vector<char>* structMask);
57 void fastaOut(Alignment* alignPtr, outputRegion partToOutput);
58 void clustalOut(Alignment* alignPtr, outputRegion partToOutput);
59 void gcgOut(Alignment* alignPtr, outputRegion partToOutput);
60 void nexusOut(Alignment* alignPtr, outputRegion partToOutput);
61 void phylipOut(Alignment* alignPtr, outputRegion partToOutput);
62 void nbrfOut(Alignment* alignPtr, outputRegion partToOutput);
63 void gdeOut(Alignment* alignPtr, outputRegion partToOutput);
64 string nameonly(string s);
66 void findRangeValues(Alignment* alignPtr, rangeNum *rnum, int firstRes, int lastRes,
68 bool openExplicitFile(auto_ptr<ofstream>& outFile, string fileName);
69 string openOutputFile(auto_ptr<ofstream>& outFile, string prompt, string path,
70 string fileExtension);
71 int SeqGCGCheckSum(vector<char>* sequence, int length);
75 auto_ptr<ofstream> clustalOutFile;
76 auto_ptr<ofstream> gcgOutFile;
77 auto_ptr<ofstream> nbrfOutFile;
78 auto_ptr<ofstream> phylipOutFile;
79 auto_ptr<ofstream> gdeOutFile;
80 auto_ptr<ofstream> nexusOutFile;
81 auto_ptr<ofstream> fastaOutFile;
83 string clustalOutName;
90 vector<string> strongGroup;
91 vector<string> weakGroup;
92 int clusSecStructOffset;
93 int clusSequenceOffset;