18 #include <QJsonDocument> 146 QByteArray array (json.toStdString().c_str());
147 QJsonDocument doc = QJsonDocument::fromJson(array);
148 QJsonObject jsonObject = doc.object();
200 QJsonDocument doc(*obj);
201 QByteArray bytes = doc.toJson();
203 return QString(bytes);
208 QJsonObject* obj =
new QJsonObject();
219 obj->insert(
"log2Decim", QJsonValue(
log2_decim));
228 obj->insert(
"bandIndex", QJsonValue(
band_index));
246 obj->insert(
"useAGC", QJsonValue(
use_agc));
249 obj->insert(
"agcHigh", QJsonValue(
agc_high));
252 obj->insert(
"useDSP", QJsonValue(
use_dsp));
255 obj->insert(
"useLNA", QJsonValue(
use_lna));
261 obj->insert(
"dcBlock", QJsonValue(
dc_block));
463 bool isObjectUpdated =
false;
485 return isObjectUpdated;
QString * reverse_api_address
bool m_reverse_api_address_isSet
void toJsonValue(QString name, void *value, QJsonObject *output, QString type)
virtual ~SWGAirspyHFSettings()
virtual QString asJson() override
bool m_reverse_api_port_isSet
void setReverseApiDeviceIndex(qint32 reverse_api_device_index)
void setUseReverseApi(qint32 use_reverse_api)
bool m_reverse_api_device_index_isSet
void setReverseApiAddress(QString *reverse_api_address)
void setTransverterDeltaFrequency(qint64 transverter_delta_frequency)
QString * getReverseApiAddress()
qint32 getAttenuatorSteps()
bool m_use_reverse_api_isSet
bool m_attenuator_steps_isSet
virtual QJsonObject * asJsonObject() override
qint32 dev_sample_rate_index
bool m_transverter_delta_frequency_isSet
QString * file_record_name
qint32 getTransverterMode()
void setDcBlock(qint32 dc_block)
void setUseAgc(qint32 use_agc)
qint32 getReverseApiDeviceIndex()
void setDevSampleRateIndex(qint32 dev_sample_rate_index)
void setLog2Decim(qint32 log2_decim)
qint64 getCenterFrequency()
virtual SWGAirspyHFSettings * fromJson(QString &jsonString) override
void setBandIndex(qint32 band_index)
bool m_file_record_name_isSet
QString * getFileRecordName()
bool m_l_oppm_tenths_isSet
void setLOppmTenths(qint32 l_oppm_tenths)
virtual bool isSet() override
void setUseDsp(qint32 use_dsp)
void setIqCorrection(qint32 iq_correction)
qint64 transverter_delta_frequency
bool m_center_frequency_isSet
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
qint32 getDevSampleRateIndex()
void setReverseApiPort(qint32 reverse_api_port)
void setCenterFrequency(qint64 center_frequency)
void setFileRecordName(QString *file_record_name)
virtual void fromJsonObject(QJsonObject &json) override
bool m_transverter_mode_isSet
qint32 reverse_api_device_index
void setAgcHigh(qint32 agc_high)
qint32 getUseReverseApi()
qint32 getReverseApiPort()
void setUseLna(qint32 use_lna)
void setTransverterMode(qint32 transverter_mode)
qint64 getTransverterDeltaFrequency()
void setAttenuatorSteps(qint32 attenuator_steps)
bool m_iq_correction_isSet
bool m_dev_sample_rate_index_isSet