18 #include <QJsonDocument> 87 title =
new QString(
"");
118 if(
title !=
nullptr) {
138 QByteArray array (json.toStdString().c_str());
139 QJsonDocument doc = QJsonDocument::fromJson(array);
140 QJsonObject jsonObject = doc.object();
188 QJsonDocument doc(*obj);
189 QByteArray bytes = doc.toJson();
191 return QString(bytes);
196 QJsonObject* obj =
new QJsonObject();
204 obj->insert(
"squelch", QJsonValue(
squelch));
207 obj->insert(
"volume", QJsonValue(
volume));
210 obj->insert(
"audioMute", QJsonValue(
audio_mute));
216 obj->insert(
"rgbColor", QJsonValue(
rgb_color));
218 if(
title !=
nullptr && *
title != QString(
"")){
225 obj->insert(
"pll", QJsonValue(
pll));
425 bool isObjectUpdated =
false;
434 if(
title !=
nullptr && *
title != QString(
"")){ isObjectUpdated =
true;
break;}
445 return isObjectUpdated;
qint32 getReverseApiPort()
bool m_audio_device_name_isSet
bool m_reverse_api_channel_index_isSet
void toJsonValue(QString name, void *value, QJsonObject *output, QString type)
bool m_rf_bandwidth_isSet
void setAudioDeviceName(QString *audio_device_name)
qint32 getReverseApiChannelIndex()
virtual SWGAMDemodSettings * fromJson(QString &jsonString) override
void setSquelch(float squelch)
bool m_stream_index_isSet
bool m_reverse_api_port_isSet
virtual void fromJsonObject(QJsonObject &json) override
void setSyncAmOperation(qint32 sync_am_operation)
bool m_reverse_api_device_index_isSet
void setReverseApiAddress(QString *reverse_api_address)
virtual QJsonObject * asJsonObject() override
QString * getAudioDeviceName()
QString * reverse_api_address
qint32 getUseReverseApi()
qint32 reverse_api_device_index
qint32 getBandpassEnable()
void setUseReverseApi(qint32 use_reverse_api)
void setBandpassEnable(qint32 bandpass_enable)
void setRfBandwidth(float rf_bandwidth)
qint32 getSyncAmOperation()
void setRgbColor(qint32 rgb_color)
void setInputFrequencyOffset(qint64 input_frequency_offset)
bool m_use_reverse_api_isSet
bool m_input_frequency_offset_isSet
qint64 getInputFrequencyOffset()
virtual QString asJson() override
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
qint32 reverse_api_channel_index
qint32 getReverseApiDeviceIndex()
virtual bool isSet() override
void setVolume(float volume)
void setReverseApiChannelIndex(qint32 reverse_api_channel_index)
void setAudioMute(qint32 audio_mute)
void setReverseApiDeviceIndex(qint32 reverse_api_device_index)
bool m_sync_am_operation_isSet
bool m_reverse_api_address_isSet
QString * audio_device_name
virtual ~SWGAMDemodSettings()
void setReverseApiPort(qint32 reverse_api_port)
qint64 input_frequency_offset
void setStreamIndex(qint32 stream_index)
bool m_bandpass_enable_isSet
QString * getReverseApiAddress()
void setTitle(QString *title)