Swagger: generate with swagger-codegen 2.2.3 to fix bugs

This commit is contained in:
f4exb 2017-11-17 14:51:16 +01:00
parent eb566dbdea
commit 6fbaad50a0
52 changed files with 937 additions and 1387 deletions

View File

@ -11,6 +11,7 @@ SUBDIRS += sdrbase
SUBDIRS += sdrgui
SUBDIRS += httpserver
SUBDIRS += logging
SUBDIRS += swagger
CONFIG(MINGW64)SUBDIRS += nanomsg
SUBDIRS += fcdhid
SUBDIRS += fcdlib

View File

@ -0,0 +1 @@
2.2.3

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGAudioDevices::SWGAudioDevices(QString* json) {
init();
this->fromJson(*json);
@ -50,29 +37,31 @@ SWGAudioDevices::~SWGAudioDevices() {
void
SWGAudioDevices::init() {
nbInputDevices = NULL;
inputDevices = new QList<QString*>();
nbOutputDevices = NULL;
outputDevices = new QList<QString*>();
nb_input_devices = 0;
input_devices = new QList<QString*>();
nb_output_devices = 0;
output_devices = new QList<QString*>();
}
void
SWGAudioDevices::cleanup() {
if(inputDevices != NULL) {
QList<QString*>* arr = inputDevices;
if(input_devices != nullptr) {
QList<QString*>* arr = input_devices;
foreach(QString* o, *arr) {
delete o;
}
delete inputDevices;
delete input_devices;
}
if(outputDevices != NULL) {
QList<QString*>* arr = outputDevices;
if(output_devices != nullptr) {
QList<QString*>* arr = output_devices;
foreach(QString* o, *arr) {
delete o;
}
delete outputDevices;
delete output_devices;
}
}
@ -87,10 +76,14 @@ SWGAudioDevices::fromJson(QString &json) {
void
SWGAudioDevices::fromJsonObject(QJsonObject &pJson) {
setValue(&nbInputDevices, pJson["nbInputDevices"], "qint32", "");
setValue(&inputDevices, pJson["inputDevices"], "QList", "QString");
setValue(&nbOutputDevices, pJson["nbOutputDevices"], "qint32", "");
setValue(&outputDevices, pJson["outputDevices"], "QList", "QString");
::Swagger::setValue(&nb_input_devices, pJson["nbInputDevices"], "qint32", "");
::Swagger::setValue(&input_devices, pJson["inputDevices"], "QList", "QString");
::Swagger::setValue(&nb_output_devices, pJson["nbOutputDevices"], "qint32", "");
::Swagger::setValue(&output_devices, pJson["outputDevices"], "QList", "QString");
}
QString
@ -106,65 +99,58 @@ SWGAudioDevices::asJson ()
QJsonObject*
SWGAudioDevices::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("nbInputDevices", QJsonValue(nbInputDevices));
QList<QString*>* inputDevicesList = inputDevices;
QJsonArray inputDevicesJsonArray;
toJsonArray((QList<void*>*)inputDevices, &inputDevicesJsonArray, "inputDevices", "QString");
obj->insert("nbInputDevices", QJsonValue(nb_input_devices));
obj->insert("inputDevices", inputDevicesJsonArray);
obj->insert("nbOutputDevices", QJsonValue(nbOutputDevices));
QJsonArray input_devicesJsonArray;
toJsonArray((QList<void*>*)input_devices, &input_devicesJsonArray, "input_devices", "QString");
obj->insert("inputDevices", input_devicesJsonArray);
QList<QString*>* outputDevicesList = outputDevices;
QJsonArray outputDevicesJsonArray;
toJsonArray((QList<void*>*)outputDevices, &outputDevicesJsonArray, "outputDevices", "QString");
obj->insert("nbOutputDevices", QJsonValue(nb_output_devices));
obj->insert("outputDevices", outputDevicesJsonArray);
QJsonArray output_devicesJsonArray;
toJsonArray((QList<void*>*)output_devices, &output_devicesJsonArray, "output_devices", "QString");
obj->insert("outputDevices", output_devicesJsonArray);
return obj;
}
qint32
SWGAudioDevices::getNbInputDevices() {
return nbInputDevices;
return nb_input_devices;
}
void
SWGAudioDevices::setNbInputDevices(qint32 nbInputDevices) {
this->nbInputDevices = nbInputDevices;
SWGAudioDevices::setNbInputDevices(qint32 nb_input_devices) {
this->nb_input_devices = nb_input_devices;
}
QList<QString*>*
SWGAudioDevices::getInputDevices() {
return inputDevices;
return input_devices;
}
void
SWGAudioDevices::setInputDevices(QList<QString*>* inputDevices) {
this->inputDevices = inputDevices;
SWGAudioDevices::setInputDevices(QList<QString*>* input_devices) {
this->input_devices = input_devices;
}
qint32
SWGAudioDevices::getNbOutputDevices() {
return nbOutputDevices;
return nb_output_devices;
}
void
SWGAudioDevices::setNbOutputDevices(qint32 nbOutputDevices) {
this->nbOutputDevices = nbOutputDevices;
SWGAudioDevices::setNbOutputDevices(qint32 nb_output_devices) {
this->nb_output_devices = nb_output_devices;
}
QList<QString*>*
SWGAudioDevices::getOutputDevices() {
return outputDevices;
return output_devices;
}
void
SWGAudioDevices::setOutputDevices(QList<QString*>* outputDevices) {
this->outputDevices = outputDevices;
SWGAudioDevices::setOutputDevices(QList<QString*>* output_devices) {
this->output_devices = output_devices;
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,21 +44,25 @@ public:
SWGAudioDevices* fromJson(QString &jsonString);
qint32 getNbInputDevices();
void setNbInputDevices(qint32 nbInputDevices);
QList<QString*>* getInputDevices();
void setInputDevices(QList<QString*>* inputDevices);
qint32 getNbOutputDevices();
void setNbOutputDevices(qint32 nbOutputDevices);
QList<QString*>* getOutputDevices();
void setOutputDevices(QList<QString*>* outputDevices);
void setNbInputDevices(qint32 nb_input_devices);
QList<QString*>* getInputDevices();
void setInputDevices(QList<QString*>* input_devices);
qint32 getNbOutputDevices();
void setNbOutputDevices(qint32 nb_output_devices);
QList<QString*>* getOutputDevices();
void setOutputDevices(QList<QString*>* output_devices);
private:
qint32 nbInputDevices;
QList<QString*>* inputDevices;
qint32 nbOutputDevices;
QList<QString*>* outputDevices;
qint32 nb_input_devices;
QList<QString*>* input_devices;
qint32 nb_output_devices;
QList<QString*>* output_devices;
};
} /* namespace Swagger */
}
#endif /* SWGAudioDevices_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGAudioDevicesSelect::SWGAudioDevicesSelect(QString* json) {
init();
this->fromJson(*json);
@ -51,15 +38,17 @@ SWGAudioDevicesSelect::~SWGAudioDevicesSelect() {
void
SWGAudioDevicesSelect::init() {
input = new QString("");
output = new QString("");
output = new QString("");
}
void
SWGAudioDevicesSelect::cleanup() {
if(input != NULL) {
if(input != nullptr) {
delete input;
}
if(output != NULL) {
if(output != nullptr) {
delete output;
}
}
@ -75,8 +64,8 @@ SWGAudioDevicesSelect::fromJson(QString &json) {
void
SWGAudioDevicesSelect::fromJsonObject(QJsonObject &pJson) {
setValue(&input, pJson["input"], "QString", "QString");
setValue(&output, pJson["output"], "QString", "QString");
::Swagger::setValue(&input, pJson["input"], "QString", "QString");
::Swagger::setValue(&output, pJson["output"], "QString", "QString");
}
QString
@ -93,15 +82,9 @@ QJsonObject*
SWGAudioDevicesSelect::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("input"), input, obj, QString("QString"));
toJsonValue(QString("output"), output, obj, QString("QString"));
return obj;
}
@ -125,6 +108,5 @@ SWGAudioDevicesSelect::setOutput(QString* output) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,14 +44,16 @@ public:
QString* getInput();
void setInput(QString* input);
QString* getOutput();
QString* getOutput();
void setOutput(QString* output);
private:
QString* input;
QString* output;
QString* output;
};
} /* namespace Swagger */
}
#endif /* SWGAudioDevicesSelect_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGChannel::SWGChannel(QString* json) {
init();
this->fromJson(*json);
@ -50,15 +37,16 @@ SWGChannel::~SWGChannel() {
void
SWGChannel::init() {
index = NULL;
id = new QString("");
deltaFrequency = NULL;
index = 0;
id = new QString("");
delta_frequency = 0;
}
void
SWGChannel::cleanup() {
if(id != NULL) {
if(id != nullptr) {
delete id;
}
@ -75,9 +63,9 @@ SWGChannel::fromJson(QString &json) {
void
SWGChannel::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", "");
setValue(&id, pJson["id"], "QString", "QString");
setValue(&deltaFrequency, pJson["deltaFrequency"], "qint32", "");
::Swagger::setValue(&index, pJson["index"], "qint32", "");
::Swagger::setValue(&id, pJson["id"], "QString", "QString");
::Swagger::setValue(&delta_frequency, pJson["deltaFrequency"], "qint32", "");
}
QString
@ -93,13 +81,12 @@ SWGChannel::asJson ()
QJsonObject*
SWGChannel::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index));
toJsonValue(QString("id"), id, obj, QString("QString"));
obj->insert("deltaFrequency", QJsonValue(deltaFrequency));
obj->insert("deltaFrequency", QJsonValue(delta_frequency));
return obj;
}
@ -124,14 +111,13 @@ SWGChannel::setId(QString* id) {
qint32
SWGChannel::getDeltaFrequency() {
return deltaFrequency;
return delta_frequency;
}
void
SWGChannel::setDeltaFrequency(qint32 deltaFrequency) {
this->deltaFrequency = deltaFrequency;
SWGChannel::setDeltaFrequency(qint32 delta_frequency) {
this->delta_frequency = delta_frequency;
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,17 +44,20 @@ public:
qint32 getIndex();
void setIndex(qint32 index);
QString* getId();
QString* getId();
void setId(QString* id);
qint32 getDeltaFrequency();
void setDeltaFrequency(qint32 deltaFrequency);
qint32 getDeltaFrequency();
void setDeltaFrequency(qint32 delta_frequency);
private:
qint32 index;
QString* id;
qint32 deltaFrequency;
QString* id;
qint32 delta_frequency;
};
} /* namespace Swagger */
}
#endif /* SWGChannel_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGChannelListItem::SWGChannelListItem(QString* json) {
init();
this->fromJson(*json);
@ -51,21 +38,24 @@ SWGChannelListItem::~SWGChannelListItem() {
void
SWGChannelListItem::init() {
name = new QString("");
id = new QString("");
tx = false;
version = new QString("");
id = new QString("");
tx = false;
version = new QString("");
}
void
SWGChannelListItem::cleanup() {
if(name != NULL) {
if(name != nullptr) {
delete name;
}
if(id != NULL) {
if(id != nullptr) {
delete id;
}
if(version != NULL) {
if(version != nullptr) {
delete version;
}
}
@ -81,10 +71,10 @@ SWGChannelListItem::fromJson(QString &json) {
void
SWGChannelListItem::fromJsonObject(QJsonObject &pJson) {
setValue(&name, pJson["name"], "QString", "QString");
setValue(&id, pJson["id"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", "");
setValue(&version, pJson["version"], "QString", "QString");
::Swagger::setValue(&name, pJson["name"], "QString", "QString");
::Swagger::setValue(&id, pJson["id"], "QString", "QString");
::Swagger::setValue(&tx, pJson["tx"], "bool", "");
::Swagger::setValue(&version, pJson["version"], "QString", "QString");
}
QString
@ -101,21 +91,13 @@ QJsonObject*
SWGChannelListItem::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("name"), name, obj, QString("QString"));
toJsonValue(QString("id"), id, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("tx", QJsonValue(tx));
toJsonValue(QString("version"), version, obj, QString("QString"));
return obj;
}
@ -157,6 +139,5 @@ SWGChannelListItem::setVersion(QString* version) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,20 +44,24 @@ public:
QString* getName();
void setName(QString* name);
QString* getId();
QString* getId();
void setId(QString* id);
bool getTx();
bool getTx();
void setTx(bool tx);
QString* getVersion();
QString* getVersion();
void setVersion(QString* version);
private:
QString* name;
QString* id;
bool tx;
QString* version;
QString* id;
bool tx;
QString* version;
};
} /* namespace Swagger */
}
#endif /* SWGChannelListItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGDVSeralDevices::SWGDVSeralDevices(QString* json) {
init();
this->fromJson(*json);
@ -50,19 +37,20 @@ SWGDVSeralDevices::~SWGDVSeralDevices() {
void
SWGDVSeralDevices::init() {
nbDevices = NULL;
dvSerialDevices = new QList<QString*>();
nb_devices = 0;
dv_serial_devices = new QList<QString*>();
}
void
SWGDVSeralDevices::cleanup() {
if(dvSerialDevices != NULL) {
QList<QString*>* arr = dvSerialDevices;
if(dv_serial_devices != nullptr) {
QList<QString*>* arr = dv_serial_devices;
foreach(QString* o, *arr) {
delete o;
}
delete dvSerialDevices;
delete dv_serial_devices;
}
}
@ -77,8 +65,10 @@ SWGDVSeralDevices::fromJson(QString &json) {
void
SWGDVSeralDevices::fromJsonObject(QJsonObject &pJson) {
setValue(&nbDevices, pJson["nbDevices"], "qint32", "");
setValue(&dvSerialDevices, pJson["dvSerialDevices"], "QList", "QString");
::Swagger::setValue(&nb_devices, pJson["nbDevices"], "qint32", "");
::Swagger::setValue(&dv_serial_devices, pJson["dvSerialDevices"], "QList", "QString");
}
QString
@ -94,38 +84,34 @@ SWGDVSeralDevices::asJson ()
QJsonObject*
SWGDVSeralDevices::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("nbDevices", QJsonValue(nbDevices));
QList<QString*>* dvSerialDevicesList = dvSerialDevices;
QJsonArray dvSerialDevicesJsonArray;
toJsonArray((QList<void*>*)dvSerialDevices, &dvSerialDevicesJsonArray, "dvSerialDevices", "QString");
obj->insert("nbDevices", QJsonValue(nb_devices));
obj->insert("dvSerialDevices", dvSerialDevicesJsonArray);
QJsonArray dv_serial_devicesJsonArray;
toJsonArray((QList<void*>*)dv_serial_devices, &dv_serial_devicesJsonArray, "dv_serial_devices", "QString");
obj->insert("dvSerialDevices", dv_serial_devicesJsonArray);
return obj;
}
qint32
SWGDVSeralDevices::getNbDevices() {
return nbDevices;
return nb_devices;
}
void
SWGDVSeralDevices::setNbDevices(qint32 nbDevices) {
this->nbDevices = nbDevices;
SWGDVSeralDevices::setNbDevices(qint32 nb_devices) {
this->nb_devices = nb_devices;
}
QList<QString*>*
SWGDVSeralDevices::getDvSerialDevices() {
return dvSerialDevices;
return dv_serial_devices;
}
void
SWGDVSeralDevices::setDvSerialDevices(QList<QString*>* dvSerialDevices) {
this->dvSerialDevices = dvSerialDevices;
SWGDVSeralDevices::setDvSerialDevices(QList<QString*>* dv_serial_devices) {
this->dv_serial_devices = dv_serial_devices;
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,15 +44,17 @@ public:
SWGDVSeralDevices* fromJson(QString &jsonString);
qint32 getNbDevices();
void setNbDevices(qint32 nbDevices);
QList<QString*>* getDvSerialDevices();
void setDvSerialDevices(QList<QString*>* dvSerialDevices);
void setNbDevices(qint32 nb_devices);
QList<QString*>* getDvSerialDevices();
void setDvSerialDevices(QList<QString*>* dv_serial_devices);
private:
qint32 nbDevices;
QList<QString*>* dvSerialDevices;
qint32 nb_devices;
QList<QString*>* dv_serial_devices;
};
} /* namespace Swagger */
}
#endif /* SWGDVSeralDevices_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "SWGDefaultApi.h"
@ -30,6 +18,7 @@
#include <QJsonDocument>
namespace Swagger {
SWGDefaultApi::SWGDefaultApi() {}
SWGDefaultApi::~SWGDefaultApi() {}
@ -49,10 +38,14 @@ SWGDefaultApi::instanceAudioGet() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -64,6 +57,9 @@ SWGDefaultApi::instanceAudioGet() {
void
SWGDefaultApi::instanceAudioGetCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -71,16 +67,15 @@ SWGDefaultApi::instanceAudioGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGAudioDevices* output = static_cast<SWGAudioDevices*>(create(json, QString("SWGAudioDevices")));
QString json(worker->response);
SWGAudioDevices* output = static_cast<SWGAudioDevices*>(create(json, QString("SWGAudioDevices")));
worker->deleteLater();
emit instanceAudioGetSignal(output);
emit instanceAudioGetSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
QString fullPath;
@ -91,12 +86,16 @@ SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -108,6 +107,9 @@ SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
void
SWGDefaultApi::instanceAudioPatchCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -115,16 +117,15 @@ SWGDefaultApi::instanceAudioPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGAudioDevicesSelect* output = static_cast<SWGAudioDevicesSelect*>(create(json, QString("SWGAudioDevicesSelect")));
QString json(worker->response);
SWGAudioDevicesSelect* output = static_cast<SWGAudioDevicesSelect*>(create(json, QString("SWGAudioDevicesSelect")));
worker->deleteLater();
emit instanceAudioPatchSignal(output);
emit instanceAudioPatchSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceChannels(bool tx) {
QString fullPath;
@ -143,10 +144,14 @@ SWGDefaultApi::instanceChannels(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -158,6 +163,9 @@ SWGDefaultApi::instanceChannels(bool tx) {
void
SWGDefaultApi::instanceChannelsCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -165,16 +173,15 @@ SWGDefaultApi::instanceChannelsCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGInstanceChannelsResponse* output = static_cast<SWGInstanceChannelsResponse*>(create(json, QString("SWGInstanceChannelsResponse")));
QString json(worker->response);
SWGInstanceChannelsResponse* output = static_cast<SWGInstanceChannelsResponse*>(create(json, QString("SWGInstanceChannelsResponse")));
worker->deleteLater();
emit instanceChannelsSignal(output);
emit instanceChannelsSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
QString fullPath;
@ -193,10 +200,14 @@ SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -208,6 +219,9 @@ SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
void
SWGDefaultApi::instanceDVSerialPatchCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -215,16 +229,15 @@ SWGDefaultApi::instanceDVSerialPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGDVSeralDevices* output = static_cast<SWGDVSeralDevices*>(create(json, QString("SWGDVSeralDevices")));
QString json(worker->response);
SWGDVSeralDevices* output = static_cast<SWGDVSeralDevices*>(create(json, QString("SWGDVSeralDevices")));
worker->deleteLater();
emit instanceDVSerialPatchSignal(output);
emit instanceDVSerialPatchSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceDeviceSetsDelete() {
QString fullPath;
@ -235,10 +248,14 @@ SWGDefaultApi::instanceDeviceSetsDelete() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "DELETE");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -250,6 +267,9 @@ SWGDefaultApi::instanceDeviceSetsDelete() {
void
SWGDefaultApi::instanceDeviceSetsDeleteCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -257,16 +277,15 @@ SWGDefaultApi::instanceDeviceSetsDeleteCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGDeviceSetList* output = static_cast<SWGDeviceSetList*>(create(json, QString("SWGDeviceSetList")));
QString json(worker->response);
SWGDeviceSetList* output = static_cast<SWGDeviceSetList*>(create(json, QString("SWGDeviceSetList")));
worker->deleteLater();
emit instanceDeviceSetsDeleteSignal(output);
emit instanceDeviceSetsDeleteSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceDeviceSetsGet() {
QString fullPath;
@ -277,10 +296,14 @@ SWGDefaultApi::instanceDeviceSetsGet() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -292,6 +315,9 @@ SWGDefaultApi::instanceDeviceSetsGet() {
void
SWGDefaultApi::instanceDeviceSetsGetCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -299,16 +325,15 @@ SWGDefaultApi::instanceDeviceSetsGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGDeviceSetList* output = static_cast<SWGDeviceSetList*>(create(json, QString("SWGDeviceSetList")));
QString json(worker->response);
SWGDeviceSetList* output = static_cast<SWGDeviceSetList*>(create(json, QString("SWGDeviceSetList")));
worker->deleteLater();
emit instanceDeviceSetsGetSignal(output);
emit instanceDeviceSetsGetSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
QString fullPath;
@ -327,10 +352,14 @@ SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "POST");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -342,6 +371,9 @@ SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
void
SWGDefaultApi::instanceDeviceSetsPostCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -349,16 +381,15 @@ SWGDefaultApi::instanceDeviceSetsPostCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGDeviceSet* output = static_cast<SWGDeviceSet*>(create(json, QString("SWGDeviceSet")));
QString json(worker->response);
SWGDeviceSet* output = static_cast<SWGDeviceSet*>(create(json, QString("SWGDeviceSet")));
worker->deleteLater();
emit instanceDeviceSetsPostSignal(output);
emit instanceDeviceSetsPostSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceDevices(bool tx) {
QString fullPath;
@ -377,10 +408,14 @@ SWGDefaultApi::instanceDevices(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -392,6 +427,9 @@ SWGDefaultApi::instanceDevices(bool tx) {
void
SWGDefaultApi::instanceDevicesCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -399,16 +437,15 @@ SWGDefaultApi::instanceDevicesCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGInstanceDevicesResponse* output = static_cast<SWGInstanceDevicesResponse*>(create(json, QString("SWGInstanceDevicesResponse")));
QString json(worker->response);
SWGInstanceDevicesResponse* output = static_cast<SWGInstanceDevicesResponse*>(create(json, QString("SWGInstanceDevicesResponse")));
worker->deleteLater();
emit instanceDevicesSignal(output);
emit instanceDevicesSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceLocationGet() {
QString fullPath;
@ -419,10 +456,14 @@ SWGDefaultApi::instanceLocationGet() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -434,6 +475,9 @@ SWGDefaultApi::instanceLocationGet() {
void
SWGDefaultApi::instanceLocationGetCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -441,16 +485,15 @@ SWGDefaultApi::instanceLocationGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGLocationInformation* output = static_cast<SWGLocationInformation*>(create(json, QString("SWGLocationInformation")));
QString json(worker->response);
SWGLocationInformation* output = static_cast<SWGLocationInformation*>(create(json, QString("SWGLocationInformation")));
worker->deleteLater();
emit instanceLocationGetSignal(output);
emit instanceLocationGetSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
QString fullPath;
@ -461,12 +504,16 @@ SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -478,6 +525,9 @@ SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
void
SWGDefaultApi::instanceLocationPutCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -485,16 +535,15 @@ SWGDefaultApi::instanceLocationPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGLocationInformation* output = static_cast<SWGLocationInformation*>(create(json, QString("SWGLocationInformation")));
QString json(worker->response);
SWGLocationInformation* output = static_cast<SWGLocationInformation*>(create(json, QString("SWGLocationInformation")));
worker->deleteLater();
emit instanceLocationPutSignal(output);
emit instanceLocationPutSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceLoggingGet() {
QString fullPath;
@ -505,10 +554,14 @@ SWGDefaultApi::instanceLoggingGet() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -520,6 +573,9 @@ SWGDefaultApi::instanceLoggingGet() {
void
SWGDefaultApi::instanceLoggingGetCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -527,16 +583,15 @@ SWGDefaultApi::instanceLoggingGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGLoggingInfo* output = static_cast<SWGLoggingInfo*>(create(json, QString("SWGLoggingInfo")));
QString json(worker->response);
SWGLoggingInfo* output = static_cast<SWGLoggingInfo*>(create(json, QString("SWGLoggingInfo")));
worker->deleteLater();
emit instanceLoggingGetSignal(output);
emit instanceLoggingGetSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
QString fullPath;
@ -547,12 +602,16 @@ SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -564,6 +623,9 @@ SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
void
SWGDefaultApi::instanceLoggingPutCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -571,16 +633,15 @@ SWGDefaultApi::instanceLoggingPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGLoggingInfo* output = static_cast<SWGLoggingInfo*>(create(json, QString("SWGLoggingInfo")));
QString json(worker->response);
SWGLoggingInfo* output = static_cast<SWGLoggingInfo*>(create(json, QString("SWGLoggingInfo")));
worker->deleteLater();
emit instanceLoggingPutSignal(output);
emit instanceLoggingPutSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
QString fullPath;
@ -591,12 +652,16 @@ SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "DELETE");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -608,6 +673,9 @@ SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
void
SWGDefaultApi::instancePresetDeleteCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -615,16 +683,15 @@ SWGDefaultApi::instancePresetDeleteCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
worker->deleteLater();
emit instancePresetDeleteSignal(output);
emit instancePresetDeleteSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instancePresetGet() {
QString fullPath;
@ -635,10 +702,14 @@ SWGDefaultApi::instancePresetGet() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -650,6 +721,9 @@ SWGDefaultApi::instancePresetGet() {
void
SWGDefaultApi::instancePresetGetCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -657,16 +731,15 @@ SWGDefaultApi::instancePresetGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGPresets* output = static_cast<SWGPresets*>(create(json, QString("SWGPresets")));
QString json(worker->response);
SWGPresets* output = static_cast<SWGPresets*>(create(json, QString("SWGPresets")));
worker->deleteLater();
emit instancePresetGetSignal(output);
emit instancePresetGetSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
QString fullPath;
@ -677,12 +750,16 @@ SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -694,6 +771,9 @@ SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
void
SWGDefaultApi::instancePresetPatchCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -701,16 +781,15 @@ SWGDefaultApi::instancePresetPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
worker->deleteLater();
emit instancePresetPatchSignal(output);
emit instancePresetPatchSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
QString fullPath;
@ -721,12 +800,16 @@ SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "POST");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -738,6 +821,9 @@ SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
void
SWGDefaultApi::instancePresetPostCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -745,16 +831,15 @@ SWGDefaultApi::instancePresetPostCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
worker->deleteLater();
emit instancePresetPostSignal(output);
emit instancePresetPostSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
QString fullPath;
@ -765,12 +850,16 @@ SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson();
input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -782,6 +871,9 @@ SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
void
SWGDefaultApi::instancePresetPutCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -789,16 +881,15 @@ SWGDefaultApi::instancePresetPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
QString json(worker->response);
SWGPresetIdentifier* output = static_cast<SWGPresetIdentifier*>(create(json, QString("SWGPresetIdentifier")));
worker->deleteLater();
emit instancePresetPutSignal(output);
emit instancePresetPutSignalE(output, error_type, error_str);
}
void
SWGDefaultApi::instanceSummary() {
QString fullPath;
@ -809,10 +900,14 @@ SWGDefaultApi::instanceSummary() {
HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker,
&HttpRequestWorker::on_execution_finished,
this,
@ -824,6 +919,9 @@ SWGDefaultApi::instanceSummary() {
void
SWGDefaultApi::instanceSummaryCallback(HttpRequestWorker * worker) {
QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length());
}
@ -831,14 +929,14 @@ SWGDefaultApi::instanceSummaryCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str;
}
QString json(worker->response);
SWGInstanceSummaryResponse* output = static_cast<SWGInstanceSummaryResponse*>(create(json, QString("SWGInstanceSummaryResponse")));
QString json(worker->response);
SWGInstanceSummaryResponse* output = static_cast<SWGInstanceSummaryResponse*>(create(json, QString("SWGInstanceSummaryResponse")));
worker->deleteLater();
emit instanceSummarySignal(output);
emit instanceSummarySignalE(output, error_type, error_str);
}
}
} /* namespace Swagger */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef _SWG_SWGDefaultApi_H_
@ -27,20 +15,20 @@
#include "SWGHttpRequest.h"
#include "SWGErrorResponse.h"
#include "SWGAudioDevices.h"
#include "SWGAudioDevicesSelect.h"
#include "SWGInstanceChannelsResponse.h"
#include "SWGDVSeralDevices.h"
#include "SWGDeviceSetList.h"
#include "SWGDeviceSet.h"
#include "SWGDeviceSetList.h"
#include "SWGErrorResponse.h"
#include "SWGInstanceChannelsResponse.h"
#include "SWGInstanceDevicesResponse.h"
#include "SWGInstanceSummaryResponse.h"
#include "SWGLocationInformation.h"
#include "SWGLoggingInfo.h"
#include "SWGPresetIdentifier.h"
#include "SWGPresets.h"
#include "SWGPresetTransfer.h"
#include "SWGInstanceSummaryResponse.h"
#include "SWGPresets.h"
#include <QObject>
@ -56,6 +44,7 @@ public:
QString host;
QString basePath;
QMap<QString, QString> defaultHeaders;
void instanceAudioGet();
void instanceAudioPatch(SWGAudioDevicesSelect body);
@ -116,6 +105,26 @@ signals:
void instancePresetPutSignal(SWGPresetIdentifier* summary);
void instanceSummarySignal(SWGInstanceSummaryResponse* summary);
void instanceAudioGetSignalE(SWGAudioDevices* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceAudioPatchSignalE(SWGAudioDevicesSelect* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceChannelsSignalE(SWGInstanceChannelsResponse* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceDVSerialPatchSignalE(SWGDVSeralDevices* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceDeviceSetsDeleteSignalE(SWGDeviceSetList* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceDeviceSetsGetSignalE(SWGDeviceSetList* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceDeviceSetsPostSignalE(SWGDeviceSet* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceDevicesSignalE(SWGInstanceDevicesResponse* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceLocationGetSignalE(SWGLocationInformation* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceLocationPutSignalE(SWGLocationInformation* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceLoggingGetSignalE(SWGLoggingInfo* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceLoggingPutSignalE(SWGLoggingInfo* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instancePresetDeleteSignalE(SWGPresetIdentifier* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instancePresetGetSignalE(SWGPresets* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instancePresetPatchSignalE(SWGPresetIdentifier* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instancePresetPostSignalE(SWGPresetIdentifier* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instancePresetPutSignalE(SWGPresetIdentifier* summary, QNetworkReply::NetworkError error_type, QString& error_str);
void instanceSummarySignalE(SWGInstanceSummaryResponse* summary, QNetworkReply::NetworkError error_type, QString& error_str);
};
}
#endif

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGDeviceListItem::SWGDeviceListItem(QString* json) {
init();
this->fromJson(*json);
@ -50,24 +37,26 @@ SWGDeviceListItem::~SWGDeviceListItem() {
void
SWGDeviceListItem::init() {
hwType = new QString("");
tx = false;
nbStreams = NULL;
streamIndex = NULL;
sequence = NULL;
serial = new QString("");
hw_type = new QString("");
tx = false;
nb_streams = 0;
stream_index = 0;
sequence = 0;
serial = new QString("");
}
void
SWGDeviceListItem::cleanup() {
if(hwType != NULL) {
delete hwType;
if(hw_type != nullptr) {
delete hw_type;
}
if(serial != NULL) {
if(serial != nullptr) {
delete serial;
}
}
@ -83,12 +72,12 @@ SWGDeviceListItem::fromJson(QString &json) {
void
SWGDeviceListItem::fromJsonObject(QJsonObject &pJson) {
setValue(&hwType, pJson["hwType"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", "");
setValue(&nbStreams, pJson["nbStreams"], "qint32", "");
setValue(&streamIndex, pJson["streamIndex"], "qint32", "");
setValue(&sequence, pJson["sequence"], "qint32", "");
setValue(&serial, pJson["serial"], "QString", "QString");
::Swagger::setValue(&hw_type, pJson["hwType"], "QString", "QString");
::Swagger::setValue(&tx, pJson["tx"], "bool", "");
::Swagger::setValue(&nb_streams, pJson["nbStreams"], "qint32", "");
::Swagger::setValue(&stream_index, pJson["streamIndex"], "qint32", "");
::Swagger::setValue(&sequence, pJson["sequence"], "qint32", "");
::Swagger::setValue(&serial, pJson["serial"], "QString", "QString");
}
QString
@ -105,30 +94,28 @@ QJsonObject*
SWGDeviceListItem::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("hwType"), hwType, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("nbStreams", QJsonValue(nbStreams));
obj->insert("streamIndex", QJsonValue(streamIndex));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("hwType"), hw_type, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("nbStreams", QJsonValue(nb_streams));
obj->insert("streamIndex", QJsonValue(stream_index));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("serial"), serial, obj, QString("QString"));
return obj;
}
QString*
SWGDeviceListItem::getHwType() {
return hwType;
return hw_type;
}
void
SWGDeviceListItem::setHwType(QString* hwType) {
this->hwType = hwType;
SWGDeviceListItem::setHwType(QString* hw_type) {
this->hw_type = hw_type;
}
bool
@ -142,20 +129,20 @@ SWGDeviceListItem::setTx(bool tx) {
qint32
SWGDeviceListItem::getNbStreams() {
return nbStreams;
return nb_streams;
}
void
SWGDeviceListItem::setNbStreams(qint32 nbStreams) {
this->nbStreams = nbStreams;
SWGDeviceListItem::setNbStreams(qint32 nb_streams) {
this->nb_streams = nb_streams;
}
qint32
SWGDeviceListItem::getStreamIndex() {
return streamIndex;
return stream_index;
}
void
SWGDeviceListItem::setStreamIndex(qint32 streamIndex) {
this->streamIndex = streamIndex;
SWGDeviceListItem::setStreamIndex(qint32 stream_index) {
this->stream_index = stream_index;
}
qint32
@ -177,6 +164,5 @@ SWGDeviceListItem::setSerial(QString* serial) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,27 +43,33 @@ public:
SWGDeviceListItem* fromJson(QString &jsonString);
QString* getHwType();
void setHwType(QString* hwType);
bool getTx();
void setHwType(QString* hw_type);
bool getTx();
void setTx(bool tx);
qint32 getNbStreams();
void setNbStreams(qint32 nbStreams);
qint32 getStreamIndex();
void setStreamIndex(qint32 streamIndex);
qint32 getSequence();
qint32 getNbStreams();
void setNbStreams(qint32 nb_streams);
qint32 getStreamIndex();
void setStreamIndex(qint32 stream_index);
qint32 getSequence();
void setSequence(qint32 sequence);
QString* getSerial();
QString* getSerial();
void setSerial(QString* serial);
private:
QString* hwType;
bool tx;
qint32 nbStreams;
qint32 streamIndex;
qint32 sequence;
QString* serial;
QString* hw_type;
bool tx;
qint32 nb_streams;
qint32 stream_index;
qint32 sequence;
QString* serial;
};
} /* namespace Swagger */
}
#endif /* SWGDeviceListItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGDeviceSet::SWGDeviceSet(QString* json) {
init();
this->fromJson(*json);
@ -50,18 +37,20 @@ SWGDeviceSet::~SWGDeviceSet() {
void
SWGDeviceSet::init() {
samplingDevice = new SWGSamplingDevice();
channelcount = NULL;
channels = new QList<SWGChannel*>();
sampling_device = new SWGSamplingDevice();
channelcount = 0;
channels = new QList<SWGChannel*>();
}
void
SWGDeviceSet::cleanup() {
if(samplingDevice != NULL) {
delete samplingDevice;
if(sampling_device != nullptr) {
delete sampling_device;
}
if(channels != NULL) {
if(channels != nullptr) {
QList<SWGChannel*>* arr = channels;
foreach(SWGChannel* o, *arr) {
delete o;
@ -81,9 +70,11 @@ SWGDeviceSet::fromJson(QString &json) {
void
SWGDeviceSet::fromJsonObject(QJsonObject &pJson) {
setValue(&samplingDevice, pJson["samplingDevice"], "SWGSamplingDevice", "SWGSamplingDevice");
setValue(&channelcount, pJson["channelcount"], "qint32", "");
setValue(&channels, pJson["channels"], "QList", "SWGChannel");
::Swagger::setValue(&sampling_device, pJson["samplingDevice"], "SWGSamplingDevice", "SWGSamplingDevice");
::Swagger::setValue(&channelcount, pJson["channelcount"], "qint32", "");
::Swagger::setValue(&channels, pJson["channels"], "QList", "SWGChannel");
}
QString
@ -100,30 +91,24 @@ QJsonObject*
SWGDeviceSet::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("samplingDevice"), samplingDevice, obj, QString("SWGSamplingDevice"));
obj->insert("channelcount", QJsonValue(channelcount));
toJsonValue(QString("samplingDevice"), sampling_device, obj, QString("SWGSamplingDevice"));
obj->insert("channelcount", QJsonValue(channelcount));
QList<SWGChannel*>* channelsList = channels;
QJsonArray channelsJsonArray;
toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannel");
obj->insert("channels", channelsJsonArray);
return obj;
}
SWGSamplingDevice*
SWGDeviceSet::getSamplingDevice() {
return samplingDevice;
return sampling_device;
}
void
SWGDeviceSet::setSamplingDevice(SWGSamplingDevice* samplingDevice) {
this->samplingDevice = samplingDevice;
SWGDeviceSet::setSamplingDevice(SWGSamplingDevice* sampling_device) {
this->sampling_device = sampling_device;
}
qint32
@ -145,6 +130,5 @@ SWGDeviceSet::setChannels(QList<SWGChannel*>* channels) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,18 +45,21 @@ public:
SWGDeviceSet* fromJson(QString &jsonString);
SWGSamplingDevice* getSamplingDevice();
void setSamplingDevice(SWGSamplingDevice* samplingDevice);
qint32 getChannelcount();
void setSamplingDevice(SWGSamplingDevice* sampling_device);
qint32 getChannelcount();
void setChannelcount(qint32 channelcount);
QList<SWGChannel*>* getChannels();
QList<SWGChannel*>* getChannels();
void setChannels(QList<SWGChannel*>* channels);
private:
SWGSamplingDevice* samplingDevice;
qint32 channelcount;
QList<SWGChannel*>* channels;
SWGSamplingDevice* sampling_device;
qint32 channelcount;
QList<SWGChannel*>* channels;
};
} /* namespace Swagger */
}
#endif /* SWGDeviceSet_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGDeviceSetList::SWGDeviceSetList(QString* json) {
init();
this->fromJson(*json);
@ -50,19 +37,20 @@ SWGDeviceSetList::~SWGDeviceSetList() {
void
SWGDeviceSetList::init() {
devicesetcount = NULL;
deviceSets = new QList<SWGDeviceSet*>();
devicesetcount = 0;
device_sets = new QList<SWGDeviceSet*>();
}
void
SWGDeviceSetList::cleanup() {
if(deviceSets != NULL) {
QList<SWGDeviceSet*>* arr = deviceSets;
if(device_sets != nullptr) {
QList<SWGDeviceSet*>* arr = device_sets;
foreach(SWGDeviceSet* o, *arr) {
delete o;
}
delete deviceSets;
delete device_sets;
}
}
@ -77,8 +65,10 @@ SWGDeviceSetList::fromJson(QString &json) {
void
SWGDeviceSetList::fromJsonObject(QJsonObject &pJson) {
setValue(&devicesetcount, pJson["devicesetcount"], "qint32", "");
setValue(&deviceSets, pJson["deviceSets"], "QList", "SWGDeviceSet");
::Swagger::setValue(&devicesetcount, pJson["devicesetcount"], "qint32", "");
::Swagger::setValue(&device_sets, pJson["deviceSets"], "QList", "SWGDeviceSet");
}
QString
@ -94,15 +84,12 @@ SWGDeviceSetList::asJson ()
QJsonObject*
SWGDeviceSetList::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("devicesetcount", QJsonValue(devicesetcount));
QList<SWGDeviceSet*>* deviceSetsList = deviceSets;
QJsonArray deviceSetsJsonArray;
toJsonArray((QList<void*>*)deviceSets, &deviceSetsJsonArray, "deviceSets", "SWGDeviceSet");
obj->insert("deviceSets", deviceSetsJsonArray);
QJsonArray device_setsJsonArray;
toJsonArray((QList<void*>*)device_sets, &device_setsJsonArray, "device_sets", "SWGDeviceSet");
obj->insert("deviceSets", device_setsJsonArray);
return obj;
}
@ -118,14 +105,13 @@ SWGDeviceSetList::setDevicesetcount(qint32 devicesetcount) {
QList<SWGDeviceSet*>*
SWGDeviceSetList::getDeviceSets() {
return deviceSets;
return device_sets;
}
void
SWGDeviceSetList::setDeviceSets(QList<SWGDeviceSet*>* deviceSets) {
this->deviceSets = deviceSets;
SWGDeviceSetList::setDeviceSets(QList<SWGDeviceSet*>* device_sets) {
this->device_sets = device_sets;
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,14 +45,16 @@ public:
qint32 getDevicesetcount();
void setDevicesetcount(qint32 devicesetcount);
QList<SWGDeviceSet*>* getDeviceSets();
void setDeviceSets(QList<SWGDeviceSet*>* deviceSets);
QList<SWGDeviceSet*>* getDeviceSets();
void setDeviceSets(QList<SWGDeviceSet*>* device_sets);
private:
qint32 devicesetcount;
QList<SWGDeviceSet*>* deviceSets;
QList<SWGDeviceSet*>* device_sets;
};
} /* namespace Swagger */
}
#endif /* SWGDeviceSetList_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGErrorResponse::SWGErrorResponse(QString* json) {
init();
this->fromJson(*json);
@ -55,7 +42,8 @@ SWGErrorResponse::init() {
void
SWGErrorResponse::cleanup() {
if(message != NULL) {
if(message != nullptr) {
delete message;
}
}
@ -71,7 +59,7 @@ SWGErrorResponse::fromJson(QString &json) {
void
SWGErrorResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&message, pJson["message"], "QString", "QString");
::Swagger::setValue(&message, pJson["message"], "QString", "QString");
}
QString
@ -88,10 +76,7 @@ QJsonObject*
SWGErrorResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("message"), message, obj, QString("QString"));
return obj;
}
@ -106,6 +91,5 @@ SWGErrorResponse::setMessage(QString* message) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,10 +45,11 @@ public:
QString* getMessage();
void setMessage(QString* message);
private:
QString* message;
};
} /* namespace Swagger */
}
#endif /* SWGErrorResponse_H_ */

View File

@ -1,4 +1,3 @@
#include <QDateTime>
/**
* SDRangel
* This is the web API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube
@ -9,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "SWGHelpers.h"
@ -29,12 +16,14 @@
#include <QDebug>
#include <QJsonArray>
#include <QJsonValue>
#include <QDateTime>
namespace Swagger {
void
setValue(void* value, QJsonValue obj, QString type, QString complexType) {
if(value == NULL) {
if(value == nullptr) {
// can't set value with a null pointer
return;
}
@ -61,7 +50,7 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
else if (QStringLiteral("QString").compare(type) == 0) {
QString **val = static_cast<QString**>(value);
if(val != NULL) {
if(val != nullptr) {
if(!obj.isNull()) {
// create a new value and return
delete *val;
@ -69,19 +58,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return;
}
else {
// set target to NULL
// set target to nullptr
delete *val;
*val = NULL;
*val = nullptr;
}
}
else {
qDebug() << "Can't set value because the target pointer is NULL";
qDebug() << "Can't set value because the target pointer is nullptr";
}
}
else if (QStringLiteral("QDateTime").compare(type) == 0) {
QDateTime **val = static_cast<QDateTime**>(value);
if(val != NULL) {
if(val != nullptr) {
if(!obj.isNull()) {
// create a new value and return
delete *val;
@ -89,19 +78,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return;
}
else {
// set target to NULL
// set target to nullptr
delete *val;
*val = NULL;
*val = nullptr;
}
}
else {
qDebug() << "Can't set value because the target pointer is NULL";
qDebug() << "Can't set value because the target pointer is nullptr";
}
}
else if (QStringLiteral("QDate").compare(type) == 0) {
QDate **val = static_cast<QDate**>(value);
if(val != NULL) {
if(val != nullptr) {
if(!obj.isNull()) {
// create a new value and return
delete *val;
@ -109,19 +98,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return;
}
else {
// set target to NULL
// set target to nullptr
delete *val;
*val = NULL;
*val = nullptr;
}
}
else {
qDebug() << "Can't set value because the target pointer is NULL";
qDebug() << "Can't set value because the target pointer is nullptr";
}
}
else if (QStringLiteral("QByteArray").compare(type) == 0) {
QByteArray **val = static_cast<QByteArray**>(value);
if(val != NULL) {
if(val != nullptr) {
if(!obj.isNull()) {
// create a new value and return
delete *val;
@ -130,20 +119,20 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return;
}
else {
// set target to NULL
// set target to nullptr
delete *val;
*val = NULL;
*val = nullptr;
}
}
else {
qDebug() << "Can't set value because the target pointer is NULL";
qDebug() << "Can't set value because the target pointer is nullptr";
}
}
else if(type.startsWith("SWG") && obj.isObject()) {
// complex type
QJsonObject jsonObj = obj.toObject();
SWGObject * so = (SWGObject*)Swagger::create(type);
if(so != NULL) {
SWGObject * so = (SWGObject*)::Swagger::create(type);
if(so != nullptr) {
so->fromJsonObject(jsonObj);
SWGObject **val = static_cast<SWGObject**>(value);
delete *val;
@ -191,19 +180,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
output->append((void*)&val);
}
else if(QStringLiteral("QString").compare(complexType) == 0) {
QString val;
QString * val = new QString();
setValue(&val, jval, QStringLiteral("QString"), QStringLiteral(""));
output->append((void*)&val);
output->append((void*)val);
}
else if(QStringLiteral("QDate").compare(complexType) == 0) {
QDate val;
QDate * val = new QDate();
setValue(&val, jval, QStringLiteral("QDate"), QStringLiteral(""));
output->append((void*)&val);
output->append((void*)val);
}
else if(QStringLiteral("QDateTime").compare(complexType) == 0) {
QDateTime val;
QDateTime * val = new QDateTime();
setValue(&val, jval, QStringLiteral("QDateTime"), QStringLiteral(""));
output->append((void*)&val);
output->append((void*)val);
}
}
}
@ -215,14 +204,14 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
void
toJsonValue(QString name, void* value, QJsonObject* output, QString type) {
if(value == NULL) {
if(value == nullptr) {
return;
}
if(type.startsWith("SWG")) {
SWGObject *swgObject = reinterpret_cast<SWGObject *>(value);
if(swgObject != NULL) {
if(swgObject != nullptr) {
QJsonObject* o = (*swgObject).asJsonObject();
if(name != NULL) {
if(name != nullptr) {
output->insert(name, *o);
delete o;
}
@ -277,7 +266,7 @@ toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString
foreach(void* obj, *value) {
QJsonObject element;
toJsonValue(NULL, obj, &element, innerType);
toJsonValue(nullptr, obj, &element, innerType);
output->append(element);
}
}
@ -302,4 +291,5 @@ QString
stringValue(bool value) {
return QString(value ? "true" : "false");
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef SWGHELPERS_H
@ -28,6 +16,7 @@
#include <QJsonValue>
namespace Swagger {
void setValue(void* value, QJsonValue obj, QString type, QString complexType);
void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType);
void toJsonValue(QString name, void* value, QJsonObject* output, QString type);
@ -36,6 +25,7 @@ namespace Swagger {
QString stringValue(qint32 value);
QString stringValue(qint64 value);
QString stringValue(bool value);
}
#endif // SWGHELPERS_H

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include "SWGHttpRequest.h"
@ -27,8 +15,11 @@
#include <QUrl>
#include <QFileInfo>
#include <QBuffer>
#include <QtGlobal>
namespace Swagger {
HttpRequestInput::HttpRequestInput() {
initialize();
}
@ -60,7 +51,7 @@ void HttpRequestInput::add_file(QString variable_name, QString local_filename, Q
HttpRequestWorker::HttpRequestWorker(QObject *parent)
: QObject(parent), manager(NULL)
: QObject(parent), manager(nullptr)
{
qsrand(QDateTime::currentDateTime().toTime_t());
@ -204,8 +195,8 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
// ensure necessary variables are available
if (
file_info->local_filename == NULL || file_info->local_filename.isEmpty()
|| file_info->variable_name == NULL || file_info->variable_name.isEmpty()
file_info->local_filename == nullptr || file_info->local_filename.isEmpty()
|| file_info->variable_name == nullptr || file_info->variable_name.isEmpty()
|| !fi.exists() || !fi.isFile() || !fi.isReadable()
) {
// silent abort for the current file
@ -219,7 +210,7 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
}
// ensure filename for the request
if (file_info->request_filename == NULL || file_info->request_filename.isEmpty()) {
if (file_info->request_filename == nullptr || file_info->request_filename.isEmpty()) {
file_info->request_filename = fi.fileName();
if (file_info->request_filename.isEmpty()) {
file_info->request_filename = "file";
@ -238,7 +229,7 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
));
request_content.append(new_line);
if (file_info->mime_type != NULL && !file_info->mime_type.isEmpty()) {
if (file_info->mime_type != nullptr && !file_info->mime_type.isEmpty()) {
request_content.append("Content-Type: ");
request_content.append(file_info->mime_type);
request_content.append(new_line);
@ -302,8 +293,16 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
manager->deleteResource(request);
}
else {
QBuffer buff(&request_content);
manager->sendCustomRequest(request, input->http_method.toLatin1(), &buff);
#if (QT_VERSION >= 0x050800)
manager->sendCustomRequest(request, input->http_method.toLatin1(), request_content);
#else
QBuffer *buffer = new QBuffer;
buffer->setData(request_content);
buffer->open(QIODevice::ReadOnly);
QNetworkReply* reply = manager->sendCustomRequest(request, input->http_method.toLatin1(), buffer);
buffer->setParent(reply);
#endif
}
}
@ -321,3 +320,5 @@ void HttpRequestWorker::on_manager_finished(QNetworkReply *reply) {
emit on_execution_finished(this);
}
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
@ -39,6 +27,7 @@
enum HttpRequestVarLayout {NOT_SET, ADDRESS, URL_ENCODED, MULTIPART};
namespace Swagger {
class SWGHttpRequestInputFileElement {
@ -96,4 +85,6 @@ private slots:
};
}
#endif // HTTPREQUESTWORKER_H

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGInstanceChannelsResponse::SWGInstanceChannelsResponse(QString* json) {
init();
this->fromJson(*json);
@ -50,14 +37,15 @@ SWGInstanceChannelsResponse::~SWGInstanceChannelsResponse() {
void
SWGInstanceChannelsResponse::init() {
channelcount = NULL;
channels = new QList<SWGChannelListItem*>();
channelcount = 0;
channels = new QList<SWGChannelListItem*>();
}
void
SWGInstanceChannelsResponse::cleanup() {
if(channels != NULL) {
if(channels != nullptr) {
QList<SWGChannelListItem*>* arr = channels;
foreach(SWGChannelListItem* o, *arr) {
delete o;
@ -77,8 +65,10 @@ SWGInstanceChannelsResponse::fromJson(QString &json) {
void
SWGInstanceChannelsResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&channelcount, pJson["channelcount"], "qint32", "");
setValue(&channels, pJson["channels"], "QList", "SWGChannelListItem");
::Swagger::setValue(&channelcount, pJson["channelcount"], "qint32", "");
::Swagger::setValue(&channels, pJson["channels"], "QList", "SWGChannelListItem");
}
QString
@ -94,15 +84,12 @@ SWGInstanceChannelsResponse::asJson ()
QJsonObject*
SWGInstanceChannelsResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("channelcount", QJsonValue(channelcount));
QList<SWGChannelListItem*>* channelsList = channels;
QJsonArray channelsJsonArray;
toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannelListItem");
obj->insert("channels", channelsJsonArray);
return obj;
}
@ -126,6 +113,5 @@ SWGInstanceChannelsResponse::setChannels(QList<SWGChannelListItem*>* channels) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,14 +45,16 @@ public:
qint32 getChannelcount();
void setChannelcount(qint32 channelcount);
QList<SWGChannelListItem*>* getChannels();
QList<SWGChannelListItem*>* getChannels();
void setChannels(QList<SWGChannelListItem*>* channels);
private:
qint32 channelcount;
QList<SWGChannelListItem*>* channels;
QList<SWGChannelListItem*>* channels;
};
} /* namespace Swagger */
}
#endif /* SWGInstanceChannelsResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGInstanceDevicesResponse::SWGInstanceDevicesResponse(QString* json) {
init();
this->fromJson(*json);
@ -50,14 +37,15 @@ SWGInstanceDevicesResponse::~SWGInstanceDevicesResponse() {
void
SWGInstanceDevicesResponse::init() {
devicecount = NULL;
devices = new QList<SWGDeviceListItem*>();
devicecount = 0;
devices = new QList<SWGDeviceListItem*>();
}
void
SWGInstanceDevicesResponse::cleanup() {
if(devices != NULL) {
if(devices != nullptr) {
QList<SWGDeviceListItem*>* arr = devices;
foreach(SWGDeviceListItem* o, *arr) {
delete o;
@ -77,8 +65,10 @@ SWGInstanceDevicesResponse::fromJson(QString &json) {
void
SWGInstanceDevicesResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&devicecount, pJson["devicecount"], "qint32", "");
setValue(&devices, pJson["devices"], "QList", "SWGDeviceListItem");
::Swagger::setValue(&devicecount, pJson["devicecount"], "qint32", "");
::Swagger::setValue(&devices, pJson["devices"], "QList", "SWGDeviceListItem");
}
QString
@ -94,15 +84,12 @@ SWGInstanceDevicesResponse::asJson ()
QJsonObject*
SWGInstanceDevicesResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("devicecount", QJsonValue(devicecount));
QList<SWGDeviceListItem*>* devicesList = devices;
QJsonArray devicesJsonArray;
toJsonArray((QList<void*>*)devices, &devicesJsonArray, "devices", "SWGDeviceListItem");
obj->insert("devices", devicesJsonArray);
return obj;
}
@ -126,6 +113,5 @@ SWGInstanceDevicesResponse::setDevices(QList<SWGDeviceListItem*>* devices) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,14 +45,16 @@ public:
qint32 getDevicecount();
void setDevicecount(qint32 devicecount);
QList<SWGDeviceListItem*>* getDevices();
QList<SWGDeviceListItem*>* getDevices();
void setDevices(QList<SWGDeviceListItem*>* devices);
private:
qint32 devicecount;
QList<SWGDeviceListItem*>* devices;
QList<SWGDeviceListItem*>* devices;
};
} /* namespace Swagger */
}
#endif /* SWGInstanceDevicesResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGInstanceSummaryResponse::SWGInstanceSummaryResponse(QString* json) {
init();
this->fromJson(*json);
@ -51,23 +38,27 @@ SWGInstanceSummaryResponse::~SWGInstanceSummaryResponse() {
void
SWGInstanceSummaryResponse::init() {
version = new QString("");
logging = new SWGLoggingInfo();
devicesetlist = new SWGDeviceSetList();
user = new SWGUser();
logging = new SWGLoggingInfo();
devicesetlist = new SWGDeviceSetList();
user = new SWGUser();
}
void
SWGInstanceSummaryResponse::cleanup() {
if(version != NULL) {
if(version != nullptr) {
delete version;
}
if(logging != NULL) {
if(logging != nullptr) {
delete logging;
}
if(devicesetlist != NULL) {
if(devicesetlist != nullptr) {
delete devicesetlist;
}
if(user != NULL) {
if(user != nullptr) {
delete user;
}
}
@ -83,10 +74,10 @@ SWGInstanceSummaryResponse::fromJson(QString &json) {
void
SWGInstanceSummaryResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&version, pJson["version"], "QString", "QString");
setValue(&logging, pJson["logging"], "SWGLoggingInfo", "SWGLoggingInfo");
setValue(&devicesetlist, pJson["devicesetlist"], "SWGDeviceSetList", "SWGDeviceSetList");
setValue(&user, pJson["user"], "SWGUser", "SWGUser");
::Swagger::setValue(&version, pJson["version"], "QString", "QString");
::Swagger::setValue(&logging, pJson["logging"], "SWGLoggingInfo", "SWGLoggingInfo");
::Swagger::setValue(&devicesetlist, pJson["devicesetlist"], "SWGDeviceSetList", "SWGDeviceSetList");
::Swagger::setValue(&user, pJson["user"], "SWGUser", "SWGUser");
}
QString
@ -103,25 +94,13 @@ QJsonObject*
SWGInstanceSummaryResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("version"), version, obj, QString("QString"));
toJsonValue(QString("logging"), logging, obj, QString("SWGLoggingInfo"));
toJsonValue(QString("devicesetlist"), devicesetlist, obj, QString("SWGDeviceSetList"));
toJsonValue(QString("user"), user, obj, QString("SWGUser"));
return obj;
}
@ -163,6 +142,5 @@ SWGInstanceSummaryResponse::setUser(SWGUser* user) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -59,20 +47,24 @@ public:
QString* getVersion();
void setVersion(QString* version);
SWGLoggingInfo* getLogging();
SWGLoggingInfo* getLogging();
void setLogging(SWGLoggingInfo* logging);
SWGDeviceSetList* getDevicesetlist();
SWGDeviceSetList* getDevicesetlist();
void setDevicesetlist(SWGDeviceSetList* devicesetlist);
SWGUser* getUser();
SWGUser* getUser();
void setUser(SWGUser* user);
private:
QString* version;
SWGLoggingInfo* logging;
SWGDeviceSetList* devicesetlist;
SWGUser* user;
SWGLoggingInfo* logging;
SWGDeviceSetList* devicesetlist;
SWGUser* user;
};
} /* namespace Swagger */
}
#endif /* SWGInstanceSummaryResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGLocationInformation::SWGLocationInformation(QString* json) {
init();
this->fromJson(*json);
@ -51,7 +38,7 @@ SWGLocationInformation::~SWGLocationInformation() {
void
SWGLocationInformation::init() {
latitude = 0.0f;
longitude = 0.0f;
longitude = 0.0f;
}
void
@ -71,8 +58,8 @@ SWGLocationInformation::fromJson(QString &json) {
void
SWGLocationInformation::fromJsonObject(QJsonObject &pJson) {
setValue(&latitude, pJson["latitude"], "float", "");
setValue(&longitude, pJson["longitude"], "float", "");
::Swagger::setValue(&latitude, pJson["latitude"], "float", "");
::Swagger::setValue(&longitude, pJson["longitude"], "float", "");
}
QString
@ -88,8 +75,10 @@ SWGLocationInformation::asJson ()
QJsonObject*
SWGLocationInformation::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("latitude", QJsonValue(latitude));
obj->insert("longitude", QJsonValue(longitude));
obj->insert("longitude", QJsonValue(longitude));
return obj;
}
@ -113,6 +102,5 @@ SWGLocationInformation::setLongitude(float longitude) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,14 +43,16 @@ public:
float getLatitude();
void setLatitude(float latitude);
float getLongitude();
float getLongitude();
void setLongitude(float longitude);
private:
float latitude;
float longitude;
float longitude;
};
} /* namespace Swagger */
}
#endif /* SWGLocationInformation_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGLoggingInfo::SWGLoggingInfo(QString* json) {
init();
this->fromJson(*json);
@ -50,23 +37,26 @@ SWGLoggingInfo::~SWGLoggingInfo() {
void
SWGLoggingInfo::init() {
consoleLevel = new QString("");
fileLevel = new QString("");
dumpToFile = false;
fileName = new QString("");
console_level = new QString("");
file_level = new QString("");
dump_to_file = false;
file_name = new QString("");
}
void
SWGLoggingInfo::cleanup() {
if(consoleLevel != NULL) {
delete consoleLevel;
}
if(fileLevel != NULL) {
delete fileLevel;
if(console_level != nullptr) {
delete console_level;
}
if(fileName != NULL) {
delete fileName;
if(file_level != nullptr) {
delete file_level;
}
if(file_name != nullptr) {
delete file_name;
}
}
@ -81,10 +71,10 @@ SWGLoggingInfo::fromJson(QString &json) {
void
SWGLoggingInfo::fromJsonObject(QJsonObject &pJson) {
setValue(&consoleLevel, pJson["consoleLevel"], "QString", "QString");
setValue(&fileLevel, pJson["fileLevel"], "QString", "QString");
setValue(&dumpToFile, pJson["dumpToFile"], "bool", "");
setValue(&fileName, pJson["fileName"], "QString", "QString");
::Swagger::setValue(&console_level, pJson["consoleLevel"], "QString", "QString");
::Swagger::setValue(&file_level, pJson["fileLevel"], "QString", "QString");
::Swagger::setValue(&dump_to_file, pJson["dumpToFile"], "bool", "");
::Swagger::setValue(&file_name, pJson["fileName"], "QString", "QString");
}
QString
@ -101,62 +91,53 @@ QJsonObject*
SWGLoggingInfo::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("consoleLevel"), consoleLevel, obj, QString("QString"));
toJsonValue(QString("consoleLevel"), console_level, obj, QString("QString"));
toJsonValue(QString("fileLevel"), fileLevel, obj, QString("QString"));
obj->insert("dumpToFile", QJsonValue(dumpToFile));
toJsonValue(QString("fileLevel"), file_level, obj, QString("QString"));
toJsonValue(QString("fileName"), fileName, obj, QString("QString"));
obj->insert("dumpToFile", QJsonValue(dump_to_file));
toJsonValue(QString("fileName"), file_name, obj, QString("QString"));
return obj;
}
QString*
SWGLoggingInfo::getConsoleLevel() {
return consoleLevel;
return console_level;
}
void
SWGLoggingInfo::setConsoleLevel(QString* consoleLevel) {
this->consoleLevel = consoleLevel;
SWGLoggingInfo::setConsoleLevel(QString* console_level) {
this->console_level = console_level;
}
QString*
SWGLoggingInfo::getFileLevel() {
return fileLevel;
return file_level;
}
void
SWGLoggingInfo::setFileLevel(QString* fileLevel) {
this->fileLevel = fileLevel;
SWGLoggingInfo::setFileLevel(QString* file_level) {
this->file_level = file_level;
}
bool
SWGLoggingInfo::getDumpToFile() {
return dumpToFile;
return dump_to_file;
}
void
SWGLoggingInfo::setDumpToFile(bool dumpToFile) {
this->dumpToFile = dumpToFile;
SWGLoggingInfo::setDumpToFile(bool dump_to_file) {
this->dump_to_file = dump_to_file;
}
QString*
SWGLoggingInfo::getFileName() {
return fileName;
return file_name;
}
void
SWGLoggingInfo::setFileName(QString* fileName) {
this->fileName = fileName;
SWGLoggingInfo::setFileName(QString* file_name) {
this->file_name = file_name;
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,21 +43,25 @@ public:
SWGLoggingInfo* fromJson(QString &jsonString);
QString* getConsoleLevel();
void setConsoleLevel(QString* consoleLevel);
QString* getFileLevel();
void setFileLevel(QString* fileLevel);
bool getDumpToFile();
void setDumpToFile(bool dumpToFile);
QString* getFileName();
void setFileName(QString* fileName);
void setConsoleLevel(QString* console_level);
QString* getFileLevel();
void setFileLevel(QString* file_level);
bool getDumpToFile();
void setDumpToFile(bool dump_to_file);
QString* getFileName();
void setFileName(QString* file_name);
private:
QString* consoleLevel;
QString* fileLevel;
bool dumpToFile;
QString* fileName;
QString* console_level;
QString* file_level;
bool dump_to_file;
QString* file_name;
};
} /* namespace Swagger */
}
#endif /* SWGLoggingInfo_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ModelFactory_H_
@ -49,6 +37,7 @@
#include "SWGUser.h"
namespace Swagger {
inline void* create(QString type) {
if(QString("SWGAudioDevices").compare(type) == 0) {
return new SWGAudioDevices();
@ -114,20 +103,21 @@ namespace Swagger {
return new SWGUser();
}
return NULL;
return nullptr;
}
inline void* create(QString json, QString type) {
void* val = create(type);
if(val != NULL) {
if(val != nullptr) {
SWGObject* obj = static_cast<SWGObject*>(val);
return obj->fromJson(json);
}
if(type.startsWith("QString")) {
return new QString();
}
return NULL;
return nullptr;
}
} /* namespace Swagger */
}
#endif /* ModelFactory_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef _SWG_OBJECT_H_
@ -27,15 +15,17 @@
#include <QJsonValue>
namespace Swagger {
class SWGObject {
public:
virtual QJsonObject* asJsonObject() {
return NULL;
return nullptr;
}
virtual ~SWGObject() {}
virtual SWGObject* fromJson(QString &jsonString) {
Q_UNUSED(jsonString);
return NULL;
return nullptr;
}
virtual void fromJsonObject(QJsonObject &json) {
Q_UNUSED(json);
@ -45,4 +35,6 @@ class SWGObject {
}
};
}
#endif /* _SWG_OBJECT_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGPresetGroup::SWGPresetGroup(QString* json) {
init();
this->fromJson(*json);
@ -50,18 +37,20 @@ SWGPresetGroup::~SWGPresetGroup() {
void
SWGPresetGroup::init() {
groupName = new QString("");
nbPresets = NULL;
presets = new QList<SWGPresetItem*>();
group_name = new QString("");
nb_presets = 0;
presets = new QList<SWGPresetItem*>();
}
void
SWGPresetGroup::cleanup() {
if(groupName != NULL) {
delete groupName;
if(group_name != nullptr) {
delete group_name;
}
if(presets != NULL) {
if(presets != nullptr) {
QList<SWGPresetItem*>* arr = presets;
foreach(SWGPresetItem* o, *arr) {
delete o;
@ -81,9 +70,11 @@ SWGPresetGroup::fromJson(QString &json) {
void
SWGPresetGroup::fromJsonObject(QJsonObject &pJson) {
setValue(&groupName, pJson["groupName"], "QString", "QString");
setValue(&nbPresets, pJson["nbPresets"], "qint32", "");
setValue(&presets, pJson["presets"], "QList", "SWGPresetItem");
::Swagger::setValue(&group_name, pJson["groupName"], "QString", "QString");
::Swagger::setValue(&nb_presets, pJson["nbPresets"], "qint32", "");
::Swagger::setValue(&presets, pJson["presets"], "QList", "SWGPresetItem");
}
QString
@ -100,39 +91,33 @@ QJsonObject*
SWGPresetGroup::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("groupName"), groupName, obj, QString("QString"));
obj->insert("nbPresets", QJsonValue(nbPresets));
toJsonValue(QString("groupName"), group_name, obj, QString("QString"));
obj->insert("nbPresets", QJsonValue(nb_presets));
QList<SWGPresetItem*>* presetsList = presets;
QJsonArray presetsJsonArray;
toJsonArray((QList<void*>*)presets, &presetsJsonArray, "presets", "SWGPresetItem");
obj->insert("presets", presetsJsonArray);
return obj;
}
QString*
SWGPresetGroup::getGroupName() {
return groupName;
return group_name;
}
void
SWGPresetGroup::setGroupName(QString* groupName) {
this->groupName = groupName;
SWGPresetGroup::setGroupName(QString* group_name) {
this->group_name = group_name;
}
qint32
SWGPresetGroup::getNbPresets() {
return nbPresets;
return nb_presets;
}
void
SWGPresetGroup::setNbPresets(qint32 nbPresets) {
this->nbPresets = nbPresets;
SWGPresetGroup::setNbPresets(qint32 nb_presets) {
this->nb_presets = nb_presets;
}
QList<SWGPresetItem*>*
@ -145,6 +130,5 @@ SWGPresetGroup::setPresets(QList<SWGPresetItem*>* presets) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -57,18 +45,21 @@ public:
SWGPresetGroup* fromJson(QString &jsonString);
QString* getGroupName();
void setGroupName(QString* groupName);
qint32 getNbPresets();
void setNbPresets(qint32 nbPresets);
QList<SWGPresetItem*>* getPresets();
void setGroupName(QString* group_name);
qint32 getNbPresets();
void setNbPresets(qint32 nb_presets);
QList<SWGPresetItem*>* getPresets();
void setPresets(QList<SWGPresetItem*>* presets);
private:
QString* groupName;
qint32 nbPresets;
QList<SWGPresetItem*>* presets;
QString* group_name;
qint32 nb_presets;
QList<SWGPresetItem*>* presets;
};
} /* namespace Swagger */
}
#endif /* SWGPresetGroup_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGPresetIdentifier::SWGPresetIdentifier(QString* json) {
init();
this->fromJson(*json);
@ -50,22 +37,25 @@ SWGPresetIdentifier::~SWGPresetIdentifier() {
void
SWGPresetIdentifier::init() {
groupName = new QString("");
centerFrequency = 0.0f;
type = new QString("");
name = new QString("");
group_name = new QString("");
center_frequency = 0.0f;
type = new QString("");
name = new QString("");
}
void
SWGPresetIdentifier::cleanup() {
if(groupName != NULL) {
delete groupName;
if(group_name != nullptr) {
delete group_name;
}
if(type != NULL) {
if(type != nullptr) {
delete type;
}
if(name != NULL) {
if(name != nullptr) {
delete name;
}
}
@ -81,10 +71,10 @@ SWGPresetIdentifier::fromJson(QString &json) {
void
SWGPresetIdentifier::fromJsonObject(QJsonObject &pJson) {
setValue(&groupName, pJson["groupName"], "QString", "QString");
setValue(&centerFrequency, pJson["centerFrequency"], "float", "");
setValue(&type, pJson["type"], "QString", "QString");
setValue(&name, pJson["name"], "QString", "QString");
::Swagger::setValue(&group_name, pJson["groupName"], "QString", "QString");
::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "float", "");
::Swagger::setValue(&type, pJson["type"], "QString", "QString");
::Swagger::setValue(&name, pJson["name"], "QString", "QString");
}
QString
@ -101,41 +91,33 @@ QJsonObject*
SWGPresetIdentifier::asJsonObject() {
QJsonObject* obj = new QJsonObject();
toJsonValue(QString("groupName"), groupName, obj, QString("QString"));
obj->insert("centerFrequency", QJsonValue(centerFrequency));
toJsonValue(QString("groupName"), group_name, obj, QString("QString"));
obj->insert("centerFrequency", QJsonValue(center_frequency));
toJsonValue(QString("type"), type, obj, QString("QString"));
toJsonValue(QString("name"), name, obj, QString("QString"));
return obj;
}
QString*
SWGPresetIdentifier::getGroupName() {
return groupName;
return group_name;
}
void
SWGPresetIdentifier::setGroupName(QString* groupName) {
this->groupName = groupName;
SWGPresetIdentifier::setGroupName(QString* group_name) {
this->group_name = group_name;
}
float
SWGPresetIdentifier::getCenterFrequency() {
return centerFrequency;
return center_frequency;
}
void
SWGPresetIdentifier::setCenterFrequency(float centerFrequency) {
this->centerFrequency = centerFrequency;
SWGPresetIdentifier::setCenterFrequency(float center_frequency) {
this->center_frequency = center_frequency;
}
QString*
@ -157,6 +139,5 @@ SWGPresetIdentifier::setName(QString* name) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,21 +43,25 @@ public:
SWGPresetIdentifier* fromJson(QString &jsonString);
QString* getGroupName();
void setGroupName(QString* groupName);
float getCenterFrequency();
void setCenterFrequency(float centerFrequency);
QString* getType();
void setGroupName(QString* group_name);
float getCenterFrequency();
void setCenterFrequency(float center_frequency);
QString* getType();
void setType(QString* type);
QString* getName();
QString* getName();
void setName(QString* name);
private:
QString* groupName;
float centerFrequency;
QString* type;
QString* name;
QString* group_name;
float center_frequency;
QString* type;
QString* name;
};
} /* namespace Swagger */
}
#endif /* SWGPresetIdentifier_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGPresetItem::SWGPresetItem(QString* json) {
init();
this->fromJson(*json);
@ -50,18 +37,20 @@ SWGPresetItem::~SWGPresetItem() {
void
SWGPresetItem::init() {
centerFrequency = 0.0f;
type = new QString("");
name = new QString("");
center_frequency = 0.0f;
type = new QString("");
name = new QString("");
}
void
SWGPresetItem::cleanup() {
if(type != NULL) {
if(type != nullptr) {
delete type;
}
if(name != NULL) {
if(name != nullptr) {
delete name;
}
}
@ -77,9 +66,9 @@ SWGPresetItem::fromJson(QString &json) {
void
SWGPresetItem::fromJsonObject(QJsonObject &pJson) {
setValue(&centerFrequency, pJson["centerFrequency"], "float", "");
setValue(&type, pJson["type"], "QString", "QString");
setValue(&name, pJson["name"], "QString", "QString");
::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "float", "");
::Swagger::setValue(&type, pJson["type"], "QString", "QString");
::Swagger::setValue(&name, pJson["name"], "QString", "QString");
}
QString
@ -95,28 +84,23 @@ SWGPresetItem::asJson ()
QJsonObject*
SWGPresetItem::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("centerFrequency", QJsonValue(centerFrequency));
obj->insert("centerFrequency", QJsonValue(center_frequency));
toJsonValue(QString("type"), type, obj, QString("QString"));
toJsonValue(QString("name"), name, obj, QString("QString"));
return obj;
}
float
SWGPresetItem::getCenterFrequency() {
return centerFrequency;
return center_frequency;
}
void
SWGPresetItem::setCenterFrequency(float centerFrequency) {
this->centerFrequency = centerFrequency;
SWGPresetItem::setCenterFrequency(float center_frequency) {
this->center_frequency = center_frequency;
}
QString*
@ -138,6 +122,5 @@ SWGPresetItem::setName(QString* name) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,18 +43,21 @@ public:
SWGPresetItem* fromJson(QString &jsonString);
float getCenterFrequency();
void setCenterFrequency(float centerFrequency);
QString* getType();
void setCenterFrequency(float center_frequency);
QString* getType();
void setType(QString* type);
QString* getName();
QString* getName();
void setName(QString* name);
private:
float centerFrequency;
QString* type;
QString* name;
float center_frequency;
QString* type;
QString* name;
};
} /* namespace Swagger */
}
#endif /* SWGPresetItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGPresetTransfer::SWGPresetTransfer(QString* json) {
init();
this->fromJson(*json);
@ -50,14 +37,15 @@ SWGPresetTransfer::~SWGPresetTransfer() {
void
SWGPresetTransfer::init() {
deviceSetIndex = NULL;
preset = new SWGPresetIdentifier();
device_set_index = 0;
preset = new SWGPresetIdentifier();
}
void
SWGPresetTransfer::cleanup() {
if(preset != NULL) {
if(preset != nullptr) {
delete preset;
}
}
@ -73,8 +61,8 @@ SWGPresetTransfer::fromJson(QString &json) {
void
SWGPresetTransfer::fromJsonObject(QJsonObject &pJson) {
setValue(&deviceSetIndex, pJson["deviceSetIndex"], "qint32", "");
setValue(&preset, pJson["preset"], "SWGPresetIdentifier", "SWGPresetIdentifier");
::Swagger::setValue(&device_set_index, pJson["deviceSetIndex"], "qint32", "");
::Swagger::setValue(&preset, pJson["preset"], "SWGPresetIdentifier", "SWGPresetIdentifier");
}
QString
@ -90,23 +78,21 @@ SWGPresetTransfer::asJson ()
QJsonObject*
SWGPresetTransfer::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("deviceSetIndex", QJsonValue(deviceSetIndex));
obj->insert("deviceSetIndex", QJsonValue(device_set_index));
toJsonValue(QString("preset"), preset, obj, QString("SWGPresetIdentifier"));
return obj;
}
qint32
SWGPresetTransfer::getDeviceSetIndex() {
return deviceSetIndex;
return device_set_index;
}
void
SWGPresetTransfer::setDeviceSetIndex(qint32 deviceSetIndex) {
this->deviceSetIndex = deviceSetIndex;
SWGPresetTransfer::setDeviceSetIndex(qint32 device_set_index) {
this->device_set_index = device_set_index;
}
SWGPresetIdentifier*
@ -119,6 +105,5 @@ SWGPresetTransfer::setPreset(SWGPresetIdentifier* preset) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -55,15 +43,17 @@ public:
SWGPresetTransfer* fromJson(QString &jsonString);
qint32 getDeviceSetIndex();
void setDeviceSetIndex(qint32 deviceSetIndex);
SWGPresetIdentifier* getPreset();
void setDeviceSetIndex(qint32 device_set_index);
SWGPresetIdentifier* getPreset();
void setPreset(SWGPresetIdentifier* preset);
private:
qint32 deviceSetIndex;
SWGPresetIdentifier* preset;
qint32 device_set_index;
SWGPresetIdentifier* preset;
};
} /* namespace Swagger */
}
#endif /* SWGPresetTransfer_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGPresets::SWGPresets(QString* json) {
init();
this->fromJson(*json);
@ -50,14 +37,15 @@ SWGPresets::~SWGPresets() {
void
SWGPresets::init() {
nbGroups = NULL;
groups = new QList<SWGPresetGroup*>();
nb_groups = 0;
groups = new QList<SWGPresetGroup*>();
}
void
SWGPresets::cleanup() {
if(groups != NULL) {
if(groups != nullptr) {
QList<SWGPresetGroup*>* arr = groups;
foreach(SWGPresetGroup* o, *arr) {
delete o;
@ -77,8 +65,10 @@ SWGPresets::fromJson(QString &json) {
void
SWGPresets::fromJsonObject(QJsonObject &pJson) {
setValue(&nbGroups, pJson["nbGroups"], "qint32", "");
setValue(&groups, pJson["groups"], "QList", "SWGPresetGroup");
::Swagger::setValue(&nb_groups, pJson["nbGroups"], "qint32", "");
::Swagger::setValue(&groups, pJson["groups"], "QList", "SWGPresetGroup");
}
QString
@ -94,26 +84,23 @@ SWGPresets::asJson ()
QJsonObject*
SWGPresets::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("nbGroups", QJsonValue(nbGroups));
QList<SWGPresetGroup*>* groupsList = groups;
obj->insert("nbGroups", QJsonValue(nb_groups));
QJsonArray groupsJsonArray;
toJsonArray((QList<void*>*)groups, &groupsJsonArray, "groups", "SWGPresetGroup");
obj->insert("groups", groupsJsonArray);
return obj;
}
qint32
SWGPresets::getNbGroups() {
return nbGroups;
return nb_groups;
}
void
SWGPresets::setNbGroups(qint32 nbGroups) {
this->nbGroups = nbGroups;
SWGPresets::setNbGroups(qint32 nb_groups) {
this->nb_groups = nb_groups;
}
QList<SWGPresetGroup*>*
@ -126,6 +113,5 @@ SWGPresets::setGroups(QList<SWGPresetGroup*>* groups) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,15 +44,17 @@ public:
SWGPresets* fromJson(QString &jsonString);
qint32 getNbGroups();
void setNbGroups(qint32 nbGroups);
QList<SWGPresetGroup*>* getGroups();
void setNbGroups(qint32 nb_groups);
QList<SWGPresetGroup*>* getGroups();
void setGroups(QList<SWGPresetGroup*>* groups);
private:
qint32 nbGroups;
QList<SWGPresetGroup*>* groups;
qint32 nb_groups;
QList<SWGPresetGroup*>* groups;
};
} /* namespace Swagger */
}
#endif /* SWGPresets_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGSamplingDevice::SWGSamplingDevice(QString* json) {
init();
this->fromJson(*json);
@ -50,28 +37,30 @@ SWGSamplingDevice::~SWGSamplingDevice() {
void
SWGSamplingDevice::init() {
index = NULL;
hwType = new QString("");
tx = false;
nbStreams = NULL;
streamIndex = NULL;
sequence = NULL;
serial = new QString("");
centerFrequency = 0L;
bandwidth = NULL;
index = 0;
hw_type = new QString("");
tx = false;
nb_streams = 0;
stream_index = 0;
sequence = 0;
serial = new QString("");
center_frequency = 0L;
bandwidth = 0;
}
void
SWGSamplingDevice::cleanup() {
if(hwType != NULL) {
delete hwType;
if(hw_type != nullptr) {
delete hw_type;
}
if(serial != NULL) {
if(serial != nullptr) {
delete serial;
}
@ -89,15 +78,15 @@ SWGSamplingDevice::fromJson(QString &json) {
void
SWGSamplingDevice::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", "");
setValue(&hwType, pJson["hwType"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", "");
setValue(&nbStreams, pJson["nbStreams"], "qint32", "");
setValue(&streamIndex, pJson["streamIndex"], "qint32", "");
setValue(&sequence, pJson["sequence"], "qint32", "");
setValue(&serial, pJson["serial"], "QString", "QString");
setValue(&centerFrequency, pJson["centerFrequency"], "qint64", "");
setValue(&bandwidth, pJson["bandwidth"], "qint32", "");
::Swagger::setValue(&index, pJson["index"], "qint32", "");
::Swagger::setValue(&hw_type, pJson["hwType"], "QString", "QString");
::Swagger::setValue(&tx, pJson["tx"], "bool", "");
::Swagger::setValue(&nb_streams, pJson["nbStreams"], "qint32", "");
::Swagger::setValue(&stream_index, pJson["streamIndex"], "qint32", "");
::Swagger::setValue(&sequence, pJson["sequence"], "qint32", "");
::Swagger::setValue(&serial, pJson["serial"], "QString", "QString");
::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "qint64", "");
::Swagger::setValue(&bandwidth, pJson["bandwidth"], "qint32", "");
}
QString
@ -113,23 +102,24 @@ SWGSamplingDevice::asJson ()
QJsonObject*
SWGSamplingDevice::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index));
toJsonValue(QString("hwType"), hwType, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("nbStreams", QJsonValue(nbStreams));
obj->insert("streamIndex", QJsonValue(streamIndex));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("hwType"), hw_type, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("nbStreams", QJsonValue(nb_streams));
obj->insert("streamIndex", QJsonValue(stream_index));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("serial"), serial, obj, QString("QString"));
obj->insert("centerFrequency", QJsonValue(centerFrequency));
obj->insert("bandwidth", QJsonValue(bandwidth));
obj->insert("centerFrequency", QJsonValue(center_frequency));
obj->insert("bandwidth", QJsonValue(bandwidth));
return obj;
}
@ -145,11 +135,11 @@ SWGSamplingDevice::setIndex(qint32 index) {
QString*
SWGSamplingDevice::getHwType() {
return hwType;
return hw_type;
}
void
SWGSamplingDevice::setHwType(QString* hwType) {
this->hwType = hwType;
SWGSamplingDevice::setHwType(QString* hw_type) {
this->hw_type = hw_type;
}
bool
@ -163,20 +153,20 @@ SWGSamplingDevice::setTx(bool tx) {
qint32
SWGSamplingDevice::getNbStreams() {
return nbStreams;
return nb_streams;
}
void
SWGSamplingDevice::setNbStreams(qint32 nbStreams) {
this->nbStreams = nbStreams;
SWGSamplingDevice::setNbStreams(qint32 nb_streams) {
this->nb_streams = nb_streams;
}
qint32
SWGSamplingDevice::getStreamIndex() {
return streamIndex;
return stream_index;
}
void
SWGSamplingDevice::setStreamIndex(qint32 streamIndex) {
this->streamIndex = streamIndex;
SWGSamplingDevice::setStreamIndex(qint32 stream_index) {
this->stream_index = stream_index;
}
qint32
@ -199,11 +189,11 @@ SWGSamplingDevice::setSerial(QString* serial) {
qint64
SWGSamplingDevice::getCenterFrequency() {
return centerFrequency;
return center_frequency;
}
void
SWGSamplingDevice::setCenterFrequency(qint64 centerFrequency) {
this->centerFrequency = centerFrequency;
SWGSamplingDevice::setCenterFrequency(qint64 center_frequency) {
this->center_frequency = center_frequency;
}
qint32
@ -216,6 +206,5 @@ SWGSamplingDevice::setBandwidth(qint32 bandwidth) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,35 +44,44 @@ public:
qint32 getIndex();
void setIndex(qint32 index);
QString* getHwType();
void setHwType(QString* hwType);
bool getTx();
QString* getHwType();
void setHwType(QString* hw_type);
bool getTx();
void setTx(bool tx);
qint32 getNbStreams();
void setNbStreams(qint32 nbStreams);
qint32 getStreamIndex();
void setStreamIndex(qint32 streamIndex);
qint32 getSequence();
qint32 getNbStreams();
void setNbStreams(qint32 nb_streams);
qint32 getStreamIndex();
void setStreamIndex(qint32 stream_index);
qint32 getSequence();
void setSequence(qint32 sequence);
QString* getSerial();
QString* getSerial();
void setSerial(QString* serial);
qint64 getCenterFrequency();
void setCenterFrequency(qint64 centerFrequency);
qint32 getBandwidth();
qint64 getCenterFrequency();
void setCenterFrequency(qint64 center_frequency);
qint32 getBandwidth();
void setBandwidth(qint32 bandwidth);
private:
qint32 index;
QString* hwType;
bool tx;
qint32 nbStreams;
qint32 streamIndex;
qint32 sequence;
QString* serial;
qint64 centerFrequency;
qint32 bandwidth;
QString* hw_type;
bool tx;
qint32 nb_streams;
qint32 stream_index;
qint32 sequence;
QString* serial;
qint64 center_frequency;
qint32 bandwidth;
};
} /* namespace Swagger */
}
#endif /* SWGSamplingDevice_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
@ -34,7 +22,6 @@
namespace Swagger {
SWGUser::SWGUser(QString* json) {
init();
this->fromJson(*json);
@ -50,14 +37,15 @@ SWGUser::~SWGUser() {
void
SWGUser::init() {
index = NULL;
name = new QString("");
index = 0;
name = new QString("");
}
void
SWGUser::cleanup() {
if(name != NULL) {
if(name != nullptr) {
delete name;
}
}
@ -73,8 +61,8 @@ SWGUser::fromJson(QString &json) {
void
SWGUser::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", "");
setValue(&name, pJson["name"], "QString", "QString");
::Swagger::setValue(&index, pJson["index"], "qint32", "");
::Swagger::setValue(&name, pJson["name"], "QString", "QString");
}
QString
@ -90,12 +78,10 @@ SWGUser::asJson ()
QJsonObject*
SWGUser::asJsonObject() {
QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index));
toJsonValue(QString("name"), name, obj, QString("QString"));
return obj;
}
@ -119,6 +105,5 @@ SWGUser::setName(QString* name) {
}
} /* namespace Swagger */
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
@ -56,14 +44,16 @@ public:
qint32 getIndex();
void setIndex(qint32 index);
QString* getName();
QString* getName();
void setName(QString* name);
private:
qint32 index;
QString* name;
QString* name;
};
} /* namespace Swagger */
}
#endif /* SWGUser_H_ */