| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 | .TH "AJson" 3 "Mon Jul 11 2022" "openPilotLog" \" -*- nroff -*-.ad l.nh.SH NAMEAJson \- The AJSON class is responsible for parsing the database (sqlite) to and from JSON\&.  .SH SYNOPSIS.br.PP.PP\fC#include <ajson\&.h>\fP.SS "Public Member Functions".in +1c.ti -1c.RI "\fBAJson\fP (QFileInfo database_file)".br.in -1c.SS "Static Public Member Functions".in +1c.ti -1c.RI "static void \fBexportDatabase\fP ()".br.RI "exportDatabase exports the currently active database to JSON\&. ".ti -1c.RI "static void \fBimportDatabase\fP ()".br.RI "importDatabase imports a dataset from JSON\&. Files need to be at AStanardPaths::JSON for now\&. ".ti -1c.RI "static QJsonDocument \fBreadFileToDoc\fP (const QString &file_path)".br.RI "readToDocument reads data from a JSON file into a QJSonDocument ".ti -1c.RI "static void \fBwriteDocToFile\fP (const QJsonDocument &doc, const QString &file_name)".br.RI "writes a QJsonDocument to a file ".in -1c.SH "Detailed Description".PP The AJSON class is responsible for parsing the database (sqlite) to and from JSON\&. .SH "Member Function Documentation".PP .SS "void AJson::exportDatabase ()\fC [static]\fP".PPexportDatabase exports the currently active database to JSON\&. QJsonObject can be constructed from QHash<QString, QVariant> aka QVariantmap\&. All rows are put into a QJsonArray and the Array is embedded into a QJsonDocument, which can be exported\&. The files are created at AStandardPaths::JSON\&. .SS "QJsonDocument AJson::readFileToDoc (const QString & file_path)\fC [static]\fP".PPreadToDocument reads data from a JSON file into a QJSonDocument .PP\fBParameters\fP.RS 4\fIfile_path\fP .RE.PP.SH "Author".PP Generated automatically by Doxygen for openPilotLog from the source code\&.
 |