18 #include <QJsonDocument> 129 QByteArray array (json.toStdString().c_str());
130 QJsonDocument doc = QJsonDocument::fromJson(array);
131 QJsonObject jsonObject = doc.object();
177 QJsonDocument doc(*obj);
178 QByteArray bytes = doc.toJson();
180 return QString(bytes);
185 QJsonObject* obj =
new QJsonObject();
199 obj->insert(
"lpfBW", QJsonValue(
lpf_bw));
202 obj->insert(
"gain", QJsonValue(
gain));
205 obj->insert(
"ncoEnable", QJsonValue(
nco_enable));
214 obj->insert(
"extClock", QJsonValue(
ext_clock));
220 obj->insert(
"pwrmode", QJsonValue(
pwrmode));
401 bool isObjectUpdated =
false;
420 return isObjectUpdated;
bool m_center_frequency_isSet
qint32 getReverseApiPort()
virtual SWGXtrxOutputSettings * fromJson(QString &jsonString) override
qint32 getReverseApiDeviceIndex()
void toJsonValue(QString name, void *value, QJsonObject *output, QString type)
void setExtClockFreq(qint32 ext_clock_freq)
void setUseReverseApi(qint32 use_reverse_api)
bool m_dev_sample_rate_isSet
virtual QString asJson() override
qint32 getLog2HardInterp()
void setGain(qint32 gain)
virtual bool isSet() override
void setReverseApiPort(qint32 reverse_api_port)
qint32 getUseReverseApi()
qint64 getCenterFrequency()
virtual void fromJsonObject(QJsonObject &json) override
void setNcoFrequency(qint32 nco_frequency)
void setAntennaPath(qint32 antenna_path)
void setLog2SoftInterp(qint32 log2_soft_interp)
void setNcoEnable(qint32 nco_enable)
void setLpfBw(qint32 lpf_bw)
bool m_log2_soft_interp_isSet
QString * getReverseApiAddress()
void setPwrmode(qint32 pwrmode)
bool m_reverse_api_device_index_isSet
bool m_antenna_path_isSet
virtual ~SWGXtrxOutputSettings()
qint32 getDevSampleRate()
void setLog2HardInterp(qint32 log2_hard_interp)
bool m_use_reverse_api_isSet
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
bool m_ext_clock_freq_isSet
bool m_log2_hard_interp_isSet
qint32 reverse_api_device_index
bool m_reverse_api_address_isSet
void setDevSampleRate(qint32 dev_sample_rate)
virtual QJsonObject * asJsonObject() override
void setExtClock(qint32 ext_clock)
qint32 getLog2SoftInterp()
QString * reverse_api_address
void setReverseApiAddress(QString *reverse_api_address)
void setCenterFrequency(qint64 center_frequency)
bool m_nco_frequency_isSet
bool m_reverse_api_port_isSet
void setReverseApiDeviceIndex(qint32 reverse_api_device_index)