From 450153d4e00a770df067d189a794881a80cf716f Mon Sep 17 00:00:00 2001 From: sunn <33183834+etherealjoy@users.noreply.github.com> Date: Tue, 15 Oct 2019 08:45:08 +0200 Subject: [PATCH] Add missing supporting files when prefix is provided (#4132) --- .../org/openapitools/codegen/languages/CppQt5ClientCodegen.java | 2 ++ .../src/main/resources/cpp-qt5-client/helpers-body.mustache | 2 +- .../resources/cpp-qt5-qhttpengine-server/helpers-body.mustache | 2 +- samples/client/petstore/cpp-qt5/.openapi-generator/VERSION | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CppQt5ClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CppQt5ClientCodegen.java index 73897d8cf74..29beb10a50c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CppQt5ClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/CppQt5ClientCodegen.java @@ -103,6 +103,8 @@ public class CppQt5ClientCodegen extends CppQt5AbstractCodegen implements Codege supportingFiles.add(new SupportingFile("helpers-body.mustache", sourceFolder, modelNamePrefix + "Helpers.cpp")); supportingFiles.add(new SupportingFile("HttpRequest.h.mustache", sourceFolder, modelNamePrefix + "HttpRequest.h")); supportingFiles.add(new SupportingFile("HttpRequest.cpp.mustache", sourceFolder, modelNamePrefix + "HttpRequest.cpp")); + supportingFiles.add(new SupportingFile("HttpFileElement.h.mustache", sourceFolder, modelNamePrefix + "HttpFileElement.h")); + supportingFiles.add(new SupportingFile("HttpFileElement.cpp.mustache", sourceFolder, modelNamePrefix + "HttpFileElement.cpp")); supportingFiles.add(new SupportingFile("object.mustache", sourceFolder, modelNamePrefix + "Object.h")); supportingFiles.add(new SupportingFile("enum.mustache", sourceFolder, modelNamePrefix + "Enum.h")); diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache index 9b97b53e52c..b6a8ee4b2dc 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-client/helpers-body.mustache @@ -228,7 +228,7 @@ fromStringValue(const QString &inStr, {{prefix}}Enum &value){ } bool -fromStringValue(const QString &inStr, OAIHttpFileElement &value){ +fromStringValue(const QString &inStr, {{prefix}}HttpFileElement &value){ return value.fromStringValue(inStr); } diff --git a/modules/openapi-generator/src/main/resources/cpp-qt5-qhttpengine-server/helpers-body.mustache b/modules/openapi-generator/src/main/resources/cpp-qt5-qhttpengine-server/helpers-body.mustache index 9b97b53e52c..b6a8ee4b2dc 100644 --- a/modules/openapi-generator/src/main/resources/cpp-qt5-qhttpengine-server/helpers-body.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-qt5-qhttpengine-server/helpers-body.mustache @@ -228,7 +228,7 @@ fromStringValue(const QString &inStr, {{prefix}}Enum &value){ } bool -fromStringValue(const QString &inStr, OAIHttpFileElement &value){ +fromStringValue(const QString &inStr, {{prefix}}HttpFileElement &value){ return value.fromStringValue(inStr); } diff --git a/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION b/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION index d1a8f58b388..c3a2c7076fa 100644 --- a/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION +++ b/samples/client/petstore/cpp-qt5/.openapi-generator/VERSION @@ -1 +1 @@ -4.1.2-SNAPSHOT \ No newline at end of file +4.2.0-SNAPSHOT \ No newline at end of file