CARMA C++
MonitorSingleTableFolder.h
1 #ifndef CARMA_UI_RTD_MONITORSINGLETABLEFOLDER_H
2 #define CARMA_UI_RTD_MONITORSINGLETABLEFOLDER_H
3 
4 
5 /*
6  * @file
7  *
8  * Create a folder with a single automatically generated table
9  * to include in a MonitorDisplay.
10  *
11  * @author Steve Scott
12  *
13  * $CarmaCopyright$
14  *
15  */
16 
17 #include <vector>
18 
20 #include <carma/ui/rtd/common/RtDisplay.h>
21 #include <carma/ui/rtd/common/MonitorTable.h>
22 
23 #include <boost/shared_ptr.hpp>
24 
25 namespace carma {
26 namespace ui {
27 namespace rtd {
28 
29 class MonitorSingleTableFolder : public RtFolder {
30  public:
45  MonitorSingleTableFolder(
46  const ::std::string & folderName,
47  const ::std::vector< MonitorColumnInfo > & columns,
48  int columnWidth,
49  int hierarchyDepth,
50  int sampleNo,
51  bool unitsInRowLabels,
52  bool switchRowsAndColumns,
53  const MonitorTableVisitorPtr visitor,
54  bool displayRowLabels=true
55  );
56 
71  MonitorSingleTableFolder(
72  const ::std::string & folderName,
73  const ::std::vector< MonitorColumnInfo > & columns,
74  int columnWidth = AUTO_SIZE,
75  int hierarchyDepth = 1,
76  int sampleNo = 0,
77  bool unitsInRowLabels = true,
78  const MonitorTableVisitorPtr visitor = MonitorTableVisitorPtr(),
79  bool displayRowLabels =true
80  );
81 
96  MonitorSingleTableFolder(
97  const ::std::string & folderName,
98  const MonitorColumnInfo & column,
99  int columnWidth = AUTO_SIZE,
100  int hierarchyDepth = 1,
101  int sampleNo = 0,
102  bool unitsInRowLabels = true,
103  const MonitorTableVisitorPtr visitor = MonitorTableVisitorPtr(),
104  bool displayRowLabels=true
105  );
106 
121  MonitorSingleTableFolder(
122  const ::std::string & folderName,
123  const ::std::string & heading,
124  const monitor::MonitorContainer & container,
125  int columnWidth = AUTO_SIZE,
126  int hierarchyDepth = 1,
127  int sampleNo = 0,
128  bool unitsInRowLabels = true,
129  const MonitorTableVisitorPtr visitor = MonitorTableVisitorPtr(),
130  bool displayRowLabels=true
131  );
132 
147  MonitorSingleTableFolder(
148  const std::string& folderName,
149  const std::vector< ::std::string >& headings,
150  const std::vector<const monitor::MonitorContainer*>& containers,
151  int columnWidth = AUTO_SIZE,
152  int hierarchyDepth = 1,
153  int sampleNo = 0,
154  bool unitsInRowLabels = true,
155  const MonitorTableVisitorPtr visitor = MonitorTableVisitorPtr(),
156  bool switchRowsAndColumns=false,
157  bool displayRowLabels=true
158  );
159 
174  MonitorSingleTableFolder(
175  const std::string & folderName,
176  const std::vector< ::std::string > & headings,
177  const std::vector<monitor::MonitorContainer*>& containers,
178  int columnWidth = AUTO_SIZE,
179  int hierarchyDepth = 1,
180  int sampleNo = 0,
181  bool unitsInRowLabels = true,
182  const MonitorTableVisitorPtr visitor = MonitorTableVisitorPtr(),
183  bool switchRowsAndColumns=false,
184  bool displayRowLabels=true
185  );
186 
187  virtual ~MonitorSingleTableFolder( );
188 
190  MonitorTable& getTable() const;
191  private:
192  boost::shared_ptr<MonitorTable> table_;
193 };
194 
195 typedef boost::shared_ptr<MonitorSingleTableFolder> MonitorSingleTableFolderPtr;
196 
197 } // namespace carma::ui::rtd
198 } // namespace carma::ui
199 } // namespace carma
200 
201 #endif
const int AUTO_SIZE
Indicate to MonitorSingleTableFolder that we want column widths to be automatically calculated with a...
Definition: MonitorTable.h:43
A generic monitor system container base class.