Last change
on this file since 1064 was
1061,
checked in by MatthewWhiting, 12 years ago
|
Ticket #162 - A large refactoring of the Column-related code. Columns have moved to Outputs, and in a new namespace Catalogues. The interface has changed, using strings to record the type rather
than the enum. Also included is a new class CatalogueSpecification?, that is designed to hold a collection of Columns. This is not yet implemented - everything still uses the full & log column
vectors, and the code still passes the verification script.
|
File size:
1.3 KB
|
Line | |
---|
1 | #ifndef DUCHAMP_ASCII_CATALOGUE_WRITER_H_ |
---|
2 | #define DUCHAMP_ASCII_CATALOGUE_WRITER_H_ |
---|
3 | |
---|
4 | #include <duchamp/Outputs/CatalogueWriter.hh> |
---|
5 | #include <duchamp/Outputs/columns.hh> |
---|
6 | #include <duchamp/Detection/detection.hh> |
---|
7 | #include <ios> |
---|
8 | #include <iostream> |
---|
9 | #include <fstream> |
---|
10 | |
---|
11 | namespace duchamp { |
---|
12 | |
---|
13 | class ASCIICatalogueWriter : public CatalogueWriter |
---|
14 | { |
---|
15 | public: |
---|
16 | ASCIICatalogueWriter(); |
---|
17 | ASCIICatalogueWriter(std::string name); |
---|
18 | ASCIICatalogueWriter(Catalogues::DESTINATION dest); |
---|
19 | ASCIICatalogueWriter(std::string name, Catalogues::DESTINATION dest); |
---|
20 | ASCIICatalogueWriter(const ASCIICatalogueWriter& other); |
---|
21 | ASCIICatalogueWriter& operator= (const ASCIICatalogueWriter& other); |
---|
22 | virtual ~ASCIICatalogueWriter(){}; |
---|
23 | |
---|
24 | /// @brief open the catalogue for writing |
---|
25 | bool openCatalogue(std::ios_base::openmode mode = std::ios_base::out ); |
---|
26 | |
---|
27 | /// @brief Write header information - not including parameters |
---|
28 | void writeHeader(); |
---|
29 | void writeCommandLineEntry(int argc, char *argv[]); |
---|
30 | |
---|
31 | void writeParameters(); |
---|
32 | void writeStats(); |
---|
33 | void writeTableHeader(); |
---|
34 | void writeEntries(); |
---|
35 | void writeEntry(Detection *object); |
---|
36 | void writeCubeSummary(); |
---|
37 | void writeFooter(){}; |
---|
38 | |
---|
39 | bool closeCatalogue(); |
---|
40 | |
---|
41 | |
---|
42 | protected: |
---|
43 | std::ostream *itsStream; |
---|
44 | std::ofstream itsFileStream; |
---|
45 | Catalogues::DESTINATION itsDestination; |
---|
46 | |
---|
47 | |
---|
48 | }; |
---|
49 | |
---|
50 | |
---|
51 | } |
---|
52 | |
---|
53 | |
---|
54 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.