]> Creatis software - clitk.git/blob - vv/vvQPacsConnection.h
add move a single image
[clitk.git] / vv / vvQPacsConnection.h
1 #ifndef __vvQPacsConnection_h_INCLUDED__
2 #define __vvQPacsConnection_h_INCLUDED__
3
4 #include <QTGUI/QWidget>
5 #include "ui_vvPacsConnection.h"
6 #include "gdcmCompositeNetworkFunctions.h"
7 #include <QtGui/QStandardItemModel.h>
8 #include <QtGui/QStringListModel.h>
9 #include <QFileDialog>
10 #include "vvDicomServerQueryFactory.h"
11
12   /**
13    * \ingroup GUI
14    */
15   //=====================================================================
16  //======================================================================
17
18
19
20   class vvQPacsConnection : public QDialog 
21   {
22           Q_OBJECT
23   public:
24           //vvQPacsConnection(){}    
25           vvQPacsConnection(QWidget *parent=0);
26     
27           ~vvQPacsConnection(){}
28         void refreshNetworks();
29         std::vector <std::string> getFileNames();
30
31 public slots:
32         void selectStudies(const QModelIndex &index);
33         void selectSeries(const QModelIndex &index);
34         void selectImages(const QModelIndex &index);
35         void selectImage(const QModelIndex &index);
36   private slots:
37     void on_scanButton_clicked();
38         void on_clearButton_clicked();
39         void on_optionsButton_clicked();
40         void on_check_ModAll_clicked(bool state);
41         void on_importButton_clicked();
42  void chooseServer(int index);
43  void removeServer();
44  void modifyServer();
45
46   private :
47
48                 
49           Ui::vvPacsConnection ui;
50         std::vector< std::pair<gdcm::Tag, std::string> > getKeys();
51         std::vector< std::pair<gdcm::Tag, std::string> > getStudyKeys(const std::string);
52         std::vector<gdcm::DataSet> findQuery(vvQuery i_query);
53
54         void manageStudiesFilter(bool i_enable);
55         void createTreeView();
56         void cleanTree();
57         void setNewPacs();
58         QStandardItemModel *Patientmodel;
59         QStandardItemModel *Studymodel;
60         QStandardItemModel *Seriesmodel;
61         QStandardItemModel *Imagesmodel;
62         void convertDataSet(std::vector<gdcm::DataSet> i_ds, QStandardItemModel *i_model, std::vector< std::pair<gdcm::Tag, std::string> > keys);
63         void manageSeriesFilter(bool i_enable);
64         std::vector< std::pair<gdcm::Tag, std::string> > fillMoveKeys();
65         std::string m_patient;
66         std::string m_study;
67         std::string m_series;
68         gdcm::EQueryLevel m_level;
69         std::string m_port;
70         std::string m_aetitle;
71         std::string m_adress;
72         std::string m_nickname;
73         vvDicomServerQueryFactory mQFactory;
74         vvQuery m_query;
75         vvQuery f_query;
76          gdcm::Directory::FilenamesType m_files;
77
78
79         
80   }; // class vvQPacsConnection
81   //=====================================================================
82
83   
84
85 #endif // __vvQPacsConnection_h_INCLUDED__
86
87