CustusX  22.04-rc5
An IGT application
cxPatientModelServiceProxy.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 CXPATIENTMODELSERVICEPROXY_H
13 #define CXPATIENTMODELSERVICEPROXY_H
14 
15 #include "cxResourceExport.h"
16 
17 #include "cxPatientModelService.h"
18 #include <boost/shared_ptr.hpp>
20 class ctkPluginContext;
21 
22 namespace cx
23 {
24 
36 class cxResource_EXPORT PatientModelServiceProxy : public PatientModelService
37 {
38 public:
39  static PatientModelServicePtr create(ctkPluginContext *pluginContext);
40  PatientModelServiceProxy(ctkPluginContext *context);
41  virtual ~PatientModelServiceProxy();
42 
43  virtual void insertData(DataPtr data, bool overWrite = false);
44  virtual DataPtr createData(QString type, QString uid, QString name="");
45  virtual std::map<QString, DataPtr> getDatas(DataFilter filter) const;
46  virtual std::map<QString, DataPtr> getChildren(QString parent_uid, QString of_type="") const;
47  virtual DataPtr getData(const QString& uid) const;
48 
49  virtual LandmarksPtr getPatientLandmarks() const;
50  virtual std::map<QString, LandmarkProperty> getLandmarkProperties() const;
51  virtual void setLandmarkName(QString uid, QString name);
52  virtual void setLandmarkActive(QString uid, bool active);
53 
54  virtual RegistrationHistoryPtr get_rMpr_History() const;
55 
56  virtual ActiveDataPtr getActiveData() const;
57 
58  virtual CLINICAL_VIEW getClinicalApplication() const;
59  virtual void setClinicalApplication(CLINICAL_VIEW application);
60 
61  virtual std::map<QString, VideoSourcePtr> getStreams() const;
62 
63  virtual QString getActivePatientFolder() const;
64  virtual bool isPatientValid() const;
65  virtual DataPtr importData(QString fileName, QString &infoText);
66  virtual void exportPatient(PATIENT_COORDINATE_SYSTEM externalSpace);
67  virtual void removeData(QString uid);
68 
69  virtual PresetTransferFunctions3DPtr getPresetTransferFunctions3D() const;
70 
71  virtual void setCenter(const Vector3D& center);
72  virtual Vector3D getCenter() const;
73 
74  virtual void setOperatingTable(const OperatingTable& ot);
75  virtual OperatingTable getOperatingTable() const;
76 
77  virtual QString addLandmark();
78  virtual void deleteLandmarks();
79 
80  virtual void autoSave();
81  virtual bool isNull();
82 
83  virtual void makeAvailable(const QString& uid, bool available);
84 
85 private:
86  void initServiceListener();
87  void onServiceAdded(PatientModelService* service);
88  void onServiceRemoved(PatientModelService *service);
89 
90  ctkPluginContext *mPluginContext;
91  PatientModelServicePtr mPatientModelService;
92  boost::shared_ptr<ServiceTrackerListener<PatientModelService> > mServiceListener;
93 };
94 
95 } // cx
96 #endif // CXPATIENTMODELSERVICEPROXY_H
The virtual patient.
boost::shared_ptr< class RegistrationHistory > RegistrationHistoryPtr
Definition: cxDataManager.h:37
boost::shared_ptr< class TransferFunctions3DPresets > PresetTransferFunctions3DPtr
Definition: cxDataManager.h:36
boost::shared_ptr< class ActiveData > ActiveDataPtr
Definition: cxColorWidget.h:21
boost::shared_ptr< class Landmarks > LandmarksPtr
Definition: cxData.h:41
boost::shared_ptr< class Data > DataPtr
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
Eigen::Vector3d Vector3D
Vector3D is a representation of a point or vector in 3D.
Definition: cxVector3D.h:42
Always provides a PatientModelService.
The OperatingTable class.
Namespace for all CustusX production code.