From e85e1f112a3917ffd3f1daea0bddf063cda83609 Mon Sep 17 00:00:00 2001 From: sunn <33183834+etherealjoy@users.noreply.github.com> Date: Sat, 18 May 2019 11:57:23 +0200 Subject: [PATCH] Separate exception types (#2930) --- .../cpp-pistache-server/api-source.mustache | 12 ++- .../petstore/cpp-pistache/api/PetApi.cpp | 98 ++++++++++++------- .../server/petstore/cpp-pistache/api/PetApi.h | 2 +- .../petstore/cpp-pistache/api/StoreApi.cpp | 50 ++++++---- .../petstore/cpp-pistache/api/StoreApi.h | 2 +- .../petstore/cpp-pistache/api/UserApi.cpp | 98 ++++++++++++------- .../petstore/cpp-pistache/api/UserApi.h | 2 +- .../petstore/cpp-pistache/impl/PetApiImpl.cpp | 2 +- .../petstore/cpp-pistache/impl/PetApiImpl.h | 2 +- .../cpp-pistache/impl/StoreApiImpl.cpp | 2 +- .../petstore/cpp-pistache/impl/StoreApiImpl.h | 2 +- .../cpp-pistache/impl/UserApiImpl.cpp | 2 +- .../petstore/cpp-pistache/impl/UserApiImpl.h | 2 +- .../petstore/cpp-pistache/main-api-server.cpp | 2 +- .../cpp-pistache/model/ApiResponse.cpp | 2 +- .../petstore/cpp-pistache/model/ApiResponse.h | 2 +- .../petstore/cpp-pistache/model/Category.cpp | 2 +- .../petstore/cpp-pistache/model/Category.h | 2 +- .../petstore/cpp-pistache/model/Helpers.cpp | 2 +- .../petstore/cpp-pistache/model/Helpers.h | 2 +- .../petstore/cpp-pistache/model/Order.cpp | 2 +- .../petstore/cpp-pistache/model/Order.h | 2 +- .../petstore/cpp-pistache/model/Pet.cpp | 2 +- .../server/petstore/cpp-pistache/model/Pet.h | 2 +- .../petstore/cpp-pistache/model/Tag.cpp | 2 +- .../server/petstore/cpp-pistache/model/Tag.h | 2 +- .../petstore/cpp-pistache/model/User.cpp | 2 +- .../server/petstore/cpp-pistache/model/User.h | 2 +- 28 files changed, 195 insertions(+), 111 deletions(-) diff --git a/modules/openapi-generator/src/main/resources/cpp-pistache-server/api-source.mustache b/modules/openapi-generator/src/main/resources/cpp-pistache-server/api-source.mustache index c529fbea57..3f7f4e0b74 100644 --- a/modules/openapi-generator/src/main/resources/cpp-pistache-server/api-source.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-pistache-server/api-source.mustache @@ -79,10 +79,14 @@ void {{classname}}::{{operationIdSnakeCase}}_handler(const Pistache::Rest::Reque try { this->{{operationIdSnakeCase}}(request, response); {{/vendorExtensions.x-codegen-pistache-isParsingSupported}} - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } diff --git a/samples/server/petstore/cpp-pistache/api/PetApi.cpp b/samples/server/petstore/cpp-pistache/api/PetApi.cpp index 5ffab955c5..5ef93e9f73 100644 --- a/samples/server/petstore/cpp-pistache/api/PetApi.cpp +++ b/samples/server/petstore/cpp-pistache/api/PetApi.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,10 +54,14 @@ void PetApi::add_pet_handler(const Pistache::Rest::Request &request, Pistache::H try { nlohmann::json::parse(request.body()).get_to(body); this->add_pet(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -70,10 +74,14 @@ void PetApi::delete_pet_handler(const Pistache::Rest::Request &request, Pistache try { this->delete_pet(petId, apiKey, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -91,10 +99,14 @@ void PetApi::find_pets_by_status_handler(const Pistache::Rest::Request &request, try { this->find_pets_by_status(status, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -112,10 +124,14 @@ void PetApi::find_pets_by_tags_handler(const Pistache::Rest::Request &request, P try { this->find_pets_by_tags(tags, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -125,10 +141,14 @@ void PetApi::get_pet_by_id_handler(const Pistache::Rest::Request &request, Pista try { this->get_pet_by_id(petId, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -141,30 +161,42 @@ void PetApi::update_pet_handler(const Pistache::Rest::Request &request, Pistache try { nlohmann::json::parse(request.body()).get_to(body); this->update_pet(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } void PetApi::update_pet_with_form_handler(const Pistache::Rest::Request &request, Pistache::Http::ResponseWriter response) { try { this->update_pet_with_form(request, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } void PetApi::upload_file_handler(const Pistache::Rest::Request &request, Pistache::Http::ResponseWriter response) { try { this->upload_file(request, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } diff --git a/samples/server/petstore/cpp-pistache/api/PetApi.h b/samples/server/petstore/cpp-pistache/api/PetApi.h index c84ca38427..d991d13aba 100644 --- a/samples/server/petstore/cpp-pistache/api/PetApi.h +++ b/samples/server/petstore/cpp-pistache/api/PetApi.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/api/StoreApi.cpp b/samples/server/petstore/cpp-pistache/api/StoreApi.cpp index 98e4d387a1..6987e9cc85 100644 --- a/samples/server/petstore/cpp-pistache/api/StoreApi.cpp +++ b/samples/server/petstore/cpp-pistache/api/StoreApi.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -47,10 +47,14 @@ void StoreApi::delete_order_handler(const Pistache::Rest::Request &request, Pist try { this->delete_order(orderId, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -58,10 +62,14 @@ void StoreApi::get_inventory_handler(const Pistache::Rest::Request &request, Pis try { this->get_inventory(response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -71,10 +79,14 @@ void StoreApi::get_order_by_id_handler(const Pistache::Rest::Request &request, P try { this->get_order_by_id(orderId, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -87,10 +99,14 @@ void StoreApi::place_order_handler(const Pistache::Rest::Request &request, Pista try { nlohmann::json::parse(request.body()).get_to(body); this->place_order(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } diff --git a/samples/server/petstore/cpp-pistache/api/StoreApi.h b/samples/server/petstore/cpp-pistache/api/StoreApi.h index cde0755f13..f69875c467 100644 --- a/samples/server/petstore/cpp-pistache/api/StoreApi.h +++ b/samples/server/petstore/cpp-pistache/api/StoreApi.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/api/UserApi.cpp b/samples/server/petstore/cpp-pistache/api/UserApi.cpp index f539a61c7e..f64232454a 100644 --- a/samples/server/petstore/cpp-pistache/api/UserApi.cpp +++ b/samples/server/petstore/cpp-pistache/api/UserApi.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -54,10 +54,14 @@ void UserApi::create_user_handler(const Pistache::Rest::Request &request, Pistac try { nlohmann::json::parse(request.body()).get_to(body); this->create_user(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -69,10 +73,14 @@ void UserApi::create_users_with_array_input_handler(const Pistache::Rest::Reques try { nlohmann::json::parse(request.body()).get_to(body); this->create_users_with_array_input(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -84,10 +92,14 @@ void UserApi::create_users_with_list_input_handler(const Pistache::Rest::Request try { nlohmann::json::parse(request.body()).get_to(body); this->create_users_with_list_input(body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -97,10 +109,14 @@ void UserApi::delete_user_handler(const Pistache::Rest::Request &request, Pistac try { this->delete_user(username, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -110,10 +126,14 @@ void UserApi::get_user_by_name_handler(const Pistache::Rest::Request &request, P try { this->get_user_by_name(username, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -139,10 +159,14 @@ void UserApi::login_user_handler(const Pistache::Rest::Request &request, Pistach try { this->login_user(username, password, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -150,10 +174,14 @@ void UserApi::logout_user_handler(const Pistache::Rest::Request &request, Pistac try { this->logout_user(response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } @@ -168,10 +196,14 @@ void UserApi::update_user_handler(const Pistache::Rest::Request &request, Pistac try { nlohmann::json::parse(request.body()).get_to(body); this->update_user(username, body, response); - } catch (std::runtime_error & e) { - //send a 400 error - response.send(Pistache::Http::Code::Bad_Request, e.what()); - return; + } catch (nlohmann::detail::exception &e) { + //send a 400 error + response.send(Pistache::Http::Code::Bad_Request, e.what()); + return; + } catch (std::runtime_error &e) { + //send a 500 error + response.send(Pistache::Http::Code::Internal_Server_Error, e.what()); + return; } } diff --git a/samples/server/petstore/cpp-pistache/api/UserApi.h b/samples/server/petstore/cpp-pistache/api/UserApi.h index 7083c76430..6c589979db 100644 --- a/samples/server/petstore/cpp-pistache/api/UserApi.h +++ b/samples/server/petstore/cpp-pistache/api/UserApi.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/PetApiImpl.cpp b/samples/server/petstore/cpp-pistache/impl/PetApiImpl.cpp index b35b40899b..778117a18b 100644 --- a/samples/server/petstore/cpp-pistache/impl/PetApiImpl.cpp +++ b/samples/server/petstore/cpp-pistache/impl/PetApiImpl.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/PetApiImpl.h b/samples/server/petstore/cpp-pistache/impl/PetApiImpl.h index 7b4f3d3240..9e9f3d145b 100644 --- a/samples/server/petstore/cpp-pistache/impl/PetApiImpl.h +++ b/samples/server/petstore/cpp-pistache/impl/PetApiImpl.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.cpp b/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.cpp index 63030737b6..ef164eb054 100644 --- a/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.cpp +++ b/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.h b/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.h index 71689ae18b..c993724631 100644 --- a/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.h +++ b/samples/server/petstore/cpp-pistache/impl/StoreApiImpl.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/UserApiImpl.cpp b/samples/server/petstore/cpp-pistache/impl/UserApiImpl.cpp index 2e7b06d956..7163a560bd 100644 --- a/samples/server/petstore/cpp-pistache/impl/UserApiImpl.cpp +++ b/samples/server/petstore/cpp-pistache/impl/UserApiImpl.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/impl/UserApiImpl.h b/samples/server/petstore/cpp-pistache/impl/UserApiImpl.h index 9bde4fc572..8f22c49988 100644 --- a/samples/server/petstore/cpp-pistache/impl/UserApiImpl.h +++ b/samples/server/petstore/cpp-pistache/impl/UserApiImpl.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/main-api-server.cpp b/samples/server/petstore/cpp-pistache/main-api-server.cpp index 053fd0dbce..191b60b771 100644 --- a/samples/server/petstore/cpp-pistache/main-api-server.cpp +++ b/samples/server/petstore/cpp-pistache/main-api-server.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp b/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp index 93b2961d03..a78fb1cc7f 100644 --- a/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp +++ b/samples/server/petstore/cpp-pistache/model/ApiResponse.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/ApiResponse.h b/samples/server/petstore/cpp-pistache/model/ApiResponse.h index 3291251d8c..7ecb6c9a82 100644 --- a/samples/server/petstore/cpp-pistache/model/ApiResponse.h +++ b/samples/server/petstore/cpp-pistache/model/ApiResponse.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Category.cpp b/samples/server/petstore/cpp-pistache/model/Category.cpp index 80112511b8..2abb0c3c5e 100644 --- a/samples/server/petstore/cpp-pistache/model/Category.cpp +++ b/samples/server/petstore/cpp-pistache/model/Category.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Category.h b/samples/server/petstore/cpp-pistache/model/Category.h index 4018607b43..fa12fdc0de 100644 --- a/samples/server/petstore/cpp-pistache/model/Category.h +++ b/samples/server/petstore/cpp-pistache/model/Category.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Helpers.cpp b/samples/server/petstore/cpp-pistache/model/Helpers.cpp index 8c0e859b64..b518f8106d 100644 --- a/samples/server/petstore/cpp-pistache/model/Helpers.cpp +++ b/samples/server/petstore/cpp-pistache/model/Helpers.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Helpers.h b/samples/server/petstore/cpp-pistache/model/Helpers.h index 8c62ecda5a..9c8c02c4ae 100644 --- a/samples/server/petstore/cpp-pistache/model/Helpers.h +++ b/samples/server/petstore/cpp-pistache/model/Helpers.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Order.cpp b/samples/server/petstore/cpp-pistache/model/Order.cpp index a0bda775a5..b24cc0fce9 100644 --- a/samples/server/petstore/cpp-pistache/model/Order.cpp +++ b/samples/server/petstore/cpp-pistache/model/Order.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Order.h b/samples/server/petstore/cpp-pistache/model/Order.h index b4d4598b74..d900b633f3 100644 --- a/samples/server/petstore/cpp-pistache/model/Order.h +++ b/samples/server/petstore/cpp-pistache/model/Order.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Pet.cpp b/samples/server/petstore/cpp-pistache/model/Pet.cpp index 40699f1333..7781e283ce 100644 --- a/samples/server/petstore/cpp-pistache/model/Pet.cpp +++ b/samples/server/petstore/cpp-pistache/model/Pet.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Pet.h b/samples/server/petstore/cpp-pistache/model/Pet.h index 22eeb9570f..f23ef47832 100644 --- a/samples/server/petstore/cpp-pistache/model/Pet.h +++ b/samples/server/petstore/cpp-pistache/model/Pet.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Tag.cpp b/samples/server/petstore/cpp-pistache/model/Tag.cpp index 4a1349f0e9..b81cb82572 100644 --- a/samples/server/petstore/cpp-pistache/model/Tag.cpp +++ b/samples/server/petstore/cpp-pistache/model/Tag.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/Tag.h b/samples/server/petstore/cpp-pistache/model/Tag.h index bb5dff9f92..4b422931d7 100644 --- a/samples/server/petstore/cpp-pistache/model/Tag.h +++ b/samples/server/petstore/cpp-pistache/model/Tag.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/User.cpp b/samples/server/petstore/cpp-pistache/model/User.cpp index 9c467a10d8..66a026e9c7 100644 --- a/samples/server/petstore/cpp-pistache/model/User.cpp +++ b/samples/server/petstore/cpp-pistache/model/User.cpp @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/samples/server/petstore/cpp-pistache/model/User.h b/samples/server/petstore/cpp-pistache/model/User.h index 4b8cd2b196..1f4c17ce6a 100644 --- a/samples/server/petstore/cpp-pistache/model/User.h +++ b/samples/server/petstore/cpp-pistache/model/User.h @@ -2,7 +2,7 @@ * OpenAPI Petstore * This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * -* OpenAPI spec version: 1.0.0 +* The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).