| 1 | // This file is part of A2Amapper.cxx . . $ `<file>/atac-driver/libatac/atac.H`/ |
| 2 | // Copyright (c) 2005 J. Craig Venter Institute |
| 3 | // Author: Brian Walenz |
| 4 | // |
| 5 | // This program is free software; you can redistribute it and/or modify |
| 6 | // it under the terms of the GNU General Public License as published by |
| 7 | // the Free Software Foundation; either version 2 of the License, or |
| 8 | // (at your option) any later version. |
| 9 | // |
| 10 | // This program is distributed in the hope that it will be useful, |
| 11 | // but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | // GNU General Public License for more details. |
| 14 | // |
| 15 | // You should have received (LICENSE.txt) a copy of the GNU General Public |
| 16 | // License along with this program; if not, write to the Free Software |
| 17 | // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 18 | |
| 19 | #ifndef ATAC_COMMON_H |
| 20 | #define ATAC_COMMON_Hcxx . . $ `atac-driver/libatac/atac.H:20:9`! |
| 21 | |
| 22 | #include <string> |
| 23 | #include <map> |
| 24 | using namespace std; |
| 25 | |
| 26 | #include "bio++.H"cxx . . $ `<file>/libbio/bio++.H`/ |
| 27 | |
| 28 | #include "seqCache.H"cxx . . $ `<file>/libseq/seqCache.H`/ |
| 29 | |
| 30 | #include "atacMatch.H"cxx . . $ `<file>/atac-driver/libatac/atacMatch.H`/ |
| 31 | #include "atacMatchList.H"cxx . . $ `<file>/atac-driver/libatac/atacMatchList.H`/ |
| 32 | #include "atacMatchOrder.H"cxx . . $ `<file>/atac-driver/libatac/atacMatchOrder.H`/ |
| 33 | |
| 34 | #include "atacFeature.H"cxx . . $ `<file>/atac-driver/libatac/atacFeature.H`/ |
| 35 | #include "atacFeatureList.H"cxx . . $ `<file>/atac-driver/libatac/atacFeatureList.H`/ |
| 36 | |
| 37 | #include "fasta-accessor.H"cxx . . $ `<file>/atac-driver/libatac/fasta-accessor.H`/ |
| 38 | |
| 39 | class atacFileBasecxx . . $ atacFileBase# { |
| 40 | public: |
| 41 | atacFileBasecxx . . $ atacFileBase#atacFileBase(49f6e7a06ebc5aa8).(); |
| 42 | virtual ~cxx . . $ atacFileBase#`~atacFileBase`(ced63f7c635d850d).atacFileBasecxx . . $ atacFileBase#(); |
| 43 | |
| 44 | char *labelAcxx . . $ atacFileBase#labelA(41208ce6ca65dd58).(void) { return(_labelAcxx . . $ atacFileBase#_labelA.); }; |
| 45 | char *labelBcxx . . $ atacFileBase#labelB(41208ce6ca65dd58).(void) { return(_labelBcxx . . $ atacFileBase#_labelB.); }; |
| 46 | |
| 47 | char *assemblyFileAcxx . . $ atacFileBase#assemblyFileA(41208ce6ca65dd58).(void) { return(_fileAcxx . . $ atacFileBase#_fileA.); }; |
| 48 | char *assemblyFileBcxx . . $ atacFileBase#assemblyFileB(41208ce6ca65dd58).(void) { return(_fileBcxx . . $ atacFileBase#_fileB.); }; |
| 49 | |
| 50 | seqCachecxx . . $ seqCache# *fastaAcxx . . $ atacFileBase#fastaA(e73a05296fa21060).(void) { return(_seqAcxx . . $ atacFileBase#_seqA.); }; |
| 51 | seqCachecxx . . $ seqCache# *fastaBcxx . . $ atacFileBase#fastaB(e73a05296fa21060).(void) { return(_seqBcxx . . $ atacFileBase#_seqB.); }; |
| 52 | |
| 53 | protected: |
| 54 | void readHeadercxx . . $ atacFileBase#readHeader(ee1e387797f67d6).(char *inLine, FILEcxx . . $ FILE# *in); |
| 55 | public: |
| 56 | void writeHeadercxx . . $ atacFileBase#writeHeader(8d4262d45fc644ab).(FILEcxx . . $ FILE# *out); |
| 57 | |
| 58 | protected: |
| 59 | char _fileAcxx . . $ atacFileBase#_fileA.[1024]; // The name of our genome files |
| 60 | char _fileBcxx . . $ atacFileBase#_fileB.[1024]; |
| 61 | |
| 62 | char _labelAcxx . . $ atacFileBase#_labelA.[256]; // The label of each of the sequences |
| 63 | char _labelBcxx . . $ atacFileBase#_labelB.[256]; |
| 64 | |
| 65 | mapcxx . . $ std/map#<stringcxx . . $ std/string#,stringcxx . . $ std/string#> _paramscxx . . $ atacFileBase#_params.; |
| 66 | |
| 67 | seqCachecxx . . $ seqCache# *_seqAcxx . . $ atacFileBase#_seqA.; |
| 68 | seqCachecxx . . $ seqCache# *_seqBcxx . . $ atacFileBase#_seqB.; |
| 69 | }; |
| 70 | |
| 71 | |
| 72 | class atacFileStreamcxx . . $ atacFileStream# : public atacFileBasecxx . . $ atacFileBase# { |
| 73 | public: |
| 74 | atacFileStreamcxx . . $ atacFileStream#atacFileStream(85c52e162fed56f9).(char const *filename); |
| 75 | ~cxx . . $ atacFileStream#`~atacFileStream`(ced63f7c635d850d).atacFileStreamcxx . . $ atacFileStream#(); |
| 76 | |
| 77 | atacMatchcxx . . $ atacMatch# *nextMatchcxx . . $ atacFileStream#nextMatch(7b3c5176a3224eae).(char type); |
| 78 | atacFeaturecxx . . $ atacFeature# *nextFeaturecxx . . $ atacFileStream#nextFeature(89eb56ca9d01cd3f).(char type[4]); |
| 79 | |
| 80 | private: |
| 81 | FILEcxx . . $ FILE# *_inFilecxx . . $ atacFileStream#_inFile.; |
| 82 | char _inLinecxx . . $ atacFileStream#_inLine.[1024]; |
| 83 | |
| 84 | uint32cxx . . $ uint32# _theMatchIIDcxx . . $ atacFileStream#_theMatchIID.; |
| 85 | uint32cxx . . $ uint32# _theFeatureIIDcxx . . $ atacFileStream#_theFeatureIID.; |
| 86 | |
| 87 | atacMatchcxx . . $ atacMatch# _theMatchcxx . . $ atacFileStream#_theMatch.; |
| 88 | atacFeaturecxx . . $ atacFeature# _theFeaturecxx . . $ atacFileStream#_theFeature.; |
| 89 | }; |
| 90 | |
| 91 | |
| 92 | class afsmcxx . . $ afsm#; |
| 93 | class atacFileStreamMergecxx . . $ atacFileStreamMerge# : public atacFileBasecxx . . $ atacFileBase# { |
| 94 | public: |
| 95 | atacFileStreamMergecxx . . $ atacFileStreamMerge#atacFileStreamMerge(49f6e7a06ebc5aa8).(void); |
| 96 | ~cxx . . $ atacFileStreamMerge#`~atacFileStreamMerge`(ced63f7c635d850d).atacFileStreamMergecxx . . $ atacFileStreamMerge#(); |
| 97 | |
| 98 | void addFilecxx . . $ atacFileStreamMerge#addFile(85c52e162fed56f9).(char const *filename); |
| 99 | |
| 100 | atacMatchcxx . . $ atacMatch# *nextMatchcxx . . $ atacFileStreamMerge#nextMatch(7b3c5176a3224eae).(char type); |
| 101 | atacFeaturecxx . . $ atacFeature# *nextFeaturecxx . . $ atacFileStreamMerge#nextFeature(89eb56ca9d01cd3f).(char type[4]); |
| 102 | |
| 103 | void writeHeadercxx . . $ atacFileStreamMerge#writeHeader(8d4262d45fc644ab).(FILEcxx . . $ FILE# *out); |
| 104 | |
| 105 | private: |
| 106 | uint32cxx . . $ uint32# _filesLencxx . . $ atacFileStreamMerge#_filesLen.; |
| 107 | uint32cxx . . $ uint32# _filesMaxcxx . . $ atacFileStreamMerge#_filesMax.; |
| 108 | afsmcxx . . $ afsm# *_filescxx . . $ atacFileStreamMerge#_files.; |
| 109 | |
| 110 | uint32cxx . . $ uint32# _theMatchIIDcxx . . $ atacFileStreamMerge#_theMatchIID.; |
| 111 | uint32cxx . . $ uint32# _theFeatureIIDcxx . . $ atacFileStreamMerge#_theFeatureIID.; |
| 112 | }; |
| 113 | |
| 114 | |
| 115 | class atacFilecxx . . $ atacFile# : public atacFileBasecxx . . $ atacFileBase# { |
| 116 | public: |
| 117 | atacFilecxx . . $ atacFile#atacFile(85c52e162fed56f9).(char const *filename); |
| 118 | ~cxx . . $ atacFile#`~atacFile`(ced63f7c635d850d).atacFilecxx . . $ atacFile#(); |
| 119 | |
| 120 | atacMatchListcxx . . $ atacMatchList# *matchescxx . . $ atacFile#matches(33e88ebc28d05bce).(void) { return(&_matchescxx . . $ atacFile#_matches.); }; |
| 121 | atacMatchListcxx . . $ atacMatchList# *runscxx . . $ atacFile#runs(33e88ebc28d05bce).(void) { return(&_runscxx . . $ atacFile#_runs.); }; |
| 122 | atacMatchListcxx . . $ atacMatchList# *clumpscxx . . $ atacFile#clumps(33e88ebc28d05bce).(void) { return(&_clumpscxx . . $ atacFile#_clumps.); }; |
| 123 | |
| 124 | private: |
| 125 | atacMatchListcxx . . $ atacMatchList# _matchescxx . . $ atacFile#_matches.; |
| 126 | atacMatchListcxx . . $ atacMatchList# _runscxx . . $ atacFile#_runs.; |
| 127 | atacMatchListcxx . . $ atacMatchList# _clumpscxx . . $ atacFile#_clumps.; |
| 128 | }; |
| 129 | |
| 130 | #endif // ATAC_COMMON_H |