v2.0.0
Loading...
Searching...
No Matches
fiff_file_sharer.h
Go to the documentation of this file.
1//=============================================================================================================
19
20#ifndef FIFF_FILE_SHARER_H
21#define FIFF_FILE_SHARER_H
22
23//=============================================================================================================
24// INCLUDES
25//=============================================================================================================
26
27#include "fiff_io.h"
28
29//=============================================================================================================
30// QT INCLUDES
31//=============================================================================================================
32
33#include <QFileSystemWatcher>
34
35//=============================================================================================================
36// DEFINE NAMESPACE FIFFLIB
37//=============================================================================================================
38
39namespace FIFFLIB
40{
41
42//=============================================================================================================
51class FIFFSHARED_EXPORT FiffFileSharer : public QObject
52{
53 Q_OBJECT
54public:
55
56 //=========================================================================================================
61
62 //=========================================================================================================
68 FiffFileSharer(const QString& sDirName);
69
70 //=========================================================================================================
76 void copyRealtimeFile(const QString &sSourcePath);
77
78 //=========================================================================================================
82 void initWatcher();
83
84private:
85
86 //=========================================================================================================
92 bool initSharedDirectory();
93
94 //=========================================================================================================
98 void clearSharedDirectory();
99
100 //=========================================================================================================
107 void onDirectoryChanged(const QString &sPath);
108
109 //=========================================================================================================
116 void onFileChanged(const QString &sPath);
117
118 QFileSystemWatcher m_fileWatcher;
119
120 QString m_sDirectory;
121 int m_iFileIndex;
122
123signals:
124
125 //=========================================================================================================
131 void newFileAtPath(const QString& sPath);
132
133};
134} //namespace
135
136#endif // FIFF_FILE_SHARER_H
High-level convenience reader/writer that loads a whole FIFF measurement file into FIFFLIB containers...
#define FIFFSHARED_EXPORT
Definition fiff_global.h:44
FIFF file I/O, in-memory data structures and high-level readers/writers.
void newFileAtPath(const QString &sPath)
void copyRealtimeFile(const QString &sSourcePath)