From c93444a75abaa1220ca1df82986c1237dc83f765 Mon Sep 17 00:00:00 2001 From: srcejon Date: Thu, 8 Feb 2024 11:37:17 +0000 Subject: [PATCH] Update Sky Map yaml --- sdrbase/resources/webapi/doc/html2/index.html | 17 +++++++++++++- .../webapi/doc/swagger/include/SkyMap.yaml | 8 +++++++ .../sdrangel/api/swagger/include/SkyMap.yaml | 8 +++++++ swagger/sdrangel/code/html2/index.html | 17 +++++++++++++- .../code/qt5/client/SWGSkyMapReport.cpp | 23 +++++++++++++++++++ .../code/qt5/client/SWGSkyMapReport.h | 6 +++++ .../code/qt5/client/SWGSkyMapTarget.cpp | 23 +++++++++++++++++++ .../code/qt5/client/SWGSkyMapTarget.h | 6 +++++ .../code/qt5/client/SWGSkyMapTarget_2.cpp | 23 +++++++++++++++++++ .../code/qt5/client/SWGSkyMapTarget_2.h | 6 +++++ 10 files changed, 135 insertions(+), 2 deletions(-) diff --git a/sdrbase/resources/webapi/doc/html2/index.html b/sdrbase/resources/webapi/doc/html2/index.html index d5f743301..3cedbfd4c 100644 --- a/sdrbase/resources/webapi/doc/html2/index.html +++ b/sdrbase/resources/webapi/doc/html2/index.html @@ -14663,6 +14663,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "azimuth" : { "type" : "number", "format" : "float", @@ -14772,6 +14777,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "hpbw" : { "type" : "number", "format" : "float", @@ -14806,6 +14816,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "hpbw" : { "type" : "number", "format" : "float", @@ -58628,7 +58643,7 @@ except ApiException as e:
- Generated 2024-02-08T12:07:33.630+01:00 + Generated 2024-02-08T12:36:55.592+01:00
diff --git a/sdrbase/resources/webapi/doc/swagger/include/SkyMap.yaml b/sdrbase/resources/webapi/doc/swagger/include/SkyMap.yaml index 0639e2efe..5ffdf9b90 100644 --- a/sdrbase/resources/webapi/doc/swagger/include/SkyMap.yaml +++ b/sdrbase/resources/webapi/doc/swagger/include/SkyMap.yaml @@ -70,6 +70,10 @@ SkyMapReport: description: "Longitude in decimal degrees (East positive) of observation/antenna location" type: number format: float + altitude: + description: "Altitude in metres of observation/antenna location" + type: number + format: float azimuth: description: "The azimuth angle in degrees to the target" type: number @@ -109,6 +113,10 @@ SkyMapTarget: description: "Longitude in decimal degrees (East positive) of observation/antenna location" type: number format: float + altitude: + description: "Altitude in metres of observation/antenna location" + type: number + format: float hpbw: description: "Antenna half-power beam width in degrees" type: number diff --git a/swagger/sdrangel/api/swagger/include/SkyMap.yaml b/swagger/sdrangel/api/swagger/include/SkyMap.yaml index ea9dd4371..251e290ce 100644 --- a/swagger/sdrangel/api/swagger/include/SkyMap.yaml +++ b/swagger/sdrangel/api/swagger/include/SkyMap.yaml @@ -70,6 +70,10 @@ SkyMapReport: description: "Longitude in decimal degrees (East positive) of observation/antenna location" type: number format: float + altitude: + description: "Altitude in metres of observation/antenna location" + type: number + format: float azimuth: description: "The azimuth angle in degrees to the target" type: number @@ -109,6 +113,10 @@ SkyMapTarget: description: "Longitude in decimal degrees (East positive) of observation/antenna location" type: number format: float + altitude: + description: "Altitude in metres of observation/antenna location" + type: number + format: float hpbw: description: "Antenna half-power beam width in degrees" type: number diff --git a/swagger/sdrangel/code/html2/index.html b/swagger/sdrangel/code/html2/index.html index d5f743301..3cedbfd4c 100644 --- a/swagger/sdrangel/code/html2/index.html +++ b/swagger/sdrangel/code/html2/index.html @@ -14663,6 +14663,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "azimuth" : { "type" : "number", "format" : "float", @@ -14772,6 +14777,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "hpbw" : { "type" : "number", "format" : "float", @@ -14806,6 +14816,11 @@ margin-bottom: 20px; "format" : "float", "description" : "Longitude in decimal degrees (East positive) of observation/antenna location" }, + "altitude" : { + "type" : "number", + "format" : "float", + "description" : "Altitude in metres of observation/antenna location" + }, "hpbw" : { "type" : "number", "format" : "float", @@ -58628,7 +58643,7 @@ except ApiException as e:
- Generated 2024-02-08T12:07:33.630+01:00 + Generated 2024-02-08T12:36:55.592+01:00
diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.cpp b/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.cpp index 7be325228..6d4e5f721 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.cpp @@ -38,6 +38,8 @@ SWGSkyMapReport::SWGSkyMapReport() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; azimuth = 0.0f; m_azimuth_isSet = false; elevation = 0.0f; @@ -62,6 +64,8 @@ SWGSkyMapReport::init() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; azimuth = 0.0f; m_azimuth_isSet = false; elevation = 0.0f; @@ -82,6 +86,7 @@ SWGSkyMapReport::cleanup() { + } SWGSkyMapReport* @@ -105,6 +110,8 @@ SWGSkyMapReport::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&longitude, pJson["longitude"], "float", ""); + ::SWGSDRangel::setValue(&altitude, pJson["altitude"], "float", ""); + ::SWGSDRangel::setValue(&azimuth, pJson["azimuth"], "float", ""); ::SWGSDRangel::setValue(&elevation, pJson["elevation"], "float", ""); @@ -142,6 +149,9 @@ SWGSkyMapReport::asJsonObject() { if(m_longitude_isSet){ obj->insert("longitude", QJsonValue(longitude)); } + if(m_altitude_isSet){ + obj->insert("altitude", QJsonValue(altitude)); + } if(m_azimuth_isSet){ obj->insert("azimuth", QJsonValue(azimuth)); } @@ -205,6 +215,16 @@ SWGSkyMapReport::setLongitude(float longitude) { this->m_longitude_isSet = true; } +float +SWGSkyMapReport::getAltitude() { + return altitude; +} +void +SWGSkyMapReport::setAltitude(float altitude) { + this->altitude = altitude; + this->m_altitude_isSet = true; +} + float SWGSkyMapReport::getAzimuth() { return azimuth; @@ -255,6 +275,9 @@ SWGSkyMapReport::isSet(){ if(m_longitude_isSet){ isObjectUpdated = true; break; } + if(m_altitude_isSet){ + isObjectUpdated = true; break; + } if(m_azimuth_isSet){ isObjectUpdated = true; break; } diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.h b/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.h index 7a42d8046..b35e1e1e9 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.h +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapReport.h @@ -57,6 +57,9 @@ public: float getLongitude(); void setLongitude(float longitude); + float getAltitude(); + void setAltitude(float altitude); + float getAzimuth(); void setAzimuth(float azimuth); @@ -85,6 +88,9 @@ private: float longitude; bool m_longitude_isSet; + float altitude; + bool m_altitude_isSet; + float azimuth; bool m_azimuth_isSet; diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.cpp b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.cpp index a91664db4..5397fb31f 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.cpp @@ -36,6 +36,8 @@ SWGSkyMapTarget::SWGSkyMapTarget() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; hpbw = 0.0f; m_hpbw_isSet = false; date_time = nullptr; @@ -56,6 +58,8 @@ SWGSkyMapTarget::init() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; hpbw = 0.0f; m_hpbw_isSet = false; date_time = new QString(""); @@ -69,6 +73,7 @@ SWGSkyMapTarget::cleanup() { + if(date_time != nullptr) { delete date_time; } @@ -93,6 +98,8 @@ SWGSkyMapTarget::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&longitude, pJson["longitude"], "float", ""); + ::SWGSDRangel::setValue(&altitude, pJson["altitude"], "float", ""); + ::SWGSDRangel::setValue(&hpbw, pJson["hpbw"], "float", ""); ::SWGSDRangel::setValue(&date_time, pJson["dateTime"], "QString", "QString"); @@ -125,6 +132,9 @@ SWGSkyMapTarget::asJsonObject() { if(m_longitude_isSet){ obj->insert("longitude", QJsonValue(longitude)); } + if(m_altitude_isSet){ + obj->insert("altitude", QJsonValue(altitude)); + } if(m_hpbw_isSet){ obj->insert("hpbw", QJsonValue(hpbw)); } @@ -175,6 +185,16 @@ SWGSkyMapTarget::setLongitude(float longitude) { this->m_longitude_isSet = true; } +float +SWGSkyMapTarget::getAltitude() { + return altitude; +} +void +SWGSkyMapTarget::setAltitude(float altitude) { + this->altitude = altitude; + this->m_altitude_isSet = true; +} + float SWGSkyMapTarget::getHpbw() { return hpbw; @@ -212,6 +232,9 @@ SWGSkyMapTarget::isSet(){ if(m_longitude_isSet){ isObjectUpdated = true; break; } + if(m_altitude_isSet){ + isObjectUpdated = true; break; + } if(m_hpbw_isSet){ isObjectUpdated = true; break; } diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.h b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.h index 5a174127a..77acd8657 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.h +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget.h @@ -54,6 +54,9 @@ public: float getLongitude(); void setLongitude(float longitude); + float getAltitude(); + void setAltitude(float altitude); + float getHpbw(); void setHpbw(float hpbw); @@ -76,6 +79,9 @@ private: float longitude; bool m_longitude_isSet; + float altitude; + bool m_altitude_isSet; + float hpbw; bool m_hpbw_isSet; diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.cpp b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.cpp index b35b9e51b..0371c3cb8 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.cpp @@ -36,6 +36,8 @@ SWGSkyMapTarget_2::SWGSkyMapTarget_2() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; hpbw = 0.0f; m_hpbw_isSet = false; date_time = nullptr; @@ -56,6 +58,8 @@ SWGSkyMapTarget_2::init() { m_latitude_isSet = false; longitude = 0.0f; m_longitude_isSet = false; + altitude = 0.0f; + m_altitude_isSet = false; hpbw = 0.0f; m_hpbw_isSet = false; date_time = new QString(""); @@ -69,6 +73,7 @@ SWGSkyMapTarget_2::cleanup() { + if(date_time != nullptr) { delete date_time; } @@ -93,6 +98,8 @@ SWGSkyMapTarget_2::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&longitude, pJson["longitude"], "float", ""); + ::SWGSDRangel::setValue(&altitude, pJson["altitude"], "float", ""); + ::SWGSDRangel::setValue(&hpbw, pJson["hpbw"], "float", ""); ::SWGSDRangel::setValue(&date_time, pJson["dateTime"], "QString", "QString"); @@ -125,6 +132,9 @@ SWGSkyMapTarget_2::asJsonObject() { if(m_longitude_isSet){ obj->insert("longitude", QJsonValue(longitude)); } + if(m_altitude_isSet){ + obj->insert("altitude", QJsonValue(altitude)); + } if(m_hpbw_isSet){ obj->insert("hpbw", QJsonValue(hpbw)); } @@ -175,6 +185,16 @@ SWGSkyMapTarget_2::setLongitude(float longitude) { this->m_longitude_isSet = true; } +float +SWGSkyMapTarget_2::getAltitude() { + return altitude; +} +void +SWGSkyMapTarget_2::setAltitude(float altitude) { + this->altitude = altitude; + this->m_altitude_isSet = true; +} + float SWGSkyMapTarget_2::getHpbw() { return hpbw; @@ -212,6 +232,9 @@ SWGSkyMapTarget_2::isSet(){ if(m_longitude_isSet){ isObjectUpdated = true; break; } + if(m_altitude_isSet){ + isObjectUpdated = true; break; + } if(m_hpbw_isSet){ isObjectUpdated = true; break; } diff --git a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.h b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.h index e7aa0d15b..ce0b0ca93 100644 --- a/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.h +++ b/swagger/sdrangel/code/qt5/client/SWGSkyMapTarget_2.h @@ -54,6 +54,9 @@ public: float getLongitude(); void setLongitude(float longitude); + float getAltitude(); + void setAltitude(float altitude); + float getHpbw(); void setHpbw(float hpbw); @@ -76,6 +79,9 @@ private: float longitude; bool m_longitude_isSet; + float altitude; + bool m_altitude_isSet; + float hpbw; bool m_hpbw_isSet;