WARNING: USE THIS SOFTWARE AT YOUR OWN RISK! THIS IS EXPERIMENTAL SOFTWARE NOT INTENDED FOR PRODUCTION USE! Zuble is currently an early stage prototype. As such Zuble is minimally tested and inherently unstable. It is provided for experimental, development, and demonstration purposes only. | Zuble QML Types | Zuble C++ Classes | Zuble Overview |
Zuble
0.1
Zuble Framework C++/QML extension API
|
This class in theory allows reading and writing of ZTableModel objects to JSON files. (TBD: currently unused/untested?) More...
#include <ZTableFile.h>
Signals | |
void | fileModified (const QString &path) |
Sent whenever the data file is modified by this or other programs. More... | |
Public Member Functions | |
ZTableFile (QObject *parent=0) | |
Q_INVOKABLE bool | readFile (const QString &filePath) |
Reads the specified table file into the data table. Previous data in the table is discarded. More... | |
Q_INVOKABLE bool | writeFile (const QString &filePath) |
Writes the data table to the specified file. Returns true if successful; otherwise returns false. More... | |
Protected Member Functions | |
ZBL_DECLARE_LOGGED_OBJECT void | validateWatcher () |
Protected Attributes | |
QString | m_filePath |
Path to the file that was last read or written. More... | |
QFileSystemWatcher * | m_watcher |
Monitors table data file for updates from this and other applications. More... | |
ZTableModel * | m_data |
The data model that will send or receive data. More... | |
Static Protected Attributes | |
static qint64 | m_maxFileBytes = 100000 * 1024 |
This class in theory allows reading and writing of ZTableModel objects to JSON files. (TBD: currently unused/untested?)
Definition at line 44 of file ZTableFile.h.
|
explicit |
Definition at line 41 of file ZTableFile.cpp.
|
signal |
Sent whenever the data file is modified by this or other programs.
path | Path to the data file. |
Referenced by ZTableFile().
bool Zbl::ZTableFile::readFile | ( | const QString & | filePath | ) |
Reads the specified table file into the data table. Previous data in the table is discarded.
filePath | path of the file to read. Returns true if successful; otherwise returns false. |
Definition at line 79 of file ZTableFile.cpp.
|
protected |
Definition at line 57 of file ZTableFile.cpp.
bool Zbl::ZTableFile::writeFile | ( | const QString & | filePath | ) |
Writes the data table to the specified file. Returns true if successful; otherwise returns false.
Definition at line 172 of file ZTableFile.cpp.
|
protected |
The data model that will send or receive data.
Definition at line 102 of file ZTableFile.h.
Referenced by readFile(), writeFile(), and ZTableFile().
|
protected |
Path to the file that was last read or written.
Definition at line 89 of file ZTableFile.h.
Referenced by readFile(), and writeFile().
|
staticprotected |
Definition at line 105 of file ZTableFile.h.
Referenced by readFile().
|
protected |
Monitors table data file for updates from this and other applications.
Definition at line 96 of file ZTableFile.h.
Referenced by readFile(), validateWatcher(), writeFile(), and ZTableFile().
Zuble documentation copyright © 2019 Bob Dinitto. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Zuble is a derivative work of Qt version 5. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.