| Line | |
|---|
| 1 | #ifndef FUN_H |
|---|
| 2 | #define FUN_H |
|---|
| 3 | |
|---|
| 4 | #ifndef ARBTOOLS_H |
|---|
| 5 | #include <arbtools.h> |
|---|
| 6 | #endif |
|---|
| 7 | |
|---|
| 8 | // forward decls for prototypes |
|---|
| 9 | |
|---|
| 10 | enum Format { |
|---|
| 11 | // input/output formats |
|---|
| 12 | EMBL, |
|---|
| 13 | GENBANK, |
|---|
| 14 | MACKE, |
|---|
| 15 | SWISSPROT, |
|---|
| 16 | LAST_INPUT_FORMAT = SWISSPROT, |
|---|
| 17 | |
|---|
| 18 | // output-only formats |
|---|
| 19 | GCG, |
|---|
| 20 | NEXUS, |
|---|
| 21 | PHYLIP, |
|---|
| 22 | FASTDNAML, |
|---|
| 23 | PRINTABLE, |
|---|
| 24 | |
|---|
| 25 | UNKNOWN, |
|---|
| 26 | }; |
|---|
| 27 | |
|---|
| 28 | CONSTEXPR_INLINE bool is_input_format(Format inType) { return inType <= LAST_INPUT_FORMAT; } |
|---|
| 29 | |
|---|
| 30 | class Reader; |
|---|
| 31 | class Writer; |
|---|
| 32 | |
|---|
| 33 | struct Embl; |
|---|
| 34 | struct Emblref; |
|---|
| 35 | struct EmblSwissprotReader; |
|---|
| 36 | struct GenBank; |
|---|
| 37 | struct GenbankRef; |
|---|
| 38 | struct GenbankReader; |
|---|
| 39 | struct Macke; |
|---|
| 40 | struct MackeReader; |
|---|
| 41 | struct Paup; |
|---|
| 42 | struct Seq; |
|---|
| 43 | struct Alignment; |
|---|
| 44 | |
|---|
| 45 | struct RDP_comments; |
|---|
| 46 | struct OrgInfo; |
|---|
| 47 | struct SeqInfo; |
|---|
| 48 | |
|---|
| 49 | typedef void (*RDP_comment_parser)(char*& datastring, int start_index, Reader& reader); |
|---|
| 50 | |
|---|
| 51 | class FormattedFile : virtual Noncopyable { |
|---|
| 52 | char *name_; |
|---|
| 53 | Format type_; |
|---|
| 54 | public: |
|---|
| 55 | FormattedFile() : name_(NULp), type_(UNKNOWN) {} |
|---|
| 56 | FormattedFile(const char *Name, Format Type); |
|---|
| 57 | ~FormattedFile(); |
|---|
| 58 | |
|---|
| 59 | void init(const char *Name, Format Type); |
|---|
| 60 | |
|---|
| 61 | const char *name() const { return name_; } |
|---|
| 62 | Format type() const { return type_; } |
|---|
| 63 | }; |
|---|
| 64 | |
|---|
| 65 | #ifndef BUFFEREDFILEREADER_H |
|---|
| 66 | #include <BufferedFileReader.h> |
|---|
| 67 | #endif |
|---|
| 68 | #ifndef PROTOTYPES_H |
|---|
| 69 | #include "prototypes.h" |
|---|
| 70 | #endif |
|---|
| 71 | |
|---|
| 72 | #else |
|---|
| 73 | #error fun.h included twice |
|---|
| 74 | #endif // FUN_H |
|---|
| 75 | |
|---|
Note: See
TracBrowser
for help on using the repository browser.