casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TBValidityChecker.qo.h
Go to the documentation of this file.
1 //# TBValidityChecker.qo.h: Widget for running TBTests on opened tables.
2 //# Copyright (C) 2005
3 //# Associated Universities, Inc. Washington DC, USA.
4 //#
5 //# This library is free software; you can redistribute it and/or modify it
6 //# under the terms of the GNU Library General Public License as published by
7 //# the Free Software Foundation; either version 2 of the License, or (at your
8 //# option) any later version.
9 //#
10 //# This library is distributed in the hope that it will be useful, but WITHOUT
11 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13 //# License for more details.
14 //#
15 //# You should have received a copy of the GNU Library General Public License
16 //# along with this library; if not, write to the Free Software Foundation,
17 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18 //#
19 //# Correspondence concerning AIPS++ should be addressed as follows:
20 //# Internet email: aips2-request@nrao.edu.
21 //# Postal address: AIPS++ Project Office
22 //# National Radio Astronomy Observatory
23 //# 520 Edgemont Road
24 //# Charlottesville, VA 22903-2475 USA
25 //#
26 //# $Id: $
27 #ifndef TBVALIDITYCHECKER_H_
28 #define TBVALIDITYCHECKER_H_
29 
30 #include <casaqt/QtBrowser/TBValidityChecker.ui.h>
31 
32 #include <casa/BasicSL/String.h>
33 
34 #include <vector>
35 
36 #include <QtGui>
37 
38 namespace casa {
39 
40 //# Forward Declarations
41 class TBBrowser;
42 class TBTest;
43 
44 // <summary>
45 // Widget for running TBTests on opened tables.
46 // </summary>
47 //
48 // <synopsis>
49 // A TBValidityChecker allows the user to select a table and then run any
50 // defined TBTests on it. The pass/fail results are then shown to the user.
51 // </synopsis>
52 
53 class TBValidityChecker : public QWidget, Ui::ValidityChecker {
54  Q_OBJECT
55 
56 public:
57  // Constructor that takes the browser parent.
59 
61 
62 private:
63  // Browser parent.
65 
66  // casacore::List of tests that can be run.
67  std::vector<TBTest*> tests;
68 
69 
70  // Sets up the tests in the GUI.
71  void setupTests();
72 
73 private slots:
74  // Slot for when the user selects a new table.
75  void tableChanged(QString newTable);
76 
77  // Slot for when the user selects a new test. Loads the checks in the
78  // right side of the widget.
79  void loadTest(int index);
80 
81  // Slot to run all checks in the selected test on the selected table.
82  void runChecks();
83 
84  // Slot to run the selected check in the selected test on the selected
85  // table.
86  void runCheck();
87 
88  // Slot for when a new table is opened in the browser. Adds the name to
89  // the list of opened tables.
90  void tableOpened(casacore::String table);
91 
92  // Slot for when a table is closed in the browser. Removes the name from
93  // the list of opened tables.
94  void tableClosed(casacore::String table);
95 };
96 
97 }
98 
99 #endif /* TBVALIDITYCHECKER_H_ */
void runCheck()
Slot to run the selected check in the selected test on the selected table.
TBBrowser * browser
Browser parent.
void tableClosed(casacore::String table)
Slot for when a table is closed in the browser.
void loadTest(int index)
Slot for when the user selects a new test.
Browser widget for managing opened tables.
Definition: TBBrowser.qo.h:63
std::vector< TBTest * > tests
casacore::List of tests that can be run.
Widget for running TBTests on opened tables.
void setupTests()
Sets up the tests in the GUI.
void tableChanged(QString newTable)
Slot for when the user selects a new table.
void runChecks()
Slot to run all checks in the selected test on the selected table.
String: the storage and methods of handling collections of characters.
Definition: String.h:223
void tableOpened(casacore::String table)
Slot for when a new table is opened in the browser.
TBValidityChecker(TBBrowser *browser)
Constructor that takes the browser parent.