forked from loafle/openapi-generator-original
removed some cruft
This commit is contained in:
parent
f9db729e75
commit
8519480f2c
@ -33,8 +33,6 @@ void
|
||||
.append(QUrl::toPercentEncoding(stringValue({{paramName}})));
|
||||
{{/queryParams}}
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "{{httpMethod}}");
|
||||
|
||||
@ -65,10 +63,7 @@ void
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: {{{returnType}}}
|
||||
|
||||
{{#returnType}}
|
||||
{{#isListContainer}}
|
||||
{{#returnType}}{{#isListContainer}}
|
||||
{{{returnType}}} output = {{{defaultResponse}}};
|
||||
QString json(worker->response);
|
||||
QByteArray array (json.toStdString().c_str());
|
||||
@ -82,9 +77,6 @@ void
|
||||
o->fromJsonObject(*ptr);
|
||||
output->append(o);
|
||||
}
|
||||
|
||||
|
||||
// void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType);
|
||||
{{/isListContainer}}
|
||||
|
||||
{{^isListContainer}}{{#returnTypeIsPrimitive}}
|
||||
|
@ -23,8 +23,6 @@ SWGPetApi::updatePet(SWGPet body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "PUT");
|
||||
|
||||
@ -53,8 +51,6 @@ SWGPetApi::updatePetCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -71,8 +67,6 @@ SWGPetApi::addPet(SWGPet body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -101,8 +95,6 @@ SWGPetApi::addPetCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -124,8 +116,6 @@ SWGPetApi::findPetsByStatus(QList<QString*>* status) {
|
||||
.append(QUrl::toPercentEncoding(stringValue(status)));
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -151,9 +141,6 @@ SWGPetApi::findPetsByStatusCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: QList<SWGPet*>*
|
||||
|
||||
|
||||
|
||||
QList<SWGPet*>* output = new QList<SWGPet*>();
|
||||
QString json(worker->response);
|
||||
@ -168,9 +155,6 @@ SWGPetApi::findPetsByStatusCallback(HttpRequestWorker * worker) {
|
||||
o->fromJsonObject(*ptr);
|
||||
output->append(o);
|
||||
}
|
||||
|
||||
|
||||
// void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType);
|
||||
|
||||
|
||||
|
||||
@ -194,8 +178,6 @@ SWGPetApi::findPetsByTags(QList<QString*>* tags) {
|
||||
.append(QUrl::toPercentEncoding(stringValue(tags)));
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -221,9 +203,6 @@ SWGPetApi::findPetsByTagsCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: QList<SWGPet*>*
|
||||
|
||||
|
||||
|
||||
QList<SWGPet*>* output = new QList<SWGPet*>();
|
||||
QString json(worker->response);
|
||||
@ -238,9 +217,6 @@ SWGPetApi::findPetsByTagsCallback(HttpRequestWorker * worker) {
|
||||
o->fromJsonObject(*ptr);
|
||||
output->append(o);
|
||||
}
|
||||
|
||||
|
||||
// void toJsonArray(QList<void*>* value, QJsonArray* output, QString innerName, QString innerType);
|
||||
|
||||
|
||||
|
||||
@ -262,8 +238,6 @@ SWGPetApi::getPetById(qint64 petId) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -289,9 +263,6 @@ SWGPetApi::getPetByIdCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: SWGPet*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -318,8 +289,6 @@ SWGPetApi::updatePetWithForm(QString* petId, QString* name, QString* status) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -345,8 +314,6 @@ SWGPetApi::updatePetWithFormCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -366,8 +333,6 @@ SWGPetApi::deletePet(QString* api_key, qint64 petId) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "DELETE");
|
||||
|
||||
@ -395,8 +360,6 @@ SWGPetApi::deletePetCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -416,8 +379,6 @@ SWGPetApi::uploadFile(qint64 petId, QString* additionalMetadata, SWGFile* file)
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -443,8 +404,6 @@ SWGPetApi::uploadFileCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
|
@ -23,8 +23,6 @@ SWGStoreApi::getInventory() {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -50,9 +48,6 @@ SWGStoreApi::getInventoryCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: QMap<String, qint32>*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -76,8 +71,6 @@ SWGStoreApi::placeOrder(SWGOrder body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -106,9 +99,6 @@ SWGStoreApi::placeOrderCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: SWGOrder*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -135,8 +125,6 @@ SWGStoreApi::getOrderById(QString* orderId) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -162,9 +150,6 @@ SWGStoreApi::getOrderByIdCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: SWGOrder*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -191,8 +176,6 @@ SWGStoreApi::deleteOrder(QString* orderId) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "DELETE");
|
||||
|
||||
@ -218,8 +201,6 @@ SWGStoreApi::deleteOrderCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
|
@ -23,8 +23,6 @@ SWGUserApi::createUser(SWGUser body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -53,8 +51,6 @@ SWGUserApi::createUserCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -71,8 +67,6 @@ SWGUserApi::createUsersWithArrayInput(QList<SWGUser*>* body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -101,8 +95,6 @@ SWGUserApi::createUsersWithArrayInputCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -119,8 +111,6 @@ SWGUserApi::createUsersWithListInput(QList<SWGUser*>* body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "POST");
|
||||
|
||||
@ -149,8 +139,6 @@ SWGUserApi::createUsersWithListInputCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -177,8 +165,6 @@ SWGUserApi::loginUser(QString* username, QString* password) {
|
||||
.append(QUrl::toPercentEncoding(stringValue(password)));
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -204,9 +190,6 @@ SWGUserApi::loginUserCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: QString*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -230,8 +213,6 @@ SWGUserApi::logoutUser() {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -257,8 +238,6 @@ SWGUserApi::logoutUserCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -278,8 +257,6 @@ SWGUserApi::getUserByName(QString* username) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "GET");
|
||||
|
||||
@ -305,9 +282,6 @@ SWGUserApi::getUserByNameCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type: SWGUser*
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -334,8 +308,6 @@ SWGUserApi::updateUser(QString* username, SWGUser body) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "PUT");
|
||||
|
||||
@ -364,8 +336,6 @@ SWGUserApi::updateUserCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
@ -385,8 +355,6 @@ SWGUserApi::deleteUser(QString* username) {
|
||||
|
||||
|
||||
|
||||
// qDebug() << fullPath;
|
||||
|
||||
HttpRequestWorker *worker = new HttpRequestWorker();
|
||||
HttpRequestInput input(fullPath, "DELETE");
|
||||
|
||||
@ -412,8 +380,6 @@ SWGUserApi::deleteUserCallback(HttpRequestWorker * worker) {
|
||||
msg = "Error: " + worker->error_str;
|
||||
}
|
||||
|
||||
// return type:
|
||||
|
||||
|
||||
|
||||
worker->deleteLater();
|
||||
|
Loading…
x
Reference in New Issue
Block a user