18 #include <QJsonDocument> 95 QByteArray array (json.toStdString().c_str());
96 QJsonDocument doc = QJsonDocument::fromJson(array);
97 QJsonObject jsonObject = doc.object();
127 QJsonDocument doc(*obj);
128 QByteArray bytes = doc.toJson();
130 return QString(bytes);
135 QJsonObject* obj =
new QJsonObject();
155 obj->insert(
"sampleRate", QJsonValue(
sample_rate));
247 bool isObjectUpdated =
false;
249 if(
file_name !=
nullptr && *
file_name != QString(
"")){ isObjectUpdated =
true;
break;}
258 return isObjectUpdated;
void setSampleRate(qint32 sample_rate)
void setDurationTime(QString *duration_time)
virtual QString asJson() override
void setFileName(QString *file_name)
void toJsonValue(QString name, void *value, QJsonObject *output, QString type)
bool m_file_sample_size_isSet
QString * getAbsoluteTime()
bool m_absolute_time_isSet
virtual SWGFileSourceReport * fromJson(QString &jsonString) override
bool m_duration_time_isSet
QString * getElapsedTime()
qint32 getFileSampleRate()
qint32 getFileSampleSize()
virtual bool isSet() override
void setFileSampleRate(qint32 file_sample_rate)
QString * getDurationTime()
virtual QJsonObject * asJsonObject() override
void setChannelPowerDb(float channel_power_db)
bool m_elapsed_time_isSet
void setElapsedTime(QString *elapsed_time)
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
virtual ~SWGFileSourceReport()
void setAbsoluteTime(QString *absolute_time)
float getChannelPowerDb()
bool m_channel_power_db_isSet
virtual void fromJsonObject(QJsonObject &json) override
bool m_file_sample_rate_isSet
void setFileSampleSize(qint32 file_sample_size)