* The get method template is modified to return the value of the enum instead of the enum itself.
* Update of the Petstore CXF server sample
* Update of the Petstore CXF client sample
* Update of the Petstore CXF server annotated base path sample
* Update of the Petstore CXF server non spring application sample
`unicode` does not exist in py3, therefore since six is already imported
switch to using `six.u` so that `unicode` is used on py2 and `str` is used
on py3.
The linting results for the generated samples are as follows
where the first number is the BEFORE and the second is AFTER.
pyclient 7714 vs. 120
pyclient3 7717 vs. 120
pyclient3-asyncio 7584 vs. 120
pyclient-tornado 7633 vs. 120
pyclient3-tornado 7633 vs. 120
For the complete details please see the following gist.
https://gist.github.com/kenjones-cisco/2eb69a7e8db75e9fd53789f01570d9f2
Enforces linting for python clients by running flake8 for the generated
python client.
* add support for async routes/endpoints
you can now set --optional-properties async=true to generate
a nancyfx server stub that uses asynchronous programming.
(cherry picked from commit 126869cb0b967e8063417e11993cf6326ce8ffd4)
* add nancyfx-petstore-server-async.sh to generate sample of async nancyfx.
* Rename async => asyncServer
* update bin/nancyfx-petstore-server-async.sh
* rename async => asyncServer in api.mustache + small bugfix
* run ./bin/nancyfx-petstore-server.sh and ./bin/nancyfx-petstore-server-async.sh
* remove additional new line in api.mustache + add space after if
* run ./bin/nancyfx-petstore-server.sh and ./bin/nancyfx-petstore-server-async.sh
* [Rust] Use serde Value for objects
This hopefully fixes the previous TODO; it at least fixes compilation
errors for the specific swagger model I'm working with.
* [Rust] Update Cargo.toml to specify versions
Letting the version float freely is scary, to say the least.
This gives it a better chance at being future-proof.
When the crate author had a recommended selector I picked that,
otherwise I went semver compatible.
* [Rust] Regenerate the example
* Add configuration to split input and output bean validations. When useBeanValidation is used, the variable are created in the application.conf file and can be tweaked by environment. For example, dev and stage can have true to both but only have input in prod.
* Refactor of mustache tags for more clarity
* sample generation with refactor
* Fix a couple of bugs with the fake-endpoint yaml but there is still 2 cases where it doesn't work.
* Remove Accept request header from api signature
* Inject HttpServletRequest to get request header and clean templates
* Use constructor injection for HttpServletRequest
* Implement example in default controller responses
The linting results for the generated samples are as follows
where the first number is the BEFORE and the second is AFTER.
flaskConnexion 1843 vs. 20
flaskConnexion-python2 1841 vs. 19
For the complete details please see the following gist.
https://gist.github.com/kenjones-cisco/edc9d71ef7fd2bf23714ecbb693d52b3
Enable the creation of the entrypoint so that the server can be started
using a named command instead of needing to always use `python -m` to
run the server.
* Removed commented code
* Input validation is now supported as strict JSON validation
* [PHP][Symfony] Improve the implementation
Closes#6614
* Generated code is tested to assure it compiles and updated README to dynamically load dependencies via composer
* Updated shell script because shippable tests were failing
* Inclusion of API documentation in CXF Server stub generation
* Inclusion of API documentation in CXF client generation
* Update of the Petstore CXF server sample
* Update of the Petstore CXF client sample
* Update of the Petstore CXF server annotated base path sample
* Update of the Petstore CXF server non spring application sample
* Changed {{{appDescription}}} to {{appDescription}} to use the HTML-escaped value in handling special characters like <, > in the description following the correction made by @wing328
* Update of the Petstore CXF samples
* Included Open Systems International in the list of companies using Swagger Codegen
* Force Jackson to use the real names of the properties of the Data type defined in the YAML
* Update of the Petstore CXF server sample
* Update of the Petstore CXF client sample
* Update of the Petstore CXF server annotated base path sample
* Update of the Petstore CXF server non spring application sample
* Changed {{name}} for {{baseName}} following the correction posted by @wing328
* Update of the Petstore CXF server sample
* Adds the ability to create code for an interface-based jaxrs client.
* Adds shell script and sample files for jaxrs-spec-interface
* rebase into adds shell
* Fixes bug in creation of Produces/Consumes in method annotation. Allows for instance "application/json; charset=utf-8"
* Fixes generated pom.xml
* Generate pom.xml by default
* Prettier output from api.mustache
* Fixes bug in mediatype, allowing charset-specification in swagger.yaml.
* Merges generation of interface-based jaxrs client/api into jaxrs-spec.
* Moves jaxrs-spec server interface to match location of jaxrs-spec server
* Makes Generated-annotation in genereated classes slightly prettier.
* Retrofit2: Return ResponseBody if response if file.
Until now
--------------------
If a swagger endpoint returned a file (e.g. an image), then the Retrofit2
template has choosen the return type java.io.File. However, retrofit cannot
deal with this and throws a com.google.gson.stream.MalformedJsonException.
New:
-------------------
If a swagger endpoint returns a file, then the corresponding Retrofit2 endpoint
will return a okhttp3.ResponseBody which can be used to retrieve the file.
* fix Interface Prefix
* Retrofit2: Return ResponseBody if response if file.
Until now
--------------------
If a swagger endpoint returned a file (e.g. an image), then the Retrofit2
template has choosen the return type java.io.File. However, retrofit cannot
deal with this and throws a com.google.gson.stream.MalformedJsonException.
New:
-------------------
If a swagger endpoint returns a file, then the corresponding Retrofit2 endpoint
will return a okhttp3.ResponseBody which can be used to retrieve the file.
* Add the option packageContext for nancyFx which allows a better adjustment of the namespace.
* run nancyfx-petstore-server.bat
* upgraded zend-expressive from version 1 to 2
* Changed error handler for compatibility with Zend Expressive 2
* generated newest sample files for Petstore ze-ph
* removed ErrorMiddleware because it is never been used anymore. Regenerated samples
* removed ErrorMiddleware Template from Codegen
* remove ErrorMiddleware from petstore sample
* Fixed some code styles
* regenerated ze-ph samples with corrected code styles
* added new line at the end of the file
* Fix Uuid parse
* Add isString = true when property is Uuid
This will not break previous code
* Update conversionBegin.mustache
* Update conversionEnd.mustache
* - Added javax.validation.Valid annotation to modules/swagger-codegen/src/main/resources/JavaJaxRS/spec/bodyParams.mustache
- Added bean validation and api description to modules/swagger-codegen/src/main/resources/JavaJaxRS/spec/headerParams.mustache
- Added api description to modules/swagger-codegen/src/main/resources/JavaJaxRS/spec/queryParams.mustache
- Added interfaceOnly parameter management to modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaJAXRSSpecServerCodegen.java to generate only interfaces and models.
- Added interfaceOnly parameter management to modules/swagger-codegen/src/main/resources/JavaJaxRS/spec/api.mustache
- Added throws java.lang.Exception to modules/swagger-codegen/src/main/resources/JavaJaxRS/spec/api.mustache
* Run ./bin/jaxrs-spec-petstore-server.sh
* jaxrs-spec: javax.validation.Valid model attributes for array items
* Run ./bin/jaxrs-spec-petstore-server.sh
* Removals of most of the warnings found by lint
* Removals of most of the warnings found by lint (PART 2)
* Removals of most of the warnings found by lint (PART 3)
* Removals of most of the warnings found by lint (PART 4)
* Removals of most of the warnings found by lint (PART 5)
* Fix conversion error
* Removal of unnecessary import. Other will need more complex login in the generator itself (not in the mustache files)
* Add missing imports + fix to the regex. Generation of the samples