18 #include <QJsonDocument> 85 title =
new QString(
"");
120 if(
title !=
nullptr) {
141 QByteArray array (json.toStdString().c_str());
142 QJsonDocument doc = QJsonDocument::fromJson(array);
143 QJsonObject jsonObject = doc.object();
193 QJsonDocument doc(*obj);
194 QByteArray bytes = doc.toJson();
196 return QString(bytes);
201 QJsonObject* obj =
new QJsonObject();
209 obj->insert(
"log2Decim", QJsonValue(
log2_decim));
212 obj->insert(
"squelch", QJsonValue(
squelch));
215 obj->insert(
"rgbColor", QJsonValue(
rgb_color));
217 if(
title !=
nullptr && *
title != QString(
"")){
221 obj->insert(
"alphaEMA", QJsonValue(
alpha_ema));
224 obj->insert(
"tracking", QJsonValue(
tracking));
233 obj->insert(
"rrc", QJsonValue(
rrc));
236 obj->insert(
"rrcRolloff", QJsonValue(
rrc_rolloff));
443 bool isObjectUpdated =
false;
450 if(
title !=
nullptr && *
title != QString(
"")){ isObjectUpdated =
true;
break;}
464 return isObjectUpdated;
virtual bool isSet() override
qint32 reverse_api_channel_index
virtual void fromJsonObject(QJsonObject &json) override
void setTracking(qint32 tracking)
bool m_reverse_api_channel_index_isSet
virtual QString asJson() override
void setAlphaEma(float alpha_ema)
bool m_reverse_api_device_index_isSet
void toJsonValue(QString name, void *value, QJsonObject *output, QString type)
qint32 getReverseApiChannelIndex()
void setUseReverseApi(qint32 use_reverse_api)
void setReverseApiChannelIndex(qint32 reverse_api_channel_index)
bool m_reverse_api_port_isSet
void setRgbColor(qint32 rgb_color)
bool m_tracker_type_isSet
void setReverseApiPort(qint32 reverse_api_port)
virtual QJsonObject * asJsonObject() override
bool m_pll_psk_order_isSet
bool m_use_reverse_api_isSet
qint64 input_frequency_offset
qint32 getUseReverseApi()
void setRrcRolloff(qint32 rrc_rolloff)
qint32 getReverseApiDeviceIndex()
virtual SWGFreqTrackerSettings * fromJson(QString &jsonString) override
qint32 getReverseApiPort()
qint32 reverse_api_device_index
bool m_input_frequency_offset_isSet
void setSquelchGate(qint32 squelch_gate)
bool m_rf_bandwidth_isSet
bool m_reverse_api_address_isSet
qint64 getInputFrequencyOffset()
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
QString * reverse_api_address
void setTitle(QString *title)
bool m_squelch_gate_isSet
void setReverseApiAddress(QString *reverse_api_address)
virtual ~SWGFreqTrackerSettings()
void setRfBandwidth(float rf_bandwidth)
void setPllPskOrder(qint32 pll_psk_order)
void setReverseApiDeviceIndex(qint32 reverse_api_device_index)
void setTrackerType(qint32 tracker_type)
QString * getReverseApiAddress()
void setSquelch(float squelch)
void setLog2Decim(qint32 log2_decim)
void setInputFrequencyOffset(qint64 input_frequency_offset)