source: tags/casa3.2.0asap/src/STHistory.h@ 2747

Last change on this file since 2747 was 1353, checked in by mar637, 17 years ago

added explicit keyword for single arument constructors

File size: 1.5 KB
Line 
1//
2// C++ Interface: STHistory
3//
4// Description:
5//
6//
7// Author: Malte Marquarding <asap@atnf.csiro.au>, (C) 2006
8//
9// Copyright: See COPYING file that comes with this distribution
10//
11//
12#ifndef ASAPSTHISTORY_H
13#define ASAPSTHISTORY_H
14
15#include <casa/aips.h>
16#include <casa/BasicSL/String.h>
17#include <tables/Tables/Table.h>
18#include <tables/Tables/ScalarColumn.h>
19
20#include "STSubTable.h"
21
22namespace asap {
23
24/**
25The History subtable of the Scantable
26
27@author Malte Marquarding
28*/
29class STHistory : public STSubTable {
30public:
31 STHistory() {;}
32 explicit STHistory(casa::Table tab);
33 explicit STHistory( const Scantable& parent );
34
35 virtual ~STHistory();
36
37 STHistory& operator=(const STHistory& other);
38
39 /**
40 * add another row to this table
41 * @param item the histor string
42 * @return an ID (irrelevant)
43 */
44 casa::uInt addEntry( const casa::String& item);
45
46 /**
47 * Just for consistency sake, doesn't do anything
48 * as IDs are irrelevant in this class
49 * @param item a string
50 * @param id an uInt ID
51 */
52 void getEntry( casa::String& item, casa::uInt id);
53
54 /**
55 * add all rows from another STHistory table
56 * @param other a STHistory reference
57 */
58 void append(const STHistory& other);
59
60 /**
61 * Get all rows in the table as a vector
62 * @return a vector of strings
63 */
64 std::vector<std::string> getHistory( ) const;
65
66 const casa::String& name() const { return name_; }
67
68private:
69 void setup();
70 static const casa::String name_;
71 casa::ScalarColumn<casa::String> itemCol_;
72};
73
74}
75
76#endif
Note: See TracBrowser for help on using the repository browser.