JsonFilter

A description for JsonFilter.

class JsonFilter : public AbstractFileFilter

Manages the import/export of data from/to a file formatted using JSON.

Public Functions

void readDataFromDevice(QIODevice &device, AbstractDataSource*, ImportMode = ImportMode::Replace, int lines = -1)

reads the content of the device device.

virtual void readDataFromFile(const QString &fileName, AbstractDataSource* = nullptr, ImportMode = ImportMode::Replace) override

reads the content of the file fileName.

virtual void write(const QString &fileName, AbstractDataSource*) override

writes the content of the data source dataSource to the file fileName.

virtual void save(QXmlStreamWriter*) const override

Saves as XML.

virtual bool load(XmlStreamReader*) override

Loads from XML.

Public Static Functions

static QStringList dataTypes()

returns the list of all predefined data types.

static QStringList dataRowTypes()

returns the list of all predefined data row types.