GOFIGURE2  0.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
QGoWizardDB.h
Go to the documentation of this file.
1 /*=========================================================================
2  Authors: The GoFigure Dev. Team.
3  at Megason Lab, Systems biology, Harvard Medical school, 2009-11
4 
5  Copyright (c) 2009-11, President and Fellows of Harvard College.
6  All rights reserved.
7 
8  Redistribution and use in source and binary forms, with or without
9  modification, are permitted provided that the following conditions are met:
10 
11  Redistributions of source code must retain the above copyright notice,
12  this list of conditions and the following disclaimer.
13  Redistributions in binary form must reproduce the above copyright notice,
14  this list of conditions and the following disclaimer in the documentation
15  and/or other materials provided with the distribution.
16  Neither the name of the President and Fellows of Harvard College
17  nor the names of its contributors may be used to endorse or promote
18  products derived from this software without specific prior written
19  permission.
20 
21  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
23  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
24  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
25  BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
26  OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
27  OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
28  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
30  OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
31  ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 
33 =========================================================================*/
34 #ifndef __QGoWizardDB_h
35 #define __QGoWizardDB_h
36 
37 #include <QWizard>
38 #include <QLineEdit>
39 #include <QLabel>
40 #include <QRadioButton>
41 #include <QFormLayout>
42 #include <QGridLayout>
43 #include <QComboBox>
44 #include <QStringList>
45 #include <QString>
46 #include <QCheckBox>
47 
48 #include <iostream>
49 #include <list>
50 
52 #include "QGoConnectServerPage.h"
53 #include "vtkMySQLDatabase.h"
54 
55 #include "QGoGUILibConfigure.h"
56 
65 class QGOGUILIB_EXPORT QGoWizardDB:public QWizard
66 {
67  Q_OBJECT
68 public:
69  enum {
70  ConnectServerPageID = 0,
73  CreateImgSessionPageID
74  };
75 
76  explicit QGoWizardDB(QWidget *parent = 0);
78 
79  QString GetNameDB();
80 
81  QString GetServer();
82 
83  QString GetLogin();
84 
85  QString GetPassword();
86 
87  QString GetImagingSessionName();
88 
89  int GetImagingSessionID();
90 
91  bool GetIsAnOpenRecentFile();
92 
94 
99  std::vector< std::vector< std::string > > GetFilenamesFromDB();
100 
101  GoFigureFileInfoHelperMultiIndexContainer GetMultiIndexFileContainer();
102 
103  std::string GetMegaCaptureHeaderFilename();
104 
105  void setImgSessionName(std::string iImgSessionName);
106 
107  std::string GetFirstFileName();
108 
109  void SetIsAnOpenRecentFile(bool iIsAnOpenRecentFile);
110 
111 signals:
112  void GofigureDatabaseExists();
113  void NoGofigureDatabase();
114 
115 protected:
116  void closeEvent(QCloseEvent *iEvent);
117 
118  void SetFirstFileName();
119 
121  std::string m_ImgSessionName;
122  std::string m_FirstFileName;
125 private:
126  Q_DISABLE_COPY(QGoWizardDB);
127 };
128 #endif
QGoConnectServerPage * m_ConnectServerPage
Definition: QGoWizardDB.h:120
virtual void closeEvent(QCloseEvent *e)
bool m_IsAnOpenRecentFile
Definition: QGoWizardDB.h:124
int m_ImgSessionID
Definition: QGoWizardDB.h:123
QPushButton * nextButton
Definition: QGoWizardDB.h:93
std::string m_FirstFileName
Definition: QGoWizardDB.h:122
std::string m_ImgSessionName
Definition: QGoWizardDB.h:121
boost::multi_index::multi_index_container< GoFigureFileInfoHelper, boost::multi_index::indexed_by< boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_PCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_RCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_CCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_XTileCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_YTileCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_ZTileCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_ZCoord >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_Channel >, >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< m_TCoord >, > >> GoFigureFileInfoHelperMultiIndexContainer
This class leads the user to chose its imagingsession and enables to get the corresponding filenames ...
Definition: QGoWizardDB.h:65