SDRAngel  4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
Public Member Functions | Private Attributes | List of all members
SWGSDRangel::SWGRDSReport_altFrequencies Class Reference

#include <SWGRDSReport_altFrequencies.h>

+ Inheritance diagram for SWGSDRangel::SWGRDSReport_altFrequencies:
+ Collaboration diagram for SWGSDRangel::SWGRDSReport_altFrequencies:

Public Member Functions

 SWGRDSReport_altFrequencies ()
 
 SWGRDSReport_altFrequencies (QString *json)
 
virtual ~SWGRDSReport_altFrequencies ()
 
void init ()
 
void cleanup ()
 
virtual QString asJson () override
 
virtual QJsonObject * asJsonObject () override
 
virtual void fromJsonObject (QJsonObject &json) override
 
virtual SWGRDSReport_altFrequenciesfromJson (QString &jsonString) override
 
float getFrequency ()
 
void setFrequency (float frequency)
 
virtual bool isSet () override
 
- Public Member Functions inherited from SWGSDRangel::SWGObject
virtual ~SWGObject ()
 

Private Attributes

float frequency
 
bool m_frequency_isSet
 

Detailed Description

Definition at line 31 of file SWGRDSReport_altFrequencies.h.

Constructor & Destructor Documentation

◆ SWGRDSReport_altFrequencies() [1/2]

SWGSDRangel::SWGRDSReport_altFrequencies::SWGRDSReport_altFrequencies ( )

◆ SWGRDSReport_altFrequencies() [2/2]

SWGSDRangel::SWGRDSReport_altFrequencies::SWGRDSReport_altFrequencies ( QString *  json)

Definition at line 25 of file SWGRDSReport_altFrequencies.cpp.

References fromJson(), and init().

25  {
26  init();
27  this->fromJson(*json);
28 }
virtual SWGRDSReport_altFrequencies * fromJson(QString &jsonString) override
+ Here is the call graph for this function:

◆ ~SWGRDSReport_altFrequencies()

SWGSDRangel::SWGRDSReport_altFrequencies::~SWGRDSReport_altFrequencies ( )
virtual

Definition at line 35 of file SWGRDSReport_altFrequencies.cpp.

References cleanup().

+ Here is the call graph for this function:

Member Function Documentation

◆ asJson()

QString SWGSDRangel::SWGRDSReport_altFrequencies::asJson ( )
overridevirtual

Reimplemented from SWGSDRangel::SWGObject.

Definition at line 66 of file SWGRDSReport_altFrequencies.cpp.

References asJsonObject().

67 {
68  QJsonObject* obj = this->asJsonObject();
69 
70  QJsonDocument doc(*obj);
71  QByteArray bytes = doc.toJson();
72  delete obj;
73  return QString(bytes);
74 }
+ Here is the call graph for this function:

◆ asJsonObject()

QJsonObject * SWGSDRangel::SWGRDSReport_altFrequencies::asJsonObject ( )
overridevirtual

Reimplemented from SWGSDRangel::SWGObject.

Definition at line 77 of file SWGRDSReport_altFrequencies.cpp.

References frequency, and m_frequency_isSet.

Referenced by asJson().

77  {
78  QJsonObject* obj = new QJsonObject();
80  obj->insert("frequency", QJsonValue(frequency));
81  }
82 
83  return obj;
84 }
+ Here is the caller graph for this function:

◆ cleanup()

void SWGSDRangel::SWGRDSReport_altFrequencies::cleanup ( )

Definition at line 46 of file SWGRDSReport_altFrequencies.cpp.

Referenced by ~SWGRDSReport_altFrequencies().

46  {
47 
48 }
+ Here is the caller graph for this function:

◆ fromJson()

SWGRDSReport_altFrequencies * SWGSDRangel::SWGRDSReport_altFrequencies::fromJson ( QString &  jsonString)
overridevirtual

Reimplemented from SWGSDRangel::SWGObject.

Definition at line 51 of file SWGRDSReport_altFrequencies.cpp.

References fromJsonObject().

Referenced by SWGRDSReport_altFrequencies().

51  {
52  QByteArray array (json.toStdString().c_str());
53  QJsonDocument doc = QJsonDocument::fromJson(array);
54  QJsonObject jsonObject = doc.object();
55  this->fromJsonObject(jsonObject);
56  return this;
57 }
virtual void fromJsonObject(QJsonObject &json) override
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ fromJsonObject()

void SWGSDRangel::SWGRDSReport_altFrequencies::fromJsonObject ( QJsonObject &  json)
overridevirtual

Reimplemented from SWGSDRangel::SWGObject.

Definition at line 60 of file SWGRDSReport_altFrequencies.cpp.

References frequency, and SWGSDRangel::setValue().

Referenced by fromJson().

60  {
61  ::SWGSDRangel::setValue(&frequency, pJson["frequency"], "float", "");
62 
63 }
void setValue(void *value, QJsonValue obj, QString type, QString complexType)
Definition: SWGHelpers.cpp:25
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getFrequency()

float SWGSDRangel::SWGRDSReport_altFrequencies::getFrequency ( )

Definition at line 87 of file SWGRDSReport_altFrequencies.cpp.

References frequency.

◆ init()

void SWGSDRangel::SWGRDSReport_altFrequencies::init ( )

Definition at line 40 of file SWGRDSReport_altFrequencies.cpp.

References frequency, and m_frequency_isSet.

Referenced by SWGRDSReport_altFrequencies().

+ Here is the caller graph for this function:

◆ isSet()

bool SWGSDRangel::SWGRDSReport_altFrequencies::isSet ( )
overridevirtual

Reimplemented from SWGSDRangel::SWGObject.

Definition at line 98 of file SWGRDSReport_altFrequencies.cpp.

References m_frequency_isSet.

98  {
99  bool isObjectUpdated = false;
100  do{
101  if(m_frequency_isSet){ isObjectUpdated = true; break;}
102  }while(false);
103  return isObjectUpdated;
104 }

◆ setFrequency()

void SWGSDRangel::SWGRDSReport_altFrequencies::setFrequency ( float  frequency)

Member Data Documentation

◆ frequency

float SWGSDRangel::SWGRDSReport_altFrequencies::frequency
private

◆ m_frequency_isSet

bool SWGSDRangel::SWGRDSReport_altFrequencies::m_frequency_isSet
private

The documentation for this class was generated from the following files: