Code Documentation 3.7
Social Network Visualizer
Loading...
Searching...
No Matches
table_export.h
Go to the documentation of this file.
1
13
14#pragma once
15
16class QAbstractItemModel;
17class QString;
18
28namespace TableExport {
29
39QString csvQuote(const QString &value);
40
50bool toCSV(QAbstractItemModel *model, const QString &filePath);
51
61bool toJSON(QAbstractItemModel *model, const QString &filePath);
62
63} // namespace TableExport
Free functions that serialise any QAbstractItemModel to CSV or JSON.
Definition table_export.cpp:23
bool toCSV(QAbstractItemModel *model, const QString &filePath)
Writes model to an RFC 4180 CSV file at filePath.
Definition table_export.cpp:39
QString csvQuote(const QString &value)
Returns a CSV-safe quoted field: wraps value in double-quotes if it contains a comma,...
Definition table_export.cpp:25
bool toJSON(QAbstractItemModel *model, const QString &filePath)
Writes model to a JSON file at filePath.
Definition table_export.cpp:76