CustusX  22.04-rc3
An IGT application
cxRep.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 
13 #ifndef CXREP_H_
14 #define CXREP_H_
15 
16 #include "cxResourceVisualizationExport.h"
17 
18 #include <string>
19 
20 #include <boost/shared_ptr.hpp>
21 #include <boost/weak_ptr.hpp>
22 
23 #include <QObject>
24 
25 namespace cx
26 {
27 typedef boost::shared_ptr<class Rep> RepPtr;
28 typedef boost::weak_ptr<class Rep> RepWeakPtr;
29 
30 class Indent;
31 typedef boost::shared_ptr<class View> ViewPtr;
32 
43 class cxResourceVisualization_EXPORT Rep :public QObject
44 {
45  Q_OBJECT
46 public:
47  virtual ~Rep() {}
48 
53  virtual QString getType() const = 0;
54 
62  virtual void connectToView(ViewPtr theView) = 0;
63 
71  virtual void disconnectFromView(ViewPtr theView) = 0;
72 
81  virtual bool isConnectedToView(ViewPtr theView) const = 0;
87  virtual void setName(QString name) = 0;
90  virtual QString getName() const = 0;
95  virtual QString getUid() const = 0;
96 
97  virtual void printSelf(std::ostream & os, Indent indent) = 0;
98 
99 };
100 
101 } // namespace cx
102 
103 #endif /*CXREP_H_*/
boost::shared_ptr< class View > ViewPtr
boost::weak_ptr< class Rep > RepWeakPtr
Definition: cxData.h:38
Formatting class for debug printing of the ssc library.
Definition: cxIndent.h:28
virtual ~Rep()
Definition: cxRep.h:47
boost::shared_ptr< class Rep > RepPtr
Definition: cxRepManager.h:24
Abstract interface for entities that can be added to a View.
Definition: cxRep.h:43
Namespace for all CustusX production code.