1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-22 16:08:39 -05:00

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 += sdrgui
SUBDIRS += httpserver SUBDIRS += httpserver
SUBDIRS += logging SUBDIRS += logging
SUBDIRS += swagger
CONFIG(MINGW64)SUBDIRS += nanomsg CONFIG(MINGW64)SUBDIRS += nanomsg
SUBDIRS += fcdhid SUBDIRS += fcdhid
SUBDIRS += fcdlib 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGAudioDevices::SWGAudioDevices(QString* json) { SWGAudioDevices::SWGAudioDevices(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,29 +37,31 @@ SWGAudioDevices::~SWGAudioDevices() {
void void
SWGAudioDevices::init() { SWGAudioDevices::init() {
nbInputDevices = NULL; nb_input_devices = 0;
inputDevices = new QList<QString*>(); input_devices = new QList<QString*>();
nbOutputDevices = NULL; nb_output_devices = 0;
outputDevices = new QList<QString*>(); output_devices = new QList<QString*>();
} }
void void
SWGAudioDevices::cleanup() { SWGAudioDevices::cleanup() {
if(inputDevices != NULL) {
QList<QString*>* arr = inputDevices; if(input_devices != nullptr) {
QList<QString*>* arr = input_devices;
foreach(QString* o, *arr) { foreach(QString* o, *arr) {
delete o; 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) { foreach(QString* o, *arr) {
delete o; delete o;
} }
delete outputDevices; delete output_devices;
} }
} }
@ -87,10 +76,14 @@ SWGAudioDevices::fromJson(QString &json) {
void void
SWGAudioDevices::fromJsonObject(QJsonObject &pJson) { SWGAudioDevices::fromJsonObject(QJsonObject &pJson) {
setValue(&nbInputDevices, pJson["nbInputDevices"], "qint32", ""); ::Swagger::setValue(&nb_input_devices, pJson["nbInputDevices"], "qint32", "");
setValue(&inputDevices, pJson["inputDevices"], "QList", "QString");
setValue(&nbOutputDevices, pJson["nbOutputDevices"], "qint32", ""); ::Swagger::setValue(&input_devices, pJson["inputDevices"], "QList", "QString");
setValue(&outputDevices, pJson["outputDevices"], "QList", "QString");
::Swagger::setValue(&nb_output_devices, pJson["nbOutputDevices"], "qint32", "");
::Swagger::setValue(&output_devices, pJson["outputDevices"], "QList", "QString");
} }
QString QString
@ -106,65 +99,58 @@ SWGAudioDevices::asJson ()
QJsonObject* QJsonObject*
SWGAudioDevices::asJsonObject() { SWGAudioDevices::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("nbInputDevices", QJsonValue(nbInputDevices));
QList<QString*>* inputDevicesList = inputDevices; obj->insert("nbInputDevices", QJsonValue(nb_input_devices));
QJsonArray inputDevicesJsonArray;
toJsonArray((QList<void*>*)inputDevices, &inputDevicesJsonArray, "inputDevices", "QString");
obj->insert("inputDevices", inputDevicesJsonArray); QJsonArray input_devicesJsonArray;
toJsonArray((QList<void*>*)input_devices, &input_devicesJsonArray, "input_devices", "QString");
obj->insert("nbOutputDevices", QJsonValue(nbOutputDevices)); obj->insert("inputDevices", input_devicesJsonArray);
obj->insert("nbOutputDevices", QJsonValue(nb_output_devices));
QList<QString*>* outputDevicesList = outputDevices;
QJsonArray outputDevicesJsonArray;
toJsonArray((QList<void*>*)outputDevices, &outputDevicesJsonArray, "outputDevices", "QString");
obj->insert("outputDevices", outputDevicesJsonArray); QJsonArray output_devicesJsonArray;
toJsonArray((QList<void*>*)output_devices, &output_devicesJsonArray, "output_devices", "QString");
obj->insert("outputDevices", output_devicesJsonArray);
return obj; return obj;
} }
qint32 qint32
SWGAudioDevices::getNbInputDevices() { SWGAudioDevices::getNbInputDevices() {
return nbInputDevices; return nb_input_devices;
} }
void void
SWGAudioDevices::setNbInputDevices(qint32 nbInputDevices) { SWGAudioDevices::setNbInputDevices(qint32 nb_input_devices) {
this->nbInputDevices = nbInputDevices; this->nb_input_devices = nb_input_devices;
} }
QList<QString*>* QList<QString*>*
SWGAudioDevices::getInputDevices() { SWGAudioDevices::getInputDevices() {
return inputDevices; return input_devices;
} }
void void
SWGAudioDevices::setInputDevices(QList<QString*>* inputDevices) { SWGAudioDevices::setInputDevices(QList<QString*>* input_devices) {
this->inputDevices = inputDevices; this->input_devices = input_devices;
} }
qint32 qint32
SWGAudioDevices::getNbOutputDevices() { SWGAudioDevices::getNbOutputDevices() {
return nbOutputDevices; return nb_output_devices;
} }
void void
SWGAudioDevices::setNbOutputDevices(qint32 nbOutputDevices) { SWGAudioDevices::setNbOutputDevices(qint32 nb_output_devices) {
this->nbOutputDevices = nbOutputDevices; this->nb_output_devices = nb_output_devices;
} }
QList<QString*>* QList<QString*>*
SWGAudioDevices::getOutputDevices() { SWGAudioDevices::getOutputDevices() {
return outputDevices; return output_devices;
} }
void void
SWGAudioDevices::setOutputDevices(QList<QString*>* outputDevices) { SWGAudioDevices::setOutputDevices(QList<QString*>* output_devices) {
this->outputDevices = outputDevices; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGAudioDevices* fromJson(QString &jsonString);
qint32 getNbInputDevices(); qint32 getNbInputDevices();
void setNbInputDevices(qint32 nbInputDevices); void setNbInputDevices(qint32 nb_input_devices);
QList<QString*>* getInputDevices();
void setInputDevices(QList<QString*>* inputDevices); QList<QString*>* getInputDevices();
qint32 getNbOutputDevices(); void setInputDevices(QList<QString*>* input_devices);
void setNbOutputDevices(qint32 nbOutputDevices);
QList<QString*>* getOutputDevices(); qint32 getNbOutputDevices();
void setOutputDevices(QList<QString*>* outputDevices); void setNbOutputDevices(qint32 nb_output_devices);
QList<QString*>* getOutputDevices();
void setOutputDevices(QList<QString*>* output_devices);
private: private:
qint32 nbInputDevices; qint32 nb_input_devices;
QList<QString*>* inputDevices; QList<QString*>* input_devices;
qint32 nbOutputDevices; qint32 nb_output_devices;
QList<QString*>* outputDevices; QList<QString*>* output_devices;
}; };
} /* namespace Swagger */ }
#endif /* SWGAudioDevices_H_ */ #endif /* SWGAudioDevices_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGAudioDevicesSelect::SWGAudioDevicesSelect(QString* json) { SWGAudioDevicesSelect::SWGAudioDevicesSelect(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -51,15 +38,17 @@ SWGAudioDevicesSelect::~SWGAudioDevicesSelect() {
void void
SWGAudioDevicesSelect::init() { SWGAudioDevicesSelect::init() {
input = new QString(""); input = new QString("");
output = new QString(""); output = new QString("");
} }
void void
SWGAudioDevicesSelect::cleanup() { SWGAudioDevicesSelect::cleanup() {
if(input != NULL) {
if(input != nullptr) {
delete input; delete input;
} }
if(output != NULL) {
if(output != nullptr) {
delete output; delete output;
} }
} }
@ -75,8 +64,8 @@ SWGAudioDevicesSelect::fromJson(QString &json) {
void void
SWGAudioDevicesSelect::fromJsonObject(QJsonObject &pJson) { SWGAudioDevicesSelect::fromJsonObject(QJsonObject &pJson) {
setValue(&input, pJson["input"], "QString", "QString"); ::Swagger::setValue(&input, pJson["input"], "QString", "QString");
setValue(&output, pJson["output"], "QString", "QString"); ::Swagger::setValue(&output, pJson["output"], "QString", "QString");
} }
QString QString
@ -93,15 +82,9 @@ QJsonObject*
SWGAudioDevicesSelect::asJsonObject() { SWGAudioDevicesSelect::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("input"), input, obj, QString("QString")); toJsonValue(QString("input"), input, obj, QString("QString"));
toJsonValue(QString("output"), output, obj, QString("QString")); toJsonValue(QString("output"), output, obj, QString("QString"));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); QString* getInput();
void setInput(QString* input); void setInput(QString* input);
QString* getOutput();
QString* getOutput();
void setOutput(QString* output); void setOutput(QString* output);
private: private:
QString* input; QString* input;
QString* output; QString* output;
}; };
} /* namespace Swagger */ }
#endif /* SWGAudioDevicesSelect_H_ */ #endif /* SWGAudioDevicesSelect_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGChannel::SWGChannel(QString* json) { SWGChannel::SWGChannel(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,15 +37,16 @@ SWGChannel::~SWGChannel() {
void void
SWGChannel::init() { SWGChannel::init() {
index = NULL; index = 0;
id = new QString(""); id = new QString("");
deltaFrequency = NULL; delta_frequency = 0;
} }
void void
SWGChannel::cleanup() { SWGChannel::cleanup() {
if(id != NULL) {
if(id != nullptr) {
delete id; delete id;
} }
@ -75,9 +63,9 @@ SWGChannel::fromJson(QString &json) {
void void
SWGChannel::fromJsonObject(QJsonObject &pJson) { SWGChannel::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", ""); ::Swagger::setValue(&index, pJson["index"], "qint32", "");
setValue(&id, pJson["id"], "QString", "QString"); ::Swagger::setValue(&id, pJson["id"], "QString", "QString");
setValue(&deltaFrequency, pJson["deltaFrequency"], "qint32", ""); ::Swagger::setValue(&delta_frequency, pJson["deltaFrequency"], "qint32", "");
} }
QString QString
@ -93,13 +81,12 @@ SWGChannel::asJson ()
QJsonObject* QJsonObject*
SWGChannel::asJsonObject() { SWGChannel::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index)); obj->insert("index", QJsonValue(index));
toJsonValue(QString("id"), id, obj, QString("QString")); toJsonValue(QString("id"), id, obj, QString("QString"));
obj->insert("deltaFrequency", QJsonValue(delta_frequency));
obj->insert("deltaFrequency", QJsonValue(deltaFrequency));
return obj; return obj;
} }
@ -124,14 +111,13 @@ SWGChannel::setId(QString* id) {
qint32 qint32
SWGChannel::getDeltaFrequency() { SWGChannel::getDeltaFrequency() {
return deltaFrequency; return delta_frequency;
} }
void void
SWGChannel::setDeltaFrequency(qint32 deltaFrequency) { SWGChannel::setDeltaFrequency(qint32 delta_frequency) {
this->deltaFrequency = deltaFrequency; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getIndex();
void setIndex(qint32 index); void setIndex(qint32 index);
QString* getId();
QString* getId();
void setId(QString* id); void setId(QString* id);
qint32 getDeltaFrequency();
void setDeltaFrequency(qint32 deltaFrequency); qint32 getDeltaFrequency();
void setDeltaFrequency(qint32 delta_frequency);
private: private:
qint32 index; qint32 index;
QString* id; QString* id;
qint32 deltaFrequency; qint32 delta_frequency;
}; };
} /* namespace Swagger */ }
#endif /* SWGChannel_H_ */ #endif /* SWGChannel_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGChannelListItem::SWGChannelListItem(QString* json) { SWGChannelListItem::SWGChannelListItem(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -51,21 +38,24 @@ SWGChannelListItem::~SWGChannelListItem() {
void void
SWGChannelListItem::init() { SWGChannelListItem::init() {
name = new QString(""); name = new QString("");
id = new QString(""); id = new QString("");
tx = false; tx = false;
version = new QString(""); version = new QString("");
} }
void void
SWGChannelListItem::cleanup() { SWGChannelListItem::cleanup() {
if(name != NULL) {
if(name != nullptr) {
delete name; delete name;
} }
if(id != NULL) {
if(id != nullptr) {
delete id; delete id;
} }
if(version != NULL) {
if(version != nullptr) {
delete version; delete version;
} }
} }
@ -81,10 +71,10 @@ SWGChannelListItem::fromJson(QString &json) {
void void
SWGChannelListItem::fromJsonObject(QJsonObject &pJson) { SWGChannelListItem::fromJsonObject(QJsonObject &pJson) {
setValue(&name, pJson["name"], "QString", "QString"); ::Swagger::setValue(&name, pJson["name"], "QString", "QString");
setValue(&id, pJson["id"], "QString", "QString"); ::Swagger::setValue(&id, pJson["id"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", ""); ::Swagger::setValue(&tx, pJson["tx"], "bool", "");
setValue(&version, pJson["version"], "QString", "QString"); ::Swagger::setValue(&version, pJson["version"], "QString", "QString");
} }
QString QString
@ -101,21 +91,13 @@ QJsonObject*
SWGChannelListItem::asJsonObject() { SWGChannelListItem::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("name"), name, obj, QString("QString")); toJsonValue(QString("name"), name, obj, QString("QString"));
toJsonValue(QString("id"), id, 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")); toJsonValue(QString("version"), version, obj, QString("QString"));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); QString* getName();
void setName(QString* name); void setName(QString* name);
QString* getId();
QString* getId();
void setId(QString* id); void setId(QString* id);
bool getTx();
bool getTx();
void setTx(bool tx); void setTx(bool tx);
QString* getVersion();
QString* getVersion();
void setVersion(QString* version); void setVersion(QString* version);
private: private:
QString* name; QString* name;
QString* id; QString* id;
bool tx; bool tx;
QString* version; QString* version;
}; };
} /* namespace Swagger */ }
#endif /* SWGChannelListItem_H_ */ #endif /* SWGChannelListItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGDVSeralDevices::SWGDVSeralDevices(QString* json) { SWGDVSeralDevices::SWGDVSeralDevices(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,19 +37,20 @@ SWGDVSeralDevices::~SWGDVSeralDevices() {
void void
SWGDVSeralDevices::init() { SWGDVSeralDevices::init() {
nbDevices = NULL; nb_devices = 0;
dvSerialDevices = new QList<QString*>(); dv_serial_devices = new QList<QString*>();
} }
void void
SWGDVSeralDevices::cleanup() { SWGDVSeralDevices::cleanup() {
if(dvSerialDevices != NULL) {
QList<QString*>* arr = dvSerialDevices; if(dv_serial_devices != nullptr) {
QList<QString*>* arr = dv_serial_devices;
foreach(QString* o, *arr) { foreach(QString* o, *arr) {
delete o; delete o;
} }
delete dvSerialDevices; delete dv_serial_devices;
} }
} }
@ -77,8 +65,10 @@ SWGDVSeralDevices::fromJson(QString &json) {
void void
SWGDVSeralDevices::fromJsonObject(QJsonObject &pJson) { SWGDVSeralDevices::fromJsonObject(QJsonObject &pJson) {
setValue(&nbDevices, pJson["nbDevices"], "qint32", ""); ::Swagger::setValue(&nb_devices, pJson["nbDevices"], "qint32", "");
setValue(&dvSerialDevices, pJson["dvSerialDevices"], "QList", "QString");
::Swagger::setValue(&dv_serial_devices, pJson["dvSerialDevices"], "QList", "QString");
} }
QString QString
@ -94,38 +84,34 @@ SWGDVSeralDevices::asJson ()
QJsonObject* QJsonObject*
SWGDVSeralDevices::asJsonObject() { SWGDVSeralDevices::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("nbDevices", QJsonValue(nbDevices));
QList<QString*>* dvSerialDevicesList = dvSerialDevices; obj->insert("nbDevices", QJsonValue(nb_devices));
QJsonArray dvSerialDevicesJsonArray;
toJsonArray((QList<void*>*)dvSerialDevices, &dvSerialDevicesJsonArray, "dvSerialDevices", "QString");
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; return obj;
} }
qint32 qint32
SWGDVSeralDevices::getNbDevices() { SWGDVSeralDevices::getNbDevices() {
return nbDevices; return nb_devices;
} }
void void
SWGDVSeralDevices::setNbDevices(qint32 nbDevices) { SWGDVSeralDevices::setNbDevices(qint32 nb_devices) {
this->nbDevices = nbDevices; this->nb_devices = nb_devices;
} }
QList<QString*>* QList<QString*>*
SWGDVSeralDevices::getDvSerialDevices() { SWGDVSeralDevices::getDvSerialDevices() {
return dvSerialDevices; return dv_serial_devices;
} }
void void
SWGDVSeralDevices::setDvSerialDevices(QList<QString*>* dvSerialDevices) { SWGDVSeralDevices::setDvSerialDevices(QList<QString*>* dv_serial_devices) {
this->dvSerialDevices = dvSerialDevices; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGDVSeralDevices* fromJson(QString &jsonString);
qint32 getNbDevices(); qint32 getNbDevices();
void setNbDevices(qint32 nbDevices); void setNbDevices(qint32 nb_devices);
QList<QString*>* getDvSerialDevices();
void setDvSerialDevices(QList<QString*>* dvSerialDevices); QList<QString*>* getDvSerialDevices();
void setDvSerialDevices(QList<QString*>* dv_serial_devices);
private: private:
qint32 nbDevices; qint32 nb_devices;
QList<QString*>* dvSerialDevices; QList<QString*>* dv_serial_devices;
}; };
} /* namespace Swagger */ }
#endif /* SWGDVSeralDevices_H_ */ #endif /* SWGDVSeralDevices_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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" #include "SWGDefaultApi.h"
@ -30,6 +18,7 @@
#include <QJsonDocument> #include <QJsonDocument>
namespace Swagger { namespace Swagger {
SWGDefaultApi::SWGDefaultApi() {} SWGDefaultApi::SWGDefaultApi() {}
SWGDefaultApi::~SWGDefaultApi() {} SWGDefaultApi::~SWGDefaultApi() {}
@ -49,10 +38,14 @@ SWGDefaultApi::instanceAudioGet() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -64,6 +57,9 @@ SWGDefaultApi::instanceAudioGet() {
void void
SWGDefaultApi::instanceAudioGetCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceAudioGetCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -71,16 +67,15 @@ SWGDefaultApi::instanceAudioGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceAudioGetSignal(output); emit instanceAudioGetSignal(output);
emit instanceAudioGetSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) { SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
QString fullPath; QString fullPath;
@ -91,12 +86,16 @@ SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH"); HttpRequestInput input(fullPath, "PATCH");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -108,6 +107,9 @@ SWGDefaultApi::instanceAudioPatch(SWGAudioDevicesSelect body) {
void void
SWGDefaultApi::instanceAudioPatchCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceAudioPatchCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -115,16 +117,15 @@ SWGDefaultApi::instanceAudioPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceAudioPatchSignal(output); emit instanceAudioPatchSignal(output);
emit instanceAudioPatchSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceChannels(bool tx) { SWGDefaultApi::instanceChannels(bool tx) {
QString fullPath; QString fullPath;
@ -143,10 +144,14 @@ SWGDefaultApi::instanceChannels(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -158,6 +163,9 @@ SWGDefaultApi::instanceChannels(bool tx) {
void void
SWGDefaultApi::instanceChannelsCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceChannelsCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -165,16 +173,15 @@ SWGDefaultApi::instanceChannelsCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceChannelsSignal(output); emit instanceChannelsSignal(output);
emit instanceChannelsSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceDVSerialPatch(bool dvserial) { SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
QString fullPath; QString fullPath;
@ -193,10 +200,14 @@ SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH"); HttpRequestInput input(fullPath, "PATCH");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -208,6 +219,9 @@ SWGDefaultApi::instanceDVSerialPatch(bool dvserial) {
void void
SWGDefaultApi::instanceDVSerialPatchCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceDVSerialPatchCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -215,16 +229,15 @@ SWGDefaultApi::instanceDVSerialPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceDVSerialPatchSignal(output); emit instanceDVSerialPatchSignal(output);
emit instanceDVSerialPatchSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceDeviceSetsDelete() { SWGDefaultApi::instanceDeviceSetsDelete() {
QString fullPath; QString fullPath;
@ -235,10 +248,14 @@ SWGDefaultApi::instanceDeviceSetsDelete() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "DELETE"); HttpRequestInput input(fullPath, "DELETE");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -250,6 +267,9 @@ SWGDefaultApi::instanceDeviceSetsDelete() {
void void
SWGDefaultApi::instanceDeviceSetsDeleteCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceDeviceSetsDeleteCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -257,16 +277,15 @@ SWGDefaultApi::instanceDeviceSetsDeleteCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceDeviceSetsDeleteSignal(output); emit instanceDeviceSetsDeleteSignal(output);
emit instanceDeviceSetsDeleteSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceDeviceSetsGet() { SWGDefaultApi::instanceDeviceSetsGet() {
QString fullPath; QString fullPath;
@ -277,10 +296,14 @@ SWGDefaultApi::instanceDeviceSetsGet() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -292,6 +315,9 @@ SWGDefaultApi::instanceDeviceSetsGet() {
void void
SWGDefaultApi::instanceDeviceSetsGetCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceDeviceSetsGetCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -299,16 +325,15 @@ SWGDefaultApi::instanceDeviceSetsGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceDeviceSetsGetSignal(output); emit instanceDeviceSetsGetSignal(output);
emit instanceDeviceSetsGetSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceDeviceSetsPost(bool tx) { SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
QString fullPath; QString fullPath;
@ -327,10 +352,14 @@ SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "POST"); HttpRequestInput input(fullPath, "POST");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -342,6 +371,9 @@ SWGDefaultApi::instanceDeviceSetsPost(bool tx) {
void void
SWGDefaultApi::instanceDeviceSetsPostCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceDeviceSetsPostCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -349,16 +381,15 @@ SWGDefaultApi::instanceDeviceSetsPostCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceDeviceSetsPostSignal(output); emit instanceDeviceSetsPostSignal(output);
emit instanceDeviceSetsPostSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceDevices(bool tx) { SWGDefaultApi::instanceDevices(bool tx) {
QString fullPath; QString fullPath;
@ -377,10 +408,14 @@ SWGDefaultApi::instanceDevices(bool tx) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -392,6 +427,9 @@ SWGDefaultApi::instanceDevices(bool tx) {
void void
SWGDefaultApi::instanceDevicesCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceDevicesCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -399,16 +437,15 @@ SWGDefaultApi::instanceDevicesCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceDevicesSignal(output); emit instanceDevicesSignal(output);
emit instanceDevicesSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceLocationGet() { SWGDefaultApi::instanceLocationGet() {
QString fullPath; QString fullPath;
@ -419,10 +456,14 @@ SWGDefaultApi::instanceLocationGet() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -434,6 +475,9 @@ SWGDefaultApi::instanceLocationGet() {
void void
SWGDefaultApi::instanceLocationGetCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceLocationGetCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -441,16 +485,15 @@ SWGDefaultApi::instanceLocationGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceLocationGetSignal(output); emit instanceLocationGetSignal(output);
emit instanceLocationGetSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) { SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
QString fullPath; QString fullPath;
@ -461,12 +504,16 @@ SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT"); HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -478,6 +525,9 @@ SWGDefaultApi::instanceLocationPut(SWGLocationInformation body) {
void void
SWGDefaultApi::instanceLocationPutCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceLocationPutCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -485,16 +535,15 @@ SWGDefaultApi::instanceLocationPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceLocationPutSignal(output); emit instanceLocationPutSignal(output);
emit instanceLocationPutSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceLoggingGet() { SWGDefaultApi::instanceLoggingGet() {
QString fullPath; QString fullPath;
@ -505,10 +554,14 @@ SWGDefaultApi::instanceLoggingGet() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -520,6 +573,9 @@ SWGDefaultApi::instanceLoggingGet() {
void void
SWGDefaultApi::instanceLoggingGetCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceLoggingGetCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -527,16 +583,15 @@ SWGDefaultApi::instanceLoggingGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceLoggingGetSignal(output); emit instanceLoggingGetSignal(output);
emit instanceLoggingGetSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) { SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
QString fullPath; QString fullPath;
@ -547,12 +602,16 @@ SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT"); HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -564,6 +623,9 @@ SWGDefaultApi::instanceLoggingPut(SWGLoggingInfo body) {
void void
SWGDefaultApi::instanceLoggingPutCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceLoggingPutCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -571,16 +633,15 @@ SWGDefaultApi::instanceLoggingPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceLoggingPutSignal(output); emit instanceLoggingPutSignal(output);
emit instanceLoggingPutSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) { SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
QString fullPath; QString fullPath;
@ -591,12 +652,16 @@ SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "DELETE"); HttpRequestInput input(fullPath, "DELETE");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -608,6 +673,9 @@ SWGDefaultApi::instancePresetDelete(SWGPresetIdentifier body) {
void void
SWGDefaultApi::instancePresetDeleteCallback(HttpRequestWorker * worker) { SWGDefaultApi::instancePresetDeleteCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -615,16 +683,15 @@ SWGDefaultApi::instancePresetDeleteCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instancePresetDeleteSignal(output); emit instancePresetDeleteSignal(output);
emit instancePresetDeleteSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instancePresetGet() { SWGDefaultApi::instancePresetGet() {
QString fullPath; QString fullPath;
@ -635,10 +702,14 @@ SWGDefaultApi::instancePresetGet() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -650,6 +721,9 @@ SWGDefaultApi::instancePresetGet() {
void void
SWGDefaultApi::instancePresetGetCallback(HttpRequestWorker * worker) { SWGDefaultApi::instancePresetGetCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -657,16 +731,15 @@ SWGDefaultApi::instancePresetGetCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instancePresetGetSignal(output); emit instancePresetGetSignal(output);
emit instancePresetGetSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) { SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
QString fullPath; QString fullPath;
@ -677,12 +750,16 @@ SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PATCH"); HttpRequestInput input(fullPath, "PATCH");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -694,6 +771,9 @@ SWGDefaultApi::instancePresetPatch(SWGPresetTransfer body) {
void void
SWGDefaultApi::instancePresetPatchCallback(HttpRequestWorker * worker) { SWGDefaultApi::instancePresetPatchCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -701,16 +781,15 @@ SWGDefaultApi::instancePresetPatchCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instancePresetPatchSignal(output); emit instancePresetPatchSignal(output);
emit instancePresetPatchSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) { SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
QString fullPath; QString fullPath;
@ -721,12 +800,16 @@ SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "POST"); HttpRequestInput input(fullPath, "POST");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -738,6 +821,9 @@ SWGDefaultApi::instancePresetPost(SWGPresetTransfer body) {
void void
SWGDefaultApi::instancePresetPostCallback(HttpRequestWorker * worker) { SWGDefaultApi::instancePresetPostCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -745,16 +831,15 @@ SWGDefaultApi::instancePresetPostCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instancePresetPostSignal(output); emit instancePresetPostSignal(output);
emit instancePresetPostSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) { SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
QString fullPath; QString fullPath;
@ -765,12 +850,16 @@ SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "PUT"); HttpRequestInput input(fullPath, "PUT");
QString output = body.asJson(); QString output = body.asJson();
input.request_body.append(output); input.request_body.append(output);
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -782,6 +871,9 @@ SWGDefaultApi::instancePresetPut(SWGPresetTransfer body) {
void void
SWGDefaultApi::instancePresetPutCallback(HttpRequestWorker * worker) { SWGDefaultApi::instancePresetPutCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -789,16 +881,15 @@ SWGDefaultApi::instancePresetPutCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instancePresetPutSignal(output); emit instancePresetPutSignal(output);
emit instancePresetPutSignalE(output, error_type, error_str);
} }
void void
SWGDefaultApi::instanceSummary() { SWGDefaultApi::instanceSummary() {
QString fullPath; QString fullPath;
@ -809,10 +900,14 @@ SWGDefaultApi::instanceSummary() {
HttpRequestWorker *worker = new HttpRequestWorker(); HttpRequestWorker *worker = new HttpRequestWorker();
HttpRequestInput input(fullPath, "GET"); HttpRequestInput input(fullPath, "GET");
foreach(QString key, this->defaultHeaders.keys()) {
input.headers.insert(key, this->defaultHeaders.value(key));
}
connect(worker, connect(worker,
&HttpRequestWorker::on_execution_finished, &HttpRequestWorker::on_execution_finished,
this, this,
@ -824,6 +919,9 @@ SWGDefaultApi::instanceSummary() {
void void
SWGDefaultApi::instanceSummaryCallback(HttpRequestWorker * worker) { SWGDefaultApi::instanceSummaryCallback(HttpRequestWorker * worker) {
QString msg; QString msg;
QString error_str = worker->error_str;
QNetworkReply::NetworkError error_type = worker->error_type;
if (worker->error_type == QNetworkReply::NoError) { if (worker->error_type == QNetworkReply::NoError) {
msg = QString("Success! %1 bytes").arg(worker->response.length()); msg = QString("Success! %1 bytes").arg(worker->response.length());
} }
@ -831,14 +929,14 @@ SWGDefaultApi::instanceSummaryCallback(HttpRequestWorker * worker) {
msg = "Error: " + worker->error_str; 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(); worker->deleteLater();
emit instanceSummarySignal(output); 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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_ #ifndef _SWG_SWGDefaultApi_H_
@ -27,20 +15,20 @@
#include "SWGHttpRequest.h" #include "SWGHttpRequest.h"
#include "SWGErrorResponse.h"
#include "SWGAudioDevices.h" #include "SWGAudioDevices.h"
#include "SWGAudioDevicesSelect.h" #include "SWGAudioDevicesSelect.h"
#include "SWGInstanceChannelsResponse.h"
#include "SWGDVSeralDevices.h" #include "SWGDVSeralDevices.h"
#include "SWGDeviceSetList.h"
#include "SWGDeviceSet.h" #include "SWGDeviceSet.h"
#include "SWGDeviceSetList.h"
#include "SWGErrorResponse.h"
#include "SWGInstanceChannelsResponse.h"
#include "SWGInstanceDevicesResponse.h" #include "SWGInstanceDevicesResponse.h"
#include "SWGInstanceSummaryResponse.h"
#include "SWGLocationInformation.h" #include "SWGLocationInformation.h"
#include "SWGLoggingInfo.h" #include "SWGLoggingInfo.h"
#include "SWGPresetIdentifier.h" #include "SWGPresetIdentifier.h"
#include "SWGPresets.h"
#include "SWGPresetTransfer.h" #include "SWGPresetTransfer.h"
#include "SWGInstanceSummaryResponse.h" #include "SWGPresets.h"
#include <QObject> #include <QObject>
@ -56,6 +44,7 @@ public:
QString host; QString host;
QString basePath; QString basePath;
QMap<QString, QString> defaultHeaders;
void instanceAudioGet(); void instanceAudioGet();
void instanceAudioPatch(SWGAudioDevicesSelect body); void instanceAudioPatch(SWGAudioDevicesSelect body);
@ -116,6 +105,26 @@ signals:
void instancePresetPutSignal(SWGPresetIdentifier* summary); void instancePresetPutSignal(SWGPresetIdentifier* summary);
void instanceSummarySignal(SWGInstanceSummaryResponse* 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 #endif

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGDeviceListItem::SWGDeviceListItem(QString* json) { SWGDeviceListItem::SWGDeviceListItem(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,24 +37,26 @@ SWGDeviceListItem::~SWGDeviceListItem() {
void void
SWGDeviceListItem::init() { SWGDeviceListItem::init() {
hwType = new QString(""); hw_type = new QString("");
tx = false; tx = false;
nbStreams = NULL; nb_streams = 0;
streamIndex = NULL; stream_index = 0;
sequence = NULL; sequence = 0;
serial = new QString(""); serial = new QString("");
} }
void void
SWGDeviceListItem::cleanup() { SWGDeviceListItem::cleanup() {
if(hwType != NULL) {
delete hwType; if(hw_type != nullptr) {
delete hw_type;
} }
if(serial != NULL) {
if(serial != nullptr) {
delete serial; delete serial;
} }
} }
@ -83,12 +72,12 @@ SWGDeviceListItem::fromJson(QString &json) {
void void
SWGDeviceListItem::fromJsonObject(QJsonObject &pJson) { SWGDeviceListItem::fromJsonObject(QJsonObject &pJson) {
setValue(&hwType, pJson["hwType"], "QString", "QString"); ::Swagger::setValue(&hw_type, pJson["hwType"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", ""); ::Swagger::setValue(&tx, pJson["tx"], "bool", "");
setValue(&nbStreams, pJson["nbStreams"], "qint32", ""); ::Swagger::setValue(&nb_streams, pJson["nbStreams"], "qint32", "");
setValue(&streamIndex, pJson["streamIndex"], "qint32", ""); ::Swagger::setValue(&stream_index, pJson["streamIndex"], "qint32", "");
setValue(&sequence, pJson["sequence"], "qint32", ""); ::Swagger::setValue(&sequence, pJson["sequence"], "qint32", "");
setValue(&serial, pJson["serial"], "QString", "QString"); ::Swagger::setValue(&serial, pJson["serial"], "QString", "QString");
} }
QString QString
@ -105,30 +94,28 @@ QJsonObject*
SWGDeviceListItem::asJsonObject() { SWGDeviceListItem::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("hwType"), hw_type, obj, QString("QString"));
toJsonValue(QString("hwType"), hwType, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("tx", QJsonValue(tx)); obj->insert("nbStreams", QJsonValue(nb_streams));
obj->insert("nbStreams", QJsonValue(nbStreams));
obj->insert("streamIndex", QJsonValue(streamIndex)); obj->insert("streamIndex", QJsonValue(stream_index));
obj->insert("sequence", QJsonValue(sequence));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("serial"), serial, obj, QString("QString")); toJsonValue(QString("serial"), serial, obj, QString("QString"));
return obj; return obj;
} }
QString* QString*
SWGDeviceListItem::getHwType() { SWGDeviceListItem::getHwType() {
return hwType; return hw_type;
} }
void void
SWGDeviceListItem::setHwType(QString* hwType) { SWGDeviceListItem::setHwType(QString* hw_type) {
this->hwType = hwType; this->hw_type = hw_type;
} }
bool bool
@ -142,20 +129,20 @@ SWGDeviceListItem::setTx(bool tx) {
qint32 qint32
SWGDeviceListItem::getNbStreams() { SWGDeviceListItem::getNbStreams() {
return nbStreams; return nb_streams;
} }
void void
SWGDeviceListItem::setNbStreams(qint32 nbStreams) { SWGDeviceListItem::setNbStreams(qint32 nb_streams) {
this->nbStreams = nbStreams; this->nb_streams = nb_streams;
} }
qint32 qint32
SWGDeviceListItem::getStreamIndex() { SWGDeviceListItem::getStreamIndex() {
return streamIndex; return stream_index;
} }
void void
SWGDeviceListItem::setStreamIndex(qint32 streamIndex) { SWGDeviceListItem::setStreamIndex(qint32 stream_index) {
this->streamIndex = streamIndex; this->stream_index = stream_index;
} }
qint32 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGDeviceListItem* fromJson(QString &jsonString);
QString* getHwType(); QString* getHwType();
void setHwType(QString* hwType); void setHwType(QString* hw_type);
bool getTx();
bool getTx();
void setTx(bool tx); void setTx(bool tx);
qint32 getNbStreams();
void setNbStreams(qint32 nbStreams); qint32 getNbStreams();
qint32 getStreamIndex(); void setNbStreams(qint32 nb_streams);
void setStreamIndex(qint32 streamIndex);
qint32 getSequence(); qint32 getStreamIndex();
void setStreamIndex(qint32 stream_index);
qint32 getSequence();
void setSequence(qint32 sequence); void setSequence(qint32 sequence);
QString* getSerial();
QString* getSerial();
void setSerial(QString* serial); void setSerial(QString* serial);
private: private:
QString* hwType; QString* hw_type;
bool tx; bool tx;
qint32 nbStreams; qint32 nb_streams;
qint32 streamIndex; qint32 stream_index;
qint32 sequence; qint32 sequence;
QString* serial; QString* serial;
}; };
} /* namespace Swagger */ }
#endif /* SWGDeviceListItem_H_ */ #endif /* SWGDeviceListItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGDeviceSet::SWGDeviceSet(QString* json) { SWGDeviceSet::SWGDeviceSet(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,18 +37,20 @@ SWGDeviceSet::~SWGDeviceSet() {
void void
SWGDeviceSet::init() { SWGDeviceSet::init() {
samplingDevice = new SWGSamplingDevice(); sampling_device = new SWGSamplingDevice();
channelcount = NULL; channelcount = 0;
channels = new QList<SWGChannel*>(); channels = new QList<SWGChannel*>();
} }
void void
SWGDeviceSet::cleanup() { SWGDeviceSet::cleanup() {
if(samplingDevice != NULL) {
delete samplingDevice; if(sampling_device != nullptr) {
delete sampling_device;
} }
if(channels != NULL) {
if(channels != nullptr) {
QList<SWGChannel*>* arr = channels; QList<SWGChannel*>* arr = channels;
foreach(SWGChannel* o, *arr) { foreach(SWGChannel* o, *arr) {
delete o; delete o;
@ -81,9 +70,11 @@ SWGDeviceSet::fromJson(QString &json) {
void void
SWGDeviceSet::fromJsonObject(QJsonObject &pJson) { SWGDeviceSet::fromJsonObject(QJsonObject &pJson) {
setValue(&samplingDevice, pJson["samplingDevice"], "SWGSamplingDevice", "SWGSamplingDevice"); ::Swagger::setValue(&sampling_device, pJson["samplingDevice"], "SWGSamplingDevice", "SWGSamplingDevice");
setValue(&channelcount, pJson["channelcount"], "qint32", ""); ::Swagger::setValue(&channelcount, pJson["channelcount"], "qint32", "");
setValue(&channels, pJson["channels"], "QList", "SWGChannel");
::Swagger::setValue(&channels, pJson["channels"], "QList", "SWGChannel");
} }
QString QString
@ -100,30 +91,24 @@ QJsonObject*
SWGDeviceSet::asJsonObject() { SWGDeviceSet::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("samplingDevice"), sampling_device, obj, QString("SWGSamplingDevice"));
toJsonValue(QString("samplingDevice"), samplingDevice, obj, QString("SWGSamplingDevice"));
obj->insert("channelcount", QJsonValue(channelcount));
obj->insert("channelcount", QJsonValue(channelcount));
QList<SWGChannel*>* channelsList = channels;
QJsonArray channelsJsonArray; QJsonArray channelsJsonArray;
toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannel"); toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannel");
obj->insert("channels", channelsJsonArray); obj->insert("channels", channelsJsonArray);
return obj; return obj;
} }
SWGSamplingDevice* SWGSamplingDevice*
SWGDeviceSet::getSamplingDevice() { SWGDeviceSet::getSamplingDevice() {
return samplingDevice; return sampling_device;
} }
void void
SWGDeviceSet::setSamplingDevice(SWGSamplingDevice* samplingDevice) { SWGDeviceSet::setSamplingDevice(SWGSamplingDevice* sampling_device) {
this->samplingDevice = samplingDevice; this->sampling_device = sampling_device;
} }
qint32 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGDeviceSet* fromJson(QString &jsonString);
SWGSamplingDevice* getSamplingDevice(); SWGSamplingDevice* getSamplingDevice();
void setSamplingDevice(SWGSamplingDevice* samplingDevice); void setSamplingDevice(SWGSamplingDevice* sampling_device);
qint32 getChannelcount();
qint32 getChannelcount();
void setChannelcount(qint32 channelcount); void setChannelcount(qint32 channelcount);
QList<SWGChannel*>* getChannels();
QList<SWGChannel*>* getChannels();
void setChannels(QList<SWGChannel*>* channels); void setChannels(QList<SWGChannel*>* channels);
private: private:
SWGSamplingDevice* samplingDevice; SWGSamplingDevice* sampling_device;
qint32 channelcount; qint32 channelcount;
QList<SWGChannel*>* channels; QList<SWGChannel*>* channels;
}; };
} /* namespace Swagger */ }
#endif /* SWGDeviceSet_H_ */ #endif /* SWGDeviceSet_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGDeviceSetList::SWGDeviceSetList(QString* json) { SWGDeviceSetList::SWGDeviceSetList(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,19 +37,20 @@ SWGDeviceSetList::~SWGDeviceSetList() {
void void
SWGDeviceSetList::init() { SWGDeviceSetList::init() {
devicesetcount = NULL; devicesetcount = 0;
deviceSets = new QList<SWGDeviceSet*>(); device_sets = new QList<SWGDeviceSet*>();
} }
void void
SWGDeviceSetList::cleanup() { SWGDeviceSetList::cleanup() {
if(deviceSets != NULL) {
QList<SWGDeviceSet*>* arr = deviceSets; if(device_sets != nullptr) {
QList<SWGDeviceSet*>* arr = device_sets;
foreach(SWGDeviceSet* o, *arr) { foreach(SWGDeviceSet* o, *arr) {
delete o; delete o;
} }
delete deviceSets; delete device_sets;
} }
} }
@ -77,8 +65,10 @@ SWGDeviceSetList::fromJson(QString &json) {
void void
SWGDeviceSetList::fromJsonObject(QJsonObject &pJson) { SWGDeviceSetList::fromJsonObject(QJsonObject &pJson) {
setValue(&devicesetcount, pJson["devicesetcount"], "qint32", ""); ::Swagger::setValue(&devicesetcount, pJson["devicesetcount"], "qint32", "");
setValue(&deviceSets, pJson["deviceSets"], "QList", "SWGDeviceSet");
::Swagger::setValue(&device_sets, pJson["deviceSets"], "QList", "SWGDeviceSet");
} }
QString QString
@ -94,15 +84,12 @@ SWGDeviceSetList::asJson ()
QJsonObject* QJsonObject*
SWGDeviceSetList::asJsonObject() { SWGDeviceSetList::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("devicesetcount", QJsonValue(devicesetcount)); obj->insert("devicesetcount", QJsonValue(devicesetcount));
QJsonArray device_setsJsonArray;
QList<SWGDeviceSet*>* deviceSetsList = deviceSets; toJsonArray((QList<void*>*)device_sets, &device_setsJsonArray, "device_sets", "SWGDeviceSet");
QJsonArray deviceSetsJsonArray; obj->insert("deviceSets", device_setsJsonArray);
toJsonArray((QList<void*>*)deviceSets, &deviceSetsJsonArray, "deviceSets", "SWGDeviceSet");
obj->insert("deviceSets", deviceSetsJsonArray);
return obj; return obj;
} }
@ -118,14 +105,13 @@ SWGDeviceSetList::setDevicesetcount(qint32 devicesetcount) {
QList<SWGDeviceSet*>* QList<SWGDeviceSet*>*
SWGDeviceSetList::getDeviceSets() { SWGDeviceSetList::getDeviceSets() {
return deviceSets; return device_sets;
} }
void void
SWGDeviceSetList::setDeviceSets(QList<SWGDeviceSet*>* deviceSets) { SWGDeviceSetList::setDeviceSets(QList<SWGDeviceSet*>* device_sets) {
this->deviceSets = deviceSets; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getDevicesetcount();
void setDevicesetcount(qint32 devicesetcount); void setDevicesetcount(qint32 devicesetcount);
QList<SWGDeviceSet*>* getDeviceSets();
void setDeviceSets(QList<SWGDeviceSet*>* deviceSets); QList<SWGDeviceSet*>* getDeviceSets();
void setDeviceSets(QList<SWGDeviceSet*>* device_sets);
private: private:
qint32 devicesetcount; qint32 devicesetcount;
QList<SWGDeviceSet*>* deviceSets; QList<SWGDeviceSet*>* device_sets;
}; };
} /* namespace Swagger */ }
#endif /* SWGDeviceSetList_H_ */ #endif /* SWGDeviceSetList_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGErrorResponse::SWGErrorResponse(QString* json) { SWGErrorResponse::SWGErrorResponse(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -55,7 +42,8 @@ SWGErrorResponse::init() {
void void
SWGErrorResponse::cleanup() { SWGErrorResponse::cleanup() {
if(message != NULL) {
if(message != nullptr) {
delete message; delete message;
} }
} }
@ -71,7 +59,7 @@ SWGErrorResponse::fromJson(QString &json) {
void void
SWGErrorResponse::fromJsonObject(QJsonObject &pJson) { SWGErrorResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&message, pJson["message"], "QString", "QString"); ::Swagger::setValue(&message, pJson["message"], "QString", "QString");
} }
QString QString
@ -88,10 +76,7 @@ QJsonObject*
SWGErrorResponse::asJsonObject() { SWGErrorResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("message"), message, obj, QString("QString")); toJsonValue(QString("message"), message, obj, QString("QString"));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); QString* getMessage();
void setMessage(QString* message); void setMessage(QString* message);
private: private:
QString* message; QString* message;
}; };
} /* namespace Swagger */ }
#endif /* SWGErrorResponse_H_ */ #endif /* SWGErrorResponse_H_ */

View File

@ -1,4 +1,3 @@
#include <QDateTime>
/** /**
* SDRangel * 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 * 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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" #include "SWGHelpers.h"
@ -29,12 +16,14 @@
#include <QDebug> #include <QDebug>
#include <QJsonArray> #include <QJsonArray>
#include <QJsonValue> #include <QJsonValue>
#include <QDateTime>
namespace Swagger { namespace Swagger {
void void
setValue(void* value, QJsonValue obj, QString type, QString complexType) { setValue(void* value, QJsonValue obj, QString type, QString complexType) {
if(value == NULL) { if(value == nullptr) {
// can't set value with a null pointer // can't set value with a null pointer
return; return;
} }
@ -61,7 +50,7 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
else if (QStringLiteral("QString").compare(type) == 0) { else if (QStringLiteral("QString").compare(type) == 0) {
QString **val = static_cast<QString**>(value); QString **val = static_cast<QString**>(value);
if(val != NULL) { if(val != nullptr) {
if(!obj.isNull()) { if(!obj.isNull()) {
// create a new value and return // create a new value and return
delete *val; delete *val;
@ -69,19 +58,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return; return;
} }
else { else {
// set target to NULL // set target to nullptr
delete *val; delete *val;
*val = NULL; *val = nullptr;
} }
} }
else { 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) { else if (QStringLiteral("QDateTime").compare(type) == 0) {
QDateTime **val = static_cast<QDateTime**>(value); QDateTime **val = static_cast<QDateTime**>(value);
if(val != NULL) { if(val != nullptr) {
if(!obj.isNull()) { if(!obj.isNull()) {
// create a new value and return // create a new value and return
delete *val; delete *val;
@ -89,19 +78,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return; return;
} }
else { else {
// set target to NULL // set target to nullptr
delete *val; delete *val;
*val = NULL; *val = nullptr;
} }
} }
else { 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) { else if (QStringLiteral("QDate").compare(type) == 0) {
QDate **val = static_cast<QDate**>(value); QDate **val = static_cast<QDate**>(value);
if(val != NULL) { if(val != nullptr) {
if(!obj.isNull()) { if(!obj.isNull()) {
// create a new value and return // create a new value and return
delete *val; delete *val;
@ -109,19 +98,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return; return;
} }
else { else {
// set target to NULL // set target to nullptr
delete *val; delete *val;
*val = NULL; *val = nullptr;
} }
} }
else { 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) { else if (QStringLiteral("QByteArray").compare(type) == 0) {
QByteArray **val = static_cast<QByteArray**>(value); QByteArray **val = static_cast<QByteArray**>(value);
if(val != NULL) { if(val != nullptr) {
if(!obj.isNull()) { if(!obj.isNull()) {
// create a new value and return // create a new value and return
delete *val; delete *val;
@ -130,20 +119,20 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
return; return;
} }
else { else {
// set target to NULL // set target to nullptr
delete *val; delete *val;
*val = NULL; *val = nullptr;
} }
} }
else { 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()) { else if(type.startsWith("SWG") && obj.isObject()) {
// complex type // complex type
QJsonObject jsonObj = obj.toObject(); QJsonObject jsonObj = obj.toObject();
SWGObject * so = (SWGObject*)Swagger::create(type); SWGObject * so = (SWGObject*)::Swagger::create(type);
if(so != NULL) { if(so != nullptr) {
so->fromJsonObject(jsonObj); so->fromJsonObject(jsonObj);
SWGObject **val = static_cast<SWGObject**>(value); SWGObject **val = static_cast<SWGObject**>(value);
delete *val; delete *val;
@ -191,19 +180,19 @@ setValue(void* value, QJsonValue obj, QString type, QString complexType) {
output->append((void*)&val); output->append((void*)&val);
} }
else if(QStringLiteral("QString").compare(complexType) == 0) { else if(QStringLiteral("QString").compare(complexType) == 0) {
QString val; QString * val = new QString();
setValue(&val, jval, QStringLiteral("QString"), QStringLiteral("")); setValue(&val, jval, QStringLiteral("QString"), QStringLiteral(""));
output->append((void*)&val); output->append((void*)val);
} }
else if(QStringLiteral("QDate").compare(complexType) == 0) { else if(QStringLiteral("QDate").compare(complexType) == 0) {
QDate val; QDate * val = new QDate();
setValue(&val, jval, QStringLiteral("QDate"), QStringLiteral("")); setValue(&val, jval, QStringLiteral("QDate"), QStringLiteral(""));
output->append((void*)&val); output->append((void*)val);
} }
else if(QStringLiteral("QDateTime").compare(complexType) == 0) { else if(QStringLiteral("QDateTime").compare(complexType) == 0) {
QDateTime val; QDateTime * val = new QDateTime();
setValue(&val, jval, QStringLiteral("QDateTime"), QStringLiteral("")); 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 void
toJsonValue(QString name, void* value, QJsonObject* output, QString type) { toJsonValue(QString name, void* value, QJsonObject* output, QString type) {
if(value == NULL) { if(value == nullptr) {
return; return;
} }
if(type.startsWith("SWG")) { if(type.startsWith("SWG")) {
SWGObject *swgObject = reinterpret_cast<SWGObject *>(value); SWGObject *swgObject = reinterpret_cast<SWGObject *>(value);
if(swgObject != NULL) { if(swgObject != nullptr) {
QJsonObject* o = (*swgObject).asJsonObject(); QJsonObject* o = (*swgObject).asJsonObject();
if(name != NULL) { if(name != nullptr) {
output->insert(name, *o); output->insert(name, *o);
delete o; delete o;
} }
@ -277,7 +266,7 @@ toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString
foreach(void* obj, *value) { foreach(void* obj, *value) {
QJsonObject element; QJsonObject element;
toJsonValue(NULL, obj, &element, innerType); toJsonValue(nullptr, obj, &element, innerType);
output->append(element); output->append(element);
} }
} }
@ -302,4 +291,5 @@ QString
stringValue(bool value) { stringValue(bool value) {
return QString(value ? "true" : "false"); 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 #ifndef SWGHELPERS_H
@ -28,6 +16,7 @@
#include <QJsonValue> #include <QJsonValue>
namespace Swagger { namespace Swagger {
void setValue(void* value, QJsonValue obj, QString type, QString complexType); void setValue(void* value, QJsonValue obj, QString type, QString complexType);
void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType); void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType);
void toJsonValue(QString name, void* value, QJsonObject* output, QString type); void toJsonValue(QString name, void* value, QJsonObject* output, QString type);
@ -36,6 +25,7 @@ namespace Swagger {
QString stringValue(qint32 value); QString stringValue(qint32 value);
QString stringValue(qint64 value); QString stringValue(qint64 value);
QString stringValue(bool value); QString stringValue(bool value);
} }
#endif // SWGHELPERS_H #endif // SWGHELPERS_H

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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" #include "SWGHttpRequest.h"
@ -27,8 +15,11 @@
#include <QUrl> #include <QUrl>
#include <QFileInfo> #include <QFileInfo>
#include <QBuffer> #include <QBuffer>
#include <QtGlobal>
namespace Swagger {
HttpRequestInput::HttpRequestInput() { HttpRequestInput::HttpRequestInput() {
initialize(); initialize();
} }
@ -60,7 +51,7 @@ void HttpRequestInput::add_file(QString variable_name, QString local_filename, Q
HttpRequestWorker::HttpRequestWorker(QObject *parent) HttpRequestWorker::HttpRequestWorker(QObject *parent)
: QObject(parent), manager(NULL) : QObject(parent), manager(nullptr)
{ {
qsrand(QDateTime::currentDateTime().toTime_t()); qsrand(QDateTime::currentDateTime().toTime_t());
@ -204,8 +195,8 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
// ensure necessary variables are available // ensure necessary variables are available
if ( if (
file_info->local_filename == NULL || file_info->local_filename.isEmpty() file_info->local_filename == nullptr || file_info->local_filename.isEmpty()
|| file_info->variable_name == NULL || file_info->variable_name.isEmpty() || file_info->variable_name == nullptr || file_info->variable_name.isEmpty()
|| !fi.exists() || !fi.isFile() || !fi.isReadable() || !fi.exists() || !fi.isFile() || !fi.isReadable()
) { ) {
// silent abort for the current file // silent abort for the current file
@ -219,7 +210,7 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
} }
// ensure filename for the request // 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(); file_info->request_filename = fi.fileName();
if (file_info->request_filename.isEmpty()) { if (file_info->request_filename.isEmpty()) {
file_info->request_filename = "file"; file_info->request_filename = "file";
@ -238,7 +229,7 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
)); ));
request_content.append(new_line); 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("Content-Type: ");
request_content.append(file_info->mime_type); request_content.append(file_info->mime_type);
request_content.append(new_line); request_content.append(new_line);
@ -302,8 +293,16 @@ void HttpRequestWorker::execute(HttpRequestInput *input) {
manager->deleteResource(request); manager->deleteResource(request);
} }
else { else {
QBuffer buff(&request_content); #if (QT_VERSION >= 0x050800)
manager->sendCustomRequest(request, input->http_method.toLatin1(), &buff); 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); emit on_execution_finished(this);
} }
}

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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}; enum HttpRequestVarLayout {NOT_SET, ADDRESS, URL_ENCODED, MULTIPART};
namespace Swagger {
class SWGHttpRequestInputFileElement { class SWGHttpRequestInputFileElement {
@ -96,4 +85,6 @@ private slots:
}; };
}
#endif // HTTPREQUESTWORKER_H #endif // HTTPREQUESTWORKER_H

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGInstanceChannelsResponse::SWGInstanceChannelsResponse(QString* json) { SWGInstanceChannelsResponse::SWGInstanceChannelsResponse(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,14 +37,15 @@ SWGInstanceChannelsResponse::~SWGInstanceChannelsResponse() {
void void
SWGInstanceChannelsResponse::init() { SWGInstanceChannelsResponse::init() {
channelcount = NULL; channelcount = 0;
channels = new QList<SWGChannelListItem*>(); channels = new QList<SWGChannelListItem*>();
} }
void void
SWGInstanceChannelsResponse::cleanup() { SWGInstanceChannelsResponse::cleanup() {
if(channels != NULL) {
if(channels != nullptr) {
QList<SWGChannelListItem*>* arr = channels; QList<SWGChannelListItem*>* arr = channels;
foreach(SWGChannelListItem* o, *arr) { foreach(SWGChannelListItem* o, *arr) {
delete o; delete o;
@ -77,8 +65,10 @@ SWGInstanceChannelsResponse::fromJson(QString &json) {
void void
SWGInstanceChannelsResponse::fromJsonObject(QJsonObject &pJson) { SWGInstanceChannelsResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&channelcount, pJson["channelcount"], "qint32", ""); ::Swagger::setValue(&channelcount, pJson["channelcount"], "qint32", "");
setValue(&channels, pJson["channels"], "QList", "SWGChannelListItem");
::Swagger::setValue(&channels, pJson["channels"], "QList", "SWGChannelListItem");
} }
QString QString
@ -94,15 +84,12 @@ SWGInstanceChannelsResponse::asJson ()
QJsonObject* QJsonObject*
SWGInstanceChannelsResponse::asJsonObject() { SWGInstanceChannelsResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("channelcount", QJsonValue(channelcount)); obj->insert("channelcount", QJsonValue(channelcount));
QList<SWGChannelListItem*>* channelsList = channels;
QJsonArray channelsJsonArray; QJsonArray channelsJsonArray;
toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannelListItem"); toJsonArray((QList<void*>*)channels, &channelsJsonArray, "channels", "SWGChannelListItem");
obj->insert("channels", channelsJsonArray); obj->insert("channels", channelsJsonArray);
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getChannelcount();
void setChannelcount(qint32 channelcount); void setChannelcount(qint32 channelcount);
QList<SWGChannelListItem*>* getChannels();
QList<SWGChannelListItem*>* getChannels();
void setChannels(QList<SWGChannelListItem*>* channels); void setChannels(QList<SWGChannelListItem*>* channels);
private: private:
qint32 channelcount; qint32 channelcount;
QList<SWGChannelListItem*>* channels; QList<SWGChannelListItem*>* channels;
}; };
} /* namespace Swagger */ }
#endif /* SWGInstanceChannelsResponse_H_ */ #endif /* SWGInstanceChannelsResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGInstanceDevicesResponse::SWGInstanceDevicesResponse(QString* json) { SWGInstanceDevicesResponse::SWGInstanceDevicesResponse(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,14 +37,15 @@ SWGInstanceDevicesResponse::~SWGInstanceDevicesResponse() {
void void
SWGInstanceDevicesResponse::init() { SWGInstanceDevicesResponse::init() {
devicecount = NULL; devicecount = 0;
devices = new QList<SWGDeviceListItem*>(); devices = new QList<SWGDeviceListItem*>();
} }
void void
SWGInstanceDevicesResponse::cleanup() { SWGInstanceDevicesResponse::cleanup() {
if(devices != NULL) {
if(devices != nullptr) {
QList<SWGDeviceListItem*>* arr = devices; QList<SWGDeviceListItem*>* arr = devices;
foreach(SWGDeviceListItem* o, *arr) { foreach(SWGDeviceListItem* o, *arr) {
delete o; delete o;
@ -77,8 +65,10 @@ SWGInstanceDevicesResponse::fromJson(QString &json) {
void void
SWGInstanceDevicesResponse::fromJsonObject(QJsonObject &pJson) { SWGInstanceDevicesResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&devicecount, pJson["devicecount"], "qint32", ""); ::Swagger::setValue(&devicecount, pJson["devicecount"], "qint32", "");
setValue(&devices, pJson["devices"], "QList", "SWGDeviceListItem");
::Swagger::setValue(&devices, pJson["devices"], "QList", "SWGDeviceListItem");
} }
QString QString
@ -94,15 +84,12 @@ SWGInstanceDevicesResponse::asJson ()
QJsonObject* QJsonObject*
SWGInstanceDevicesResponse::asJsonObject() { SWGInstanceDevicesResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("devicecount", QJsonValue(devicecount)); obj->insert("devicecount", QJsonValue(devicecount));
QList<SWGDeviceListItem*>* devicesList = devices;
QJsonArray devicesJsonArray; QJsonArray devicesJsonArray;
toJsonArray((QList<void*>*)devices, &devicesJsonArray, "devices", "SWGDeviceListItem"); toJsonArray((QList<void*>*)devices, &devicesJsonArray, "devices", "SWGDeviceListItem");
obj->insert("devices", devicesJsonArray); obj->insert("devices", devicesJsonArray);
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getDevicecount();
void setDevicecount(qint32 devicecount); void setDevicecount(qint32 devicecount);
QList<SWGDeviceListItem*>* getDevices();
QList<SWGDeviceListItem*>* getDevices();
void setDevices(QList<SWGDeviceListItem*>* devices); void setDevices(QList<SWGDeviceListItem*>* devices);
private: private:
qint32 devicecount; qint32 devicecount;
QList<SWGDeviceListItem*>* devices; QList<SWGDeviceListItem*>* devices;
}; };
} /* namespace Swagger */ }
#endif /* SWGInstanceDevicesResponse_H_ */ #endif /* SWGInstanceDevicesResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGInstanceSummaryResponse::SWGInstanceSummaryResponse(QString* json) { SWGInstanceSummaryResponse::SWGInstanceSummaryResponse(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -51,23 +38,27 @@ SWGInstanceSummaryResponse::~SWGInstanceSummaryResponse() {
void void
SWGInstanceSummaryResponse::init() { SWGInstanceSummaryResponse::init() {
version = new QString(""); version = new QString("");
logging = new SWGLoggingInfo(); logging = new SWGLoggingInfo();
devicesetlist = new SWGDeviceSetList(); devicesetlist = new SWGDeviceSetList();
user = new SWGUser(); user = new SWGUser();
} }
void void
SWGInstanceSummaryResponse::cleanup() { SWGInstanceSummaryResponse::cleanup() {
if(version != NULL) {
if(version != nullptr) {
delete version; delete version;
} }
if(logging != NULL) {
if(logging != nullptr) {
delete logging; delete logging;
} }
if(devicesetlist != NULL) {
if(devicesetlist != nullptr) {
delete devicesetlist; delete devicesetlist;
} }
if(user != NULL) {
if(user != nullptr) {
delete user; delete user;
} }
} }
@ -83,10 +74,10 @@ SWGInstanceSummaryResponse::fromJson(QString &json) {
void void
SWGInstanceSummaryResponse::fromJsonObject(QJsonObject &pJson) { SWGInstanceSummaryResponse::fromJsonObject(QJsonObject &pJson) {
setValue(&version, pJson["version"], "QString", "QString"); ::Swagger::setValue(&version, pJson["version"], "QString", "QString");
setValue(&logging, pJson["logging"], "SWGLoggingInfo", "SWGLoggingInfo"); ::Swagger::setValue(&logging, pJson["logging"], "SWGLoggingInfo", "SWGLoggingInfo");
setValue(&devicesetlist, pJson["devicesetlist"], "SWGDeviceSetList", "SWGDeviceSetList"); ::Swagger::setValue(&devicesetlist, pJson["devicesetlist"], "SWGDeviceSetList", "SWGDeviceSetList");
setValue(&user, pJson["user"], "SWGUser", "SWGUser"); ::Swagger::setValue(&user, pJson["user"], "SWGUser", "SWGUser");
} }
QString QString
@ -103,25 +94,13 @@ QJsonObject*
SWGInstanceSummaryResponse::asJsonObject() { SWGInstanceSummaryResponse::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("version"), version, obj, QString("QString")); toJsonValue(QString("version"), version, obj, QString("QString"));
toJsonValue(QString("logging"), logging, obj, QString("SWGLoggingInfo")); toJsonValue(QString("logging"), logging, obj, QString("SWGLoggingInfo"));
toJsonValue(QString("devicesetlist"), devicesetlist, obj, QString("SWGDeviceSetList")); toJsonValue(QString("devicesetlist"), devicesetlist, obj, QString("SWGDeviceSetList"));
toJsonValue(QString("user"), user, obj, QString("SWGUser")); toJsonValue(QString("user"), user, obj, QString("SWGUser"));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); QString* getVersion();
void setVersion(QString* version); void setVersion(QString* version);
SWGLoggingInfo* getLogging();
SWGLoggingInfo* getLogging();
void setLogging(SWGLoggingInfo* logging); void setLogging(SWGLoggingInfo* logging);
SWGDeviceSetList* getDevicesetlist();
SWGDeviceSetList* getDevicesetlist();
void setDevicesetlist(SWGDeviceSetList* devicesetlist); void setDevicesetlist(SWGDeviceSetList* devicesetlist);
SWGUser* getUser();
SWGUser* getUser();
void setUser(SWGUser* user); void setUser(SWGUser* user);
private: private:
QString* version; QString* version;
SWGLoggingInfo* logging; SWGLoggingInfo* logging;
SWGDeviceSetList* devicesetlist; SWGDeviceSetList* devicesetlist;
SWGUser* user; SWGUser* user;
}; };
} /* namespace Swagger */ }
#endif /* SWGInstanceSummaryResponse_H_ */ #endif /* SWGInstanceSummaryResponse_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGLocationInformation::SWGLocationInformation(QString* json) { SWGLocationInformation::SWGLocationInformation(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -51,7 +38,7 @@ SWGLocationInformation::~SWGLocationInformation() {
void void
SWGLocationInformation::init() { SWGLocationInformation::init() {
latitude = 0.0f; latitude = 0.0f;
longitude = 0.0f; longitude = 0.0f;
} }
void void
@ -71,8 +58,8 @@ SWGLocationInformation::fromJson(QString &json) {
void void
SWGLocationInformation::fromJsonObject(QJsonObject &pJson) { SWGLocationInformation::fromJsonObject(QJsonObject &pJson) {
setValue(&latitude, pJson["latitude"], "float", ""); ::Swagger::setValue(&latitude, pJson["latitude"], "float", "");
setValue(&longitude, pJson["longitude"], "float", ""); ::Swagger::setValue(&longitude, pJson["longitude"], "float", "");
} }
QString QString
@ -88,8 +75,10 @@ SWGLocationInformation::asJson ()
QJsonObject* QJsonObject*
SWGLocationInformation::asJsonObject() { SWGLocationInformation::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("latitude", QJsonValue(latitude)); obj->insert("latitude", QJsonValue(latitude));
obj->insert("longitude", QJsonValue(longitude));
obj->insert("longitude", QJsonValue(longitude));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); float getLatitude();
void setLatitude(float latitude); void setLatitude(float latitude);
float getLongitude();
float getLongitude();
void setLongitude(float longitude); void setLongitude(float longitude);
private: private:
float latitude; float latitude;
float longitude; float longitude;
}; };
} /* namespace Swagger */ }
#endif /* SWGLocationInformation_H_ */ #endif /* SWGLocationInformation_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGLoggingInfo::SWGLoggingInfo(QString* json) { SWGLoggingInfo::SWGLoggingInfo(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,23 +37,26 @@ SWGLoggingInfo::~SWGLoggingInfo() {
void void
SWGLoggingInfo::init() { SWGLoggingInfo::init() {
consoleLevel = new QString(""); console_level = new QString("");
fileLevel = new QString(""); file_level = new QString("");
dumpToFile = false; dump_to_file = false;
fileName = new QString(""); file_name = new QString("");
} }
void void
SWGLoggingInfo::cleanup() { SWGLoggingInfo::cleanup() {
if(consoleLevel != NULL) {
delete consoleLevel; if(console_level != nullptr) {
} delete console_level;
if(fileLevel != NULL) {
delete fileLevel;
} }
if(fileName != NULL) { if(file_level != nullptr) {
delete fileName; delete file_level;
}
if(file_name != nullptr) {
delete file_name;
} }
} }
@ -81,10 +71,10 @@ SWGLoggingInfo::fromJson(QString &json) {
void void
SWGLoggingInfo::fromJsonObject(QJsonObject &pJson) { SWGLoggingInfo::fromJsonObject(QJsonObject &pJson) {
setValue(&consoleLevel, pJson["consoleLevel"], "QString", "QString"); ::Swagger::setValue(&console_level, pJson["consoleLevel"], "QString", "QString");
setValue(&fileLevel, pJson["fileLevel"], "QString", "QString"); ::Swagger::setValue(&file_level, pJson["fileLevel"], "QString", "QString");
setValue(&dumpToFile, pJson["dumpToFile"], "bool", ""); ::Swagger::setValue(&dump_to_file, pJson["dumpToFile"], "bool", "");
setValue(&fileName, pJson["fileName"], "QString", "QString"); ::Swagger::setValue(&file_name, pJson["fileName"], "QString", "QString");
} }
QString QString
@ -101,62 +91,53 @@ QJsonObject*
SWGLoggingInfo::asJsonObject() { SWGLoggingInfo::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("consoleLevel"), console_level, obj, QString("QString"));
toJsonValue(QString("consoleLevel"), consoleLevel, obj, QString("QString"));
toJsonValue(QString("fileLevel"), file_level, obj, QString("QString"));
toJsonValue(QString("fileLevel"), fileLevel, obj, QString("QString"));
obj->insert("dumpToFile", QJsonValue(dumpToFile));
obj->insert("dumpToFile", QJsonValue(dump_to_file));
toJsonValue(QString("fileName"), fileName, obj, QString("QString"));
toJsonValue(QString("fileName"), file_name, obj, QString("QString"));
return obj; return obj;
} }
QString* QString*
SWGLoggingInfo::getConsoleLevel() { SWGLoggingInfo::getConsoleLevel() {
return consoleLevel; return console_level;
} }
void void
SWGLoggingInfo::setConsoleLevel(QString* consoleLevel) { SWGLoggingInfo::setConsoleLevel(QString* console_level) {
this->consoleLevel = consoleLevel; this->console_level = console_level;
} }
QString* QString*
SWGLoggingInfo::getFileLevel() { SWGLoggingInfo::getFileLevel() {
return fileLevel; return file_level;
} }
void void
SWGLoggingInfo::setFileLevel(QString* fileLevel) { SWGLoggingInfo::setFileLevel(QString* file_level) {
this->fileLevel = fileLevel; this->file_level = file_level;
} }
bool bool
SWGLoggingInfo::getDumpToFile() { SWGLoggingInfo::getDumpToFile() {
return dumpToFile; return dump_to_file;
} }
void void
SWGLoggingInfo::setDumpToFile(bool dumpToFile) { SWGLoggingInfo::setDumpToFile(bool dump_to_file) {
this->dumpToFile = dumpToFile; this->dump_to_file = dump_to_file;
} }
QString* QString*
SWGLoggingInfo::getFileName() { SWGLoggingInfo::getFileName() {
return fileName; return file_name;
} }
void void
SWGLoggingInfo::setFileName(QString* fileName) { SWGLoggingInfo::setFileName(QString* file_name) {
this->fileName = fileName; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGLoggingInfo* fromJson(QString &jsonString);
QString* getConsoleLevel(); QString* getConsoleLevel();
void setConsoleLevel(QString* consoleLevel); void setConsoleLevel(QString* console_level);
QString* getFileLevel();
void setFileLevel(QString* fileLevel); QString* getFileLevel();
bool getDumpToFile(); void setFileLevel(QString* file_level);
void setDumpToFile(bool dumpToFile);
QString* getFileName(); bool getDumpToFile();
void setFileName(QString* fileName); void setDumpToFile(bool dump_to_file);
QString* getFileName();
void setFileName(QString* file_name);
private: private:
QString* consoleLevel; QString* console_level;
QString* fileLevel; QString* file_level;
bool dumpToFile; bool dump_to_file;
QString* fileName; QString* file_name;
}; };
} /* namespace Swagger */ }
#endif /* SWGLoggingInfo_H_ */ #endif /* SWGLoggingInfo_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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_ #ifndef ModelFactory_H_
@ -49,6 +37,7 @@
#include "SWGUser.h" #include "SWGUser.h"
namespace Swagger { namespace Swagger {
inline void* create(QString type) { inline void* create(QString type) {
if(QString("SWGAudioDevices").compare(type) == 0) { if(QString("SWGAudioDevices").compare(type) == 0) {
return new SWGAudioDevices(); return new SWGAudioDevices();
@ -114,20 +103,21 @@ namespace Swagger {
return new SWGUser(); return new SWGUser();
} }
return NULL; return nullptr;
} }
inline void* create(QString json, QString type) { inline void* create(QString json, QString type) {
void* val = create(type); void* val = create(type);
if(val != NULL) { if(val != nullptr) {
SWGObject* obj = static_cast<SWGObject*>(val); SWGObject* obj = static_cast<SWGObject*>(val);
return obj->fromJson(json); return obj->fromJson(json);
} }
if(type.startsWith("QString")) { if(type.startsWith("QString")) {
return new QString(); return new QString();
} }
return NULL; return nullptr;
} }
} /* namespace Swagger */
}
#endif /* ModelFactory_H_ */ #endif /* ModelFactory_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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_ #ifndef _SWG_OBJECT_H_
@ -27,15 +15,17 @@
#include <QJsonValue> #include <QJsonValue>
namespace Swagger {
class SWGObject { class SWGObject {
public: public:
virtual QJsonObject* asJsonObject() { virtual QJsonObject* asJsonObject() {
return NULL; return nullptr;
} }
virtual ~SWGObject() {} virtual ~SWGObject() {}
virtual SWGObject* fromJson(QString &jsonString) { virtual SWGObject* fromJson(QString &jsonString) {
Q_UNUSED(jsonString); Q_UNUSED(jsonString);
return NULL; return nullptr;
} }
virtual void fromJsonObject(QJsonObject &json) { virtual void fromJsonObject(QJsonObject &json) {
Q_UNUSED(json); Q_UNUSED(json);
@ -45,4 +35,6 @@ class SWGObject {
} }
}; };
}
#endif /* _SWG_OBJECT_H_ */ #endif /* _SWG_OBJECT_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGPresetGroup::SWGPresetGroup(QString* json) { SWGPresetGroup::SWGPresetGroup(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,18 +37,20 @@ SWGPresetGroup::~SWGPresetGroup() {
void void
SWGPresetGroup::init() { SWGPresetGroup::init() {
groupName = new QString(""); group_name = new QString("");
nbPresets = NULL; nb_presets = 0;
presets = new QList<SWGPresetItem*>(); presets = new QList<SWGPresetItem*>();
} }
void void
SWGPresetGroup::cleanup() { SWGPresetGroup::cleanup() {
if(groupName != NULL) {
delete groupName; if(group_name != nullptr) {
delete group_name;
} }
if(presets != NULL) {
if(presets != nullptr) {
QList<SWGPresetItem*>* arr = presets; QList<SWGPresetItem*>* arr = presets;
foreach(SWGPresetItem* o, *arr) { foreach(SWGPresetItem* o, *arr) {
delete o; delete o;
@ -81,9 +70,11 @@ SWGPresetGroup::fromJson(QString &json) {
void void
SWGPresetGroup::fromJsonObject(QJsonObject &pJson) { SWGPresetGroup::fromJsonObject(QJsonObject &pJson) {
setValue(&groupName, pJson["groupName"], "QString", "QString"); ::Swagger::setValue(&group_name, pJson["groupName"], "QString", "QString");
setValue(&nbPresets, pJson["nbPresets"], "qint32", ""); ::Swagger::setValue(&nb_presets, pJson["nbPresets"], "qint32", "");
setValue(&presets, pJson["presets"], "QList", "SWGPresetItem");
::Swagger::setValue(&presets, pJson["presets"], "QList", "SWGPresetItem");
} }
QString QString
@ -100,39 +91,33 @@ QJsonObject*
SWGPresetGroup::asJsonObject() { SWGPresetGroup::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("groupName"), group_name, obj, QString("QString"));
toJsonValue(QString("groupName"), groupName, obj, QString("QString"));
obj->insert("nbPresets", QJsonValue(nb_presets));
obj->insert("nbPresets", QJsonValue(nbPresets));
QList<SWGPresetItem*>* presetsList = presets;
QJsonArray presetsJsonArray; QJsonArray presetsJsonArray;
toJsonArray((QList<void*>*)presets, &presetsJsonArray, "presets", "SWGPresetItem"); toJsonArray((QList<void*>*)presets, &presetsJsonArray, "presets", "SWGPresetItem");
obj->insert("presets", presetsJsonArray); obj->insert("presets", presetsJsonArray);
return obj; return obj;
} }
QString* QString*
SWGPresetGroup::getGroupName() { SWGPresetGroup::getGroupName() {
return groupName; return group_name;
} }
void void
SWGPresetGroup::setGroupName(QString* groupName) { SWGPresetGroup::setGroupName(QString* group_name) {
this->groupName = groupName; this->group_name = group_name;
} }
qint32 qint32
SWGPresetGroup::getNbPresets() { SWGPresetGroup::getNbPresets() {
return nbPresets; return nb_presets;
} }
void void
SWGPresetGroup::setNbPresets(qint32 nbPresets) { SWGPresetGroup::setNbPresets(qint32 nb_presets) {
this->nbPresets = nbPresets; this->nb_presets = nb_presets;
} }
QList<SWGPresetItem*>* 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGPresetGroup* fromJson(QString &jsonString);
QString* getGroupName(); QString* getGroupName();
void setGroupName(QString* groupName); void setGroupName(QString* group_name);
qint32 getNbPresets();
void setNbPresets(qint32 nbPresets); qint32 getNbPresets();
QList<SWGPresetItem*>* getPresets(); void setNbPresets(qint32 nb_presets);
QList<SWGPresetItem*>* getPresets();
void setPresets(QList<SWGPresetItem*>* presets); void setPresets(QList<SWGPresetItem*>* presets);
private: private:
QString* groupName; QString* group_name;
qint32 nbPresets; qint32 nb_presets;
QList<SWGPresetItem*>* presets; QList<SWGPresetItem*>* presets;
}; };
} /* namespace Swagger */ }
#endif /* SWGPresetGroup_H_ */ #endif /* SWGPresetGroup_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGPresetIdentifier::SWGPresetIdentifier(QString* json) { SWGPresetIdentifier::SWGPresetIdentifier(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,22 +37,25 @@ SWGPresetIdentifier::~SWGPresetIdentifier() {
void void
SWGPresetIdentifier::init() { SWGPresetIdentifier::init() {
groupName = new QString(""); group_name = new QString("");
centerFrequency = 0.0f; center_frequency = 0.0f;
type = new QString(""); type = new QString("");
name = new QString(""); name = new QString("");
} }
void void
SWGPresetIdentifier::cleanup() { SWGPresetIdentifier::cleanup() {
if(groupName != NULL) {
delete groupName; if(group_name != nullptr) {
delete group_name;
} }
if(type != NULL) {
if(type != nullptr) {
delete type; delete type;
} }
if(name != NULL) {
if(name != nullptr) {
delete name; delete name;
} }
} }
@ -81,10 +71,10 @@ SWGPresetIdentifier::fromJson(QString &json) {
void void
SWGPresetIdentifier::fromJsonObject(QJsonObject &pJson) { SWGPresetIdentifier::fromJsonObject(QJsonObject &pJson) {
setValue(&groupName, pJson["groupName"], "QString", "QString"); ::Swagger::setValue(&group_name, pJson["groupName"], "QString", "QString");
setValue(&centerFrequency, pJson["centerFrequency"], "float", ""); ::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "float", "");
setValue(&type, pJson["type"], "QString", "QString"); ::Swagger::setValue(&type, pJson["type"], "QString", "QString");
setValue(&name, pJson["name"], "QString", "QString"); ::Swagger::setValue(&name, pJson["name"], "QString", "QString");
} }
QString QString
@ -101,41 +91,33 @@ QJsonObject*
SWGPresetIdentifier::asJsonObject() { SWGPresetIdentifier::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
toJsonValue(QString("groupName"), group_name, obj, QString("QString"));
toJsonValue(QString("groupName"), groupName, obj, QString("QString"));
obj->insert("centerFrequency", QJsonValue(center_frequency));
obj->insert("centerFrequency", QJsonValue(centerFrequency));
toJsonValue(QString("type"), type, obj, QString("QString")); toJsonValue(QString("type"), type, obj, QString("QString"));
toJsonValue(QString("name"), name, obj, QString("QString")); toJsonValue(QString("name"), name, obj, QString("QString"));
return obj; return obj;
} }
QString* QString*
SWGPresetIdentifier::getGroupName() { SWGPresetIdentifier::getGroupName() {
return groupName; return group_name;
} }
void void
SWGPresetIdentifier::setGroupName(QString* groupName) { SWGPresetIdentifier::setGroupName(QString* group_name) {
this->groupName = groupName; this->group_name = group_name;
} }
float float
SWGPresetIdentifier::getCenterFrequency() { SWGPresetIdentifier::getCenterFrequency() {
return centerFrequency; return center_frequency;
} }
void void
SWGPresetIdentifier::setCenterFrequency(float centerFrequency) { SWGPresetIdentifier::setCenterFrequency(float center_frequency) {
this->centerFrequency = centerFrequency; this->center_frequency = center_frequency;
} }
QString* 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGPresetIdentifier* fromJson(QString &jsonString);
QString* getGroupName(); QString* getGroupName();
void setGroupName(QString* groupName); void setGroupName(QString* group_name);
float getCenterFrequency();
void setCenterFrequency(float centerFrequency); float getCenterFrequency();
QString* getType(); void setCenterFrequency(float center_frequency);
QString* getType();
void setType(QString* type); void setType(QString* type);
QString* getName();
QString* getName();
void setName(QString* name); void setName(QString* name);
private: private:
QString* groupName; QString* group_name;
float centerFrequency; float center_frequency;
QString* type; QString* type;
QString* name; QString* name;
}; };
} /* namespace Swagger */ }
#endif /* SWGPresetIdentifier_H_ */ #endif /* SWGPresetIdentifier_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGPresetItem::SWGPresetItem(QString* json) { SWGPresetItem::SWGPresetItem(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,18 +37,20 @@ SWGPresetItem::~SWGPresetItem() {
void void
SWGPresetItem::init() { SWGPresetItem::init() {
centerFrequency = 0.0f; center_frequency = 0.0f;
type = new QString(""); type = new QString("");
name = new QString(""); name = new QString("");
} }
void void
SWGPresetItem::cleanup() { SWGPresetItem::cleanup() {
if(type != NULL) {
if(type != nullptr) {
delete type; delete type;
} }
if(name != NULL) {
if(name != nullptr) {
delete name; delete name;
} }
} }
@ -77,9 +66,9 @@ SWGPresetItem::fromJson(QString &json) {
void void
SWGPresetItem::fromJsonObject(QJsonObject &pJson) { SWGPresetItem::fromJsonObject(QJsonObject &pJson) {
setValue(&centerFrequency, pJson["centerFrequency"], "float", ""); ::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "float", "");
setValue(&type, pJson["type"], "QString", "QString"); ::Swagger::setValue(&type, pJson["type"], "QString", "QString");
setValue(&name, pJson["name"], "QString", "QString"); ::Swagger::setValue(&name, pJson["name"], "QString", "QString");
} }
QString QString
@ -95,28 +84,23 @@ SWGPresetItem::asJson ()
QJsonObject* QJsonObject*
SWGPresetItem::asJsonObject() { SWGPresetItem::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("centerFrequency", QJsonValue(centerFrequency));
obj->insert("centerFrequency", QJsonValue(center_frequency));
toJsonValue(QString("type"), type, obj, QString("QString")); toJsonValue(QString("type"), type, obj, QString("QString"));
toJsonValue(QString("name"), name, obj, QString("QString")); toJsonValue(QString("name"), name, obj, QString("QString"));
return obj; return obj;
} }
float float
SWGPresetItem::getCenterFrequency() { SWGPresetItem::getCenterFrequency() {
return centerFrequency; return center_frequency;
} }
void void
SWGPresetItem::setCenterFrequency(float centerFrequency) { SWGPresetItem::setCenterFrequency(float center_frequency) {
this->centerFrequency = centerFrequency; this->center_frequency = center_frequency;
} }
QString* 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGPresetItem* fromJson(QString &jsonString);
float getCenterFrequency(); float getCenterFrequency();
void setCenterFrequency(float centerFrequency); void setCenterFrequency(float center_frequency);
QString* getType();
QString* getType();
void setType(QString* type); void setType(QString* type);
QString* getName();
QString* getName();
void setName(QString* name); void setName(QString* name);
private: private:
float centerFrequency; float center_frequency;
QString* type; QString* type;
QString* name; QString* name;
}; };
} /* namespace Swagger */ }
#endif /* SWGPresetItem_H_ */ #endif /* SWGPresetItem_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGPresetTransfer::SWGPresetTransfer(QString* json) { SWGPresetTransfer::SWGPresetTransfer(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,14 +37,15 @@ SWGPresetTransfer::~SWGPresetTransfer() {
void void
SWGPresetTransfer::init() { SWGPresetTransfer::init() {
deviceSetIndex = NULL; device_set_index = 0;
preset = new SWGPresetIdentifier(); preset = new SWGPresetIdentifier();
} }
void void
SWGPresetTransfer::cleanup() { SWGPresetTransfer::cleanup() {
if(preset != NULL) {
if(preset != nullptr) {
delete preset; delete preset;
} }
} }
@ -73,8 +61,8 @@ SWGPresetTransfer::fromJson(QString &json) {
void void
SWGPresetTransfer::fromJsonObject(QJsonObject &pJson) { SWGPresetTransfer::fromJsonObject(QJsonObject &pJson) {
setValue(&deviceSetIndex, pJson["deviceSetIndex"], "qint32", ""); ::Swagger::setValue(&device_set_index, pJson["deviceSetIndex"], "qint32", "");
setValue(&preset, pJson["preset"], "SWGPresetIdentifier", "SWGPresetIdentifier"); ::Swagger::setValue(&preset, pJson["preset"], "SWGPresetIdentifier", "SWGPresetIdentifier");
} }
QString QString
@ -90,23 +78,21 @@ SWGPresetTransfer::asJson ()
QJsonObject* QJsonObject*
SWGPresetTransfer::asJsonObject() { SWGPresetTransfer::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("deviceSetIndex", QJsonValue(deviceSetIndex));
obj->insert("deviceSetIndex", QJsonValue(device_set_index));
toJsonValue(QString("preset"), preset, obj, QString("SWGPresetIdentifier")); toJsonValue(QString("preset"), preset, obj, QString("SWGPresetIdentifier"));
return obj; return obj;
} }
qint32 qint32
SWGPresetTransfer::getDeviceSetIndex() { SWGPresetTransfer::getDeviceSetIndex() {
return deviceSetIndex; return device_set_index;
} }
void void
SWGPresetTransfer::setDeviceSetIndex(qint32 deviceSetIndex) { SWGPresetTransfer::setDeviceSetIndex(qint32 device_set_index) {
this->deviceSetIndex = deviceSetIndex; this->device_set_index = device_set_index;
} }
SWGPresetIdentifier* 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGPresetTransfer* fromJson(QString &jsonString);
qint32 getDeviceSetIndex(); qint32 getDeviceSetIndex();
void setDeviceSetIndex(qint32 deviceSetIndex); void setDeviceSetIndex(qint32 device_set_index);
SWGPresetIdentifier* getPreset();
SWGPresetIdentifier* getPreset();
void setPreset(SWGPresetIdentifier* preset); void setPreset(SWGPresetIdentifier* preset);
private: private:
qint32 deviceSetIndex; qint32 device_set_index;
SWGPresetIdentifier* preset; SWGPresetIdentifier* preset;
}; };
} /* namespace Swagger */ }
#endif /* SWGPresetTransfer_H_ */ #endif /* SWGPresetTransfer_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGPresets::SWGPresets(QString* json) { SWGPresets::SWGPresets(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,14 +37,15 @@ SWGPresets::~SWGPresets() {
void void
SWGPresets::init() { SWGPresets::init() {
nbGroups = NULL; nb_groups = 0;
groups = new QList<SWGPresetGroup*>(); groups = new QList<SWGPresetGroup*>();
} }
void void
SWGPresets::cleanup() { SWGPresets::cleanup() {
if(groups != NULL) {
if(groups != nullptr) {
QList<SWGPresetGroup*>* arr = groups; QList<SWGPresetGroup*>* arr = groups;
foreach(SWGPresetGroup* o, *arr) { foreach(SWGPresetGroup* o, *arr) {
delete o; delete o;
@ -77,8 +65,10 @@ SWGPresets::fromJson(QString &json) {
void void
SWGPresets::fromJsonObject(QJsonObject &pJson) { SWGPresets::fromJsonObject(QJsonObject &pJson) {
setValue(&nbGroups, pJson["nbGroups"], "qint32", ""); ::Swagger::setValue(&nb_groups, pJson["nbGroups"], "qint32", "");
setValue(&groups, pJson["groups"], "QList", "SWGPresetGroup");
::Swagger::setValue(&groups, pJson["groups"], "QList", "SWGPresetGroup");
} }
QString QString
@ -94,26 +84,23 @@ SWGPresets::asJson ()
QJsonObject* QJsonObject*
SWGPresets::asJsonObject() { SWGPresets::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("nbGroups", QJsonValue(nbGroups));
QList<SWGPresetGroup*>* groupsList = groups; obj->insert("nbGroups", QJsonValue(nb_groups));
QJsonArray groupsJsonArray; QJsonArray groupsJsonArray;
toJsonArray((QList<void*>*)groups, &groupsJsonArray, "groups", "SWGPresetGroup"); toJsonArray((QList<void*>*)groups, &groupsJsonArray, "groups", "SWGPresetGroup");
obj->insert("groups", groupsJsonArray); obj->insert("groups", groupsJsonArray);
return obj; return obj;
} }
qint32 qint32
SWGPresets::getNbGroups() { SWGPresets::getNbGroups() {
return nbGroups; return nb_groups;
} }
void void
SWGPresets::setNbGroups(qint32 nbGroups) { SWGPresets::setNbGroups(qint32 nb_groups) {
this->nbGroups = nbGroups; this->nb_groups = nb_groups;
} }
QList<SWGPresetGroup*>* 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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); SWGPresets* fromJson(QString &jsonString);
qint32 getNbGroups(); qint32 getNbGroups();
void setNbGroups(qint32 nbGroups); void setNbGroups(qint32 nb_groups);
QList<SWGPresetGroup*>* getGroups();
QList<SWGPresetGroup*>* getGroups();
void setGroups(QList<SWGPresetGroup*>* groups); void setGroups(QList<SWGPresetGroup*>* groups);
private: private:
qint32 nbGroups; qint32 nb_groups;
QList<SWGPresetGroup*>* groups; QList<SWGPresetGroup*>* groups;
}; };
} /* namespace Swagger */ }
#endif /* SWGPresets_H_ */ #endif /* SWGPresets_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGSamplingDevice::SWGSamplingDevice(QString* json) { SWGSamplingDevice::SWGSamplingDevice(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,28 +37,30 @@ SWGSamplingDevice::~SWGSamplingDevice() {
void void
SWGSamplingDevice::init() { SWGSamplingDevice::init() {
index = NULL; index = 0;
hwType = new QString(""); hw_type = new QString("");
tx = false; tx = false;
nbStreams = NULL; nb_streams = 0;
streamIndex = NULL; stream_index = 0;
sequence = NULL; sequence = 0;
serial = new QString(""); serial = new QString("");
centerFrequency = 0L; center_frequency = 0L;
bandwidth = NULL; bandwidth = 0;
} }
void void
SWGSamplingDevice::cleanup() { SWGSamplingDevice::cleanup() {
if(hwType != NULL) {
delete hwType; if(hw_type != nullptr) {
delete hw_type;
} }
if(serial != NULL) {
if(serial != nullptr) {
delete serial; delete serial;
} }
@ -89,15 +78,15 @@ SWGSamplingDevice::fromJson(QString &json) {
void void
SWGSamplingDevice::fromJsonObject(QJsonObject &pJson) { SWGSamplingDevice::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", ""); ::Swagger::setValue(&index, pJson["index"], "qint32", "");
setValue(&hwType, pJson["hwType"], "QString", "QString"); ::Swagger::setValue(&hw_type, pJson["hwType"], "QString", "QString");
setValue(&tx, pJson["tx"], "bool", ""); ::Swagger::setValue(&tx, pJson["tx"], "bool", "");
setValue(&nbStreams, pJson["nbStreams"], "qint32", ""); ::Swagger::setValue(&nb_streams, pJson["nbStreams"], "qint32", "");
setValue(&streamIndex, pJson["streamIndex"], "qint32", ""); ::Swagger::setValue(&stream_index, pJson["streamIndex"], "qint32", "");
setValue(&sequence, pJson["sequence"], "qint32", ""); ::Swagger::setValue(&sequence, pJson["sequence"], "qint32", "");
setValue(&serial, pJson["serial"], "QString", "QString"); ::Swagger::setValue(&serial, pJson["serial"], "QString", "QString");
setValue(&centerFrequency, pJson["centerFrequency"], "qint64", ""); ::Swagger::setValue(&center_frequency, pJson["centerFrequency"], "qint64", "");
setValue(&bandwidth, pJson["bandwidth"], "qint32", ""); ::Swagger::setValue(&bandwidth, pJson["bandwidth"], "qint32", "");
} }
QString QString
@ -113,23 +102,24 @@ SWGSamplingDevice::asJson ()
QJsonObject* QJsonObject*
SWGSamplingDevice::asJsonObject() { SWGSamplingDevice::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index)); obj->insert("index", QJsonValue(index));
toJsonValue(QString("hwType"), hw_type, obj, QString("QString"));
toJsonValue(QString("hwType"), hwType, obj, QString("QString"));
obj->insert("tx", QJsonValue(tx));
obj->insert("tx", QJsonValue(tx)); obj->insert("nbStreams", QJsonValue(nb_streams));
obj->insert("nbStreams", QJsonValue(nbStreams));
obj->insert("streamIndex", QJsonValue(streamIndex)); obj->insert("streamIndex", QJsonValue(stream_index));
obj->insert("sequence", QJsonValue(sequence));
obj->insert("sequence", QJsonValue(sequence));
toJsonValue(QString("serial"), serial, obj, QString("QString")); toJsonValue(QString("serial"), serial, obj, QString("QString"));
obj->insert("centerFrequency", QJsonValue(center_frequency));
obj->insert("centerFrequency", QJsonValue(centerFrequency));
obj->insert("bandwidth", QJsonValue(bandwidth)); obj->insert("bandwidth", QJsonValue(bandwidth));
return obj; return obj;
} }
@ -145,11 +135,11 @@ SWGSamplingDevice::setIndex(qint32 index) {
QString* QString*
SWGSamplingDevice::getHwType() { SWGSamplingDevice::getHwType() {
return hwType; return hw_type;
} }
void void
SWGSamplingDevice::setHwType(QString* hwType) { SWGSamplingDevice::setHwType(QString* hw_type) {
this->hwType = hwType; this->hw_type = hw_type;
} }
bool bool
@ -163,20 +153,20 @@ SWGSamplingDevice::setTx(bool tx) {
qint32 qint32
SWGSamplingDevice::getNbStreams() { SWGSamplingDevice::getNbStreams() {
return nbStreams; return nb_streams;
} }
void void
SWGSamplingDevice::setNbStreams(qint32 nbStreams) { SWGSamplingDevice::setNbStreams(qint32 nb_streams) {
this->nbStreams = nbStreams; this->nb_streams = nb_streams;
} }
qint32 qint32
SWGSamplingDevice::getStreamIndex() { SWGSamplingDevice::getStreamIndex() {
return streamIndex; return stream_index;
} }
void void
SWGSamplingDevice::setStreamIndex(qint32 streamIndex) { SWGSamplingDevice::setStreamIndex(qint32 stream_index) {
this->streamIndex = streamIndex; this->stream_index = stream_index;
} }
qint32 qint32
@ -199,11 +189,11 @@ SWGSamplingDevice::setSerial(QString* serial) {
qint64 qint64
SWGSamplingDevice::getCenterFrequency() { SWGSamplingDevice::getCenterFrequency() {
return centerFrequency; return center_frequency;
} }
void void
SWGSamplingDevice::setCenterFrequency(qint64 centerFrequency) { SWGSamplingDevice::setCenterFrequency(qint64 center_frequency) {
this->centerFrequency = centerFrequency; this->center_frequency = center_frequency;
} }
qint32 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getIndex();
void setIndex(qint32 index); void setIndex(qint32 index);
QString* getHwType();
void setHwType(QString* hwType); QString* getHwType();
bool getTx(); void setHwType(QString* hw_type);
bool getTx();
void setTx(bool tx); void setTx(bool tx);
qint32 getNbStreams();
void setNbStreams(qint32 nbStreams); qint32 getNbStreams();
qint32 getStreamIndex(); void setNbStreams(qint32 nb_streams);
void setStreamIndex(qint32 streamIndex);
qint32 getSequence(); qint32 getStreamIndex();
void setStreamIndex(qint32 stream_index);
qint32 getSequence();
void setSequence(qint32 sequence); void setSequence(qint32 sequence);
QString* getSerial();
QString* getSerial();
void setSerial(QString* serial); void setSerial(QString* serial);
qint64 getCenterFrequency();
void setCenterFrequency(qint64 centerFrequency); qint64 getCenterFrequency();
qint32 getBandwidth(); void setCenterFrequency(qint64 center_frequency);
qint32 getBandwidth();
void setBandwidth(qint32 bandwidth); void setBandwidth(qint32 bandwidth);
private: private:
qint32 index; qint32 index;
QString* hwType; QString* hw_type;
bool tx; bool tx;
qint32 nbStreams; qint32 nb_streams;
qint32 streamIndex; qint32 stream_index;
qint32 sequence; qint32 sequence;
QString* serial; QString* serial;
qint64 centerFrequency; qint64 center_frequency;
qint32 bandwidth; qint32 bandwidth;
}; };
} /* namespace Swagger */ }
#endif /* SWGSamplingDevice_H_ */ #endif /* SWGSamplingDevice_H_ */

View File

@ -8,18 +8,6 @@
* NOTE: This class is auto generated by the swagger code generator program. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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 { namespace Swagger {
SWGUser::SWGUser(QString* json) { SWGUser::SWGUser(QString* json) {
init(); init();
this->fromJson(*json); this->fromJson(*json);
@ -50,14 +37,15 @@ SWGUser::~SWGUser() {
void void
SWGUser::init() { SWGUser::init() {
index = NULL; index = 0;
name = new QString(""); name = new QString("");
} }
void void
SWGUser::cleanup() { SWGUser::cleanup() {
if(name != NULL) {
if(name != nullptr) {
delete name; delete name;
} }
} }
@ -73,8 +61,8 @@ SWGUser::fromJson(QString &json) {
void void
SWGUser::fromJsonObject(QJsonObject &pJson) { SWGUser::fromJsonObject(QJsonObject &pJson) {
setValue(&index, pJson["index"], "qint32", ""); ::Swagger::setValue(&index, pJson["index"], "qint32", "");
setValue(&name, pJson["name"], "QString", "QString"); ::Swagger::setValue(&name, pJson["name"], "QString", "QString");
} }
QString QString
@ -90,12 +78,10 @@ SWGUser::asJson ()
QJsonObject* QJsonObject*
SWGUser::asJsonObject() { SWGUser::asJsonObject() {
QJsonObject* obj = new QJsonObject(); QJsonObject* obj = new QJsonObject();
obj->insert("index", QJsonValue(index)); obj->insert("index", QJsonValue(index));
toJsonValue(QString("name"), name, obj, QString("QString")); toJsonValue(QString("name"), name, obj, QString("QString"));
return obj; 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. * NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git * https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually. * 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(); qint32 getIndex();
void setIndex(qint32 index); void setIndex(qint32 index);
QString* getName();
QString* getName();
void setName(QString* name); void setName(QString* name);
private: private:
qint32 index; qint32 index;
QString* name; QString* name;
}; };
} /* namespace Swagger */ }
#endif /* SWGUser_H_ */ #endif /* SWGUser_H_ */