NorMIT-nav  2023.01.05-dev+develop.0da12
An IGT application
cxPatientData.h
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 
12 #ifndef CXPATIENTDATA_H_
13 #define CXPATIENTDATA_H_
14 
15 #include "org_custusx_core_patientmodel_Export.h"
16 
17 #include "boost/shared_ptr.hpp"
18 #include <QString>
19 #include <QObject>
20 #include "cxForwardDeclarations.h"
21 #include "cxTransform3D.h"
22 #include <QDomDocument>
23 
24 class QDomDocument;
25 
26 namespace cx
27 {
28 
29 typedef boost::shared_ptr<class SessionStorageService> SessionStorageServicePtr;
30 typedef boost::shared_ptr<class DataManager> DataServicePtr;
31 
32 
46 class org_custusx_core_patientmodel_EXPORT PatientData: public QObject
47 {
48 Q_OBJECT
49 public:
50  explicit PatientData(DataServicePtr dataManager, SessionStorageServicePtr session, FileManagerServicePtr fileManager);
51  virtual ~PatientData();
52 
53  QString getActivePatientFolder() const;
54  bool isPatientValid() const;
55 
56 public slots:
61  DataPtr importData(QString fileName, QString &infoText);
62  void removeData(QString uid);
63  void exportPatient(PATIENT_COORDINATE_SYSTEM externalSpace);
64  void autoSave();
65 
66 signals:
67  void patientChanged();
68 
69 private slots:
70  void onCleared();
71  void onSessionLoad(QDomElement& node);
72  void onSessionSave(QDomElement& node);
73 
74 private:
75  DataServicePtr mDataManager;
76  SessionStorageServicePtr mSession;
77  FileManagerServicePtr mFileManagerService;
78 };
79 
80 typedef boost::shared_ptr<PatientData> PatientDataPtr;
81 
82 } // namespace cx
83 
84 #endif /* CXPATIENTDATA_H_ */
cx::PatientDataPtr
boost::shared_ptr< PatientData > PatientDataPtr
Definition: cxPatientData.h:80
cx
Namespace for all CustusX production code.
Definition: cx_dev_group_definitions.h:13
cxForwardDeclarations.h
cx::FileManagerServicePtr
boost::shared_ptr< class FileManagerService > FileManagerServicePtr
Definition: cxLogicManager.h:31
cx::SessionStorageServicePtr
boost::shared_ptr< class SessionStorageService > SessionStorageServicePtr
Definition: cxLogicManager.h:30
cx::DataPtr
boost::shared_ptr< class Data > DataPtr
Definition: cxRegistrationApplicator.h:22
cx::PatientData
Functionality for storing patient data in a folder on the disk and access to these data.
Definition: cxPatientData.h:46
cx::DataServicePtr
boost::shared_ptr< class DataManager > DataServicePtr
Definition: cxDataManagerImpl.h:36
cxTransform3D.h