You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When generating the interface for the sample json using cpp-restsdk generator, the resulting cpp is not compilable. One error is the generated helper function
template <typename T>
utility::string_t toString(const T value)
{
std::ostringstream out;
out << std::setprecision(std::numeric_limits<T>::digits10) << std::fixed << value;
return out.str();
}
where std::ostringstream out; should be utility::ostringstream_t out;
The main problems are with the generated HttpContent class. A lot of non-existing method calls are generated, like fromJson, fromMultipart, get, toMultipart. Also non-existing constructors are called on HttpContent.
Description
When generating the interface for the sample json using cpp-restsdk generator, the resulting cpp is not compilable. One error is the generated helper function
where
std::ostringstream out;
should beutility::ostringstream_t out;
The main problems are with the generated
HttpContent
class. A lot of non-existing method calls are generated, likefromJson
,fromMultipart
,get
,toMultipart
. Also non-existing constructors are called onHttpContent
.openapi-generator version
tried with 3.3.4 and 4.0.0 (latest master)
OpenAPI declaration file content or url
gist link to the json file:
https://gist.github.com/Findus79/83044968492b225968c2c4bb749d2e21
Command line used for generation
java -jar openapi-generator-cli-3.4.4.jar generate -g cpp-restsdk -i input\openapi-cpprestsdk.json -o output
and
java -jar openapi-generator-cli-4.0.0.jar generate -g cpp-restsdk -i input\openapi-cpprestsdk.json -o output
The text was updated successfully, but these errors were encountered: