MNE-CPP  beta 1.0
realtimecov.h
Go to the documentation of this file.
1 //=============================================================================================================
36 #ifndef REALTIMECOV_H
37 #define REALTIMECOV_H
38 
39 
40 //*************************************************************************************************************
41 //=============================================================================================================
42 // INCLUDES
43 //=============================================================================================================
44 
45 #include "xmeas_global.h"
46 #include "newmeasurement.h"
48 
49 #include <fiff/fiff_cov.h>
50 
51 
52 //*************************************************************************************************************
53 //=============================================================================================================
54 // Qt INCLUDES
55 //=============================================================================================================
56 
57 #include <QSharedPointer>
58 #include <QVector>
59 #include <QList>
60 #include <QColor>
61 #include <QMutex>
62 #include <QMutexLocker>
63 
64 
65 //*************************************************************************************************************
66 //=============================================================================================================
67 // DEFINE NAMESPACE XMEASLIB
68 //=============================================================================================================
69 
70 namespace XMEASLIB
71 {
72 
73 
74 //*************************************************************************************************************
75 //=============================================================================================================
76 // USED NAMESPACES
77 //=============================================================================================================
78 
79 using namespace FIFFLIB;
80 
81 
82 //=========================================================================================================
89 {
90  Q_OBJECT
91 public:
92  typedef QSharedPointer<RealTimeCov> SPtr;
93  typedef QSharedPointer<const RealTimeCov> ConstSPtr;
95  //=========================================================================================================
99  explicit RealTimeCov(QObject *parent = 0);
100 
101  //=========================================================================================================
105  virtual ~RealTimeCov();
106 
107  //=========================================================================================================
113  virtual void setValue(FiffCov& v);
114 
115  //=========================================================================================================
122  virtual FiffCov::SPtr& getValue();
123 
124  //=========================================================================================================
130  inline bool isInitialized() const;
131 
132 private:
133  mutable QMutex m_qMutex;
135  FiffCov::SPtr m_pFiffCov;
137  bool m_bInitialized;
138 };
139 
140 
141 //*************************************************************************************************************
142 //=============================================================================================================
143 // INLINE DEFINITIONS
144 //=============================================================================================================
145 
146 inline bool RealTimeCov::isInitialized() const
147 {
148  QMutexLocker locker(&m_qMutex);
149  return m_bInitialized;
150 }
151 
152 } // NAMESPACE
153 
154 Q_DECLARE_METATYPE(XMEASLIB::RealTimeCov::SPtr)
155 
156 #endif // REALTIMECOV_H
The RealTimeMultiSampleArrayNew class is the base class of every RealTimeMultiSampleArrayNew Measurem...
Definition: realtimecov.h:88
QSharedPointer< FiffCov > SPtr
Definition: fiff_cov.h:97
QSharedPointer< RealTimeCov > SPtr
Definition: realtimecov.h:92
Contains the declaration of the NewMeasurement class.
#define XMEASSHARED_EXPORT
Definition: xmeas_global.h:54
Contains the declaration of the RealTimeSampleArrayChInfo class.
covariance data
Definition: fiff_cov.h:94
Definition: fiff.h:98
QSharedPointer< const RealTimeCov > ConstSPtr
Definition: realtimecov.h:93
bool isInitialized() const
Definition: realtimecov.h:146
Contains the xMeas library export/import macros.
FiffCov class declaration.