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.
SWGRange.h
Go to the documentation of this file.
1 
13 /*
14  * SWGRange.h
15  *
16  * An arbitrary range of integer values
17  */
18 
19 #ifndef SWGRange_H_
20 #define SWGRange_H_
21 
22 #include <QJsonObject>
23 
24 
25 
26 #include "SWGObject.h"
27 #include "export.h"
28 
29 namespace SWGSDRangel {
30 
31 class SWG_API SWGRange: public SWGObject {
32 public:
33  SWGRange();
34  SWGRange(QString* json);
35  virtual ~SWGRange();
36  void init();
37  void cleanup();
38 
39  virtual QString asJson () override;
40  virtual QJsonObject* asJsonObject() override;
41  virtual void fromJsonObject(QJsonObject &json) override;
42  virtual SWGRange* fromJson(QString &jsonString) override;
43 
44  qint32 getMin();
45  void setMin(qint32 min);
46 
47  qint32 getMax();
48  void setMax(qint32 max);
49 
50  qint32 getStep();
51  void setStep(qint32 step);
52 
53 
54  virtual bool isSet() override;
55 
56 private:
57  qint32 min;
59 
60  qint32 max;
62 
63  qint32 step;
65 
66 };
67 
68 }
69 
70 #endif /* SWGRange_H_ */
#define SWG_API
Definition: export.h:124
T max(const T &x, const T &y)
Definition: framework.h:446
T min(const T &x, const T &y)
Definition: framework.h:440