Commit Graph

11877 Commits

Author SHA1 Message Date
Adrian Price
4c14c85542 Add additional properties to Java CodegenModel (#1854)
Fixes the first part of https://github.com/OpenAPITools/openapi-generator/pull/1729#issuecomment-451991109 (see https://github.com/OpenAPITools/openapi-generator/pull/1729#issuecomment-449937728). The second part was fixed by https://github.com/OpenAPITools/openapi-generator/pull/1845 (commit d65dd763d814fba356a61abeae6dd1dbc4193fd2).
2019-01-09 10:49:43 +08:00
FallenRiteMonk
9331df791f Minor Angular type improvements (#1843)
Update api.service.mustache

update samples
2019-01-09 00:30:37 +08:00
d3v-cl
9ccf872290 [DART] fix: set fields to null if json value is null. (#1798)
* fix: set fields to null if json value is null.

* rebuild dart2 petstore

* rebuild dart petstore

* rebuild petstore

* [DART]fix: set fields to null if json value is null.
2019-01-09 00:26:46 +08:00
William Cheng
293066bb0d
add options to maven plugin (#1845) 2019-01-08 21:32:51 +08:00
William Cheng
fbf570e7bd
fix unqiue name in handling forward slash (#1839) 2019-01-08 07:51:25 +08:00
William Cheng
ed5bd5ffb0
better handle of oauth (#1838) 2019-01-08 07:51:02 +08:00
Hemant Zope
233ce093e5 [C] Support for authentication methods (#1628)
* added auth support in apiClient

* added httperror response in detail

* added apikey to apiClient create

* remove unnecessary print statements

* remove freeing of apiclient object from apiclient_free function

* added auth params to apiClient_free function

* free only received data and apiClient object to be freed by user
2019-01-07 23:31:42 +08:00
William Cheng
b7971e2e3d better error message when parameter ref not defined (#1837) 2019-01-08 00:29:13 +09:00
William Cheng
1ef56b44c2
Add links to articles about openapi generator 2019-01-07 22:54:43 +08:00
William Cheng
22a3f7ee0e
Add a link to @watiko article 2019-01-07 22:45:46 +08:00
Akihito Nakano
6e4556772c Delete langs command (#1836)
* Delete langs command

* Delete "langs" from docker entrypoint script

* langs -> list

* langs -> list
2019-01-07 08:57:05 -05:00
William Cheng
549197cce5 restore c test 2019-01-07 19:01:00 +08:00
William Cheng
60776b8cb5
deprecated initialCaps (#1821) 2019-01-07 17:47:07 +08:00
sredbull
eff0c5e8d0 Added proper error response (#1814) 2019-01-07 12:19:50 +08:00
sredbull
1189362466 [JavaScript] Added plugins variable for the javascript/ES6 client (#1797)
* Added plugins variable for the javascript/ES6 client

* Ran the javascript and javascript-es6 shell script
2019-01-07 12:18:03 +08:00
William Cheng
f0f214743e
Use JS ES6 as the default (#1825)
* set JS ES6 as the default

* update doc
2019-01-07 11:43:11 +08:00
sunn
651395d426
Update base class due to failed compilation in case of plain object type with no properties or additionalProperties specified (#1826) 2019-01-06 18:20:23 +01:00
sunn
fda35ea263
Fix missing const keyword in array and maps (#1828) 2019-01-06 18:19:08 +01:00
sunn
c65ef987af
Emit worker also in response signal (#1829) 2019-01-06 18:18:20 +01:00
William Cheng
b015ac9307
use 4-space instead of tab in perl templates (#1830) 2019-01-07 00:22:24 +08:00
Akihito Nakano
bdf32775fb
Add test cases for ExampleGenerator (#1802)
* Add test case : generateFromResponseSchemaWithArrayOfModel

* Add test case : generateFromResponseSchemaWithArrayOfPrimitiveTypes

* Add test case : generateFromResponseSchemaWithModel

* Add test case : generateFromResponseSchemaWithNoExample

* Use String.format for windows

* Specify locale to prevent issues due to locale
2019-01-06 13:27:27 +09:00
William Cheng
1a2deb016b
Fix security issue with dependencies (#1820)
* fix security issue with dependency

* update samples

* update pom and sample
2019-01-05 23:30:59 +08:00
William Cheng
b25eeebf03
Update Elixir technical committee 2019-01-05 19:18:49 +08:00
William Cheng
8f561f1ef3
[C#][Refactor] Fix nullable required property in the constructor (#1819)
* add serialization test, fix nulllable reuqired

* remove vs folder
2019-01-05 18:54:29 +08:00
Marco
b931da2909 [java][webclient] Register Jackson modules on ObjectMapper (#911)
* [java][webclient] register jackson modules on object mapper

* Regenerate client

* Removed findAndRegisterModules() call

* ObjectMapper is initialized only if NOT provided by client

* Remove (now) useless DateFormat inside buildWebClient signature and regenerate client
2019-01-05 18:29:49 +08:00
Yuriy Belenko
fa9bd1f567 [Slim] Add ApiKey and OAuth authentication middleware (#1207)
* [Slim] Add fork of token middleware

This commit will be dropped, when official repo approves submitted PRs.
Right now it's for test purposes only.

* [Slim] Adds token middleware to template

* [Slim] Move auth implementation to external classes

* [Slim] Update readme

* [Slim] Add config example

* [Slim] Remove deprecated package

Considered to use dyorg/slim-token-authentication for all authentication
schemes. User needs to decode and parse Basic token himself, but it's
pretty simple task and there are many code examples in
the web. Most of time solution is two lines of code.

* [Slim] Format phpdoc comments

I've changed PHP version to 7 and updated comments to follow  main
recommendations. Used PHPCodesniffer rules are Generic.Commenting,
Squiz.Commenting, PEAR.Commenting. Of course I applied only reasonable
sniffs from this standards.

@category tag has been deleted as deprecated accordingly to
phpDocumentor offical docs.

Ref: http://docs.phpdoc.org/references/phpdoc/tags/category.html

* [Slim] Refresh samples
2019-01-05 11:32:23 +09:00
William Cheng
d35f4b08d9
Fix various typos in the templates (Ruby, C#) (#1803)
* Fix typos

* update petstore samples
2019-01-05 09:39:10 +08:00
Erik Timmers
be262384cd Change renamed user @trenneman to @eriktim (#1809) 2019-01-04 11:49:50 +08:00
William Cheng
5729ce176c
Add GenFlow to the company/project list (#1806) 2019-01-04 00:39:41 +08:00
William Cheng
3d59d8b58f
Add GenFlow to the company/project list 2019-01-03 22:31:10 +08:00
Tomer Cohen
59db7cc568 remove unnecessary words from migration-from-swagger-codegen.md (#1791)
Removed 'an existing '.
2019-01-03 18:53:58 +08:00
William Cheng
ad5184efc1
Add process utils class to add index to properties (#1796)
* add process utils to add index to properties

* fix javadoc warning
2019-01-03 16:06:22 +08:00
William Cheng
92db181d97
Fix Shippable CI (#1799)
* comment out apt-get update

* test php slim in travis

* comment out php verison check
2019-01-03 16:04:35 +08:00
Jim Schubert
8fd474d4a7 [gradle-plugin] Fix test, ensure tests run in CI (#1789)
* Update GenerateTaskDslTest to remove "Pets" array model which is no longer generated
* Ensure check on uploadArchives task
2019-01-02 17:15:01 +08:00
Akihito Nakano
af6757ccde Refactor InlineModelResolver (#1788)
* Extract a method "flattenPaths" to reduce the scope of method

* Tweak

* Rename parameter name

* Extract a method "flattenModels" to reduce the scope of method

* Rename parameter name

* Rename: models -> components

* Delete comment

* Extract a method "flattenRequestBody" to reduce the scope of method

* Extract a method "flattenParameters" to reduce the scope of method

* Extract a method "flattenResponses" to reduce the scope of method

* Tweak types

* Reduce indentation
2019-01-02 17:14:34 +08:00
Akihito Nakano
9334dd391a
Improve test codes of InlineModelResolver (#1787)
* Delete unnecessary "throws"

* Delete unnecessary cast expressions

* Tweak redundant assertions

* Delete unnecessary comment
2019-01-01 13:14:23 +09:00
Akihito Nakano
d6fa9e60c6
Add test case for InlineModelResolver: arbitrary models (#1786)
* Add test case : arbitraryObjectModelInline

* Delete legacy test case : testArbitraryObjectModelInline

* Add test case : arbitraryObjectModelWithArrayInlineWithoutTitle

* Delete legacy test case : testArbitraryObjectModelWithArrayInlineWithoutTitle

* Add test case : arbitraryObjectModelWithArrayInlineWithTitle

* Delete legacy test case :
testArbitraryObjectModelWithArrayInlineWithTitle

* Add test case : emptyExampleOnStringTypeModels

* Delete legacy test case : testEmptyExampleOnStrinngTypeModels
2019-01-01 11:51:20 +09:00
Akihito Nakano
6abb9ddf30
Add test case for InlineModelResolver: arbitrary response (#1785)
* Add test case : arbitraryObjectResponse

* Delete legacy test case : testArbitraryObjectResponse

* Add test case : arbitraryObjectResponseArray

* Delete legacy test case : testArbitraryObjectResponseArray

* Add test case : arbitraryObjectResponseArrayInline

* Delete legacy test case : testArbitraryObjectResponseArrayInline

* Add test case : arbitraryObjectResponseWithAdditionalProperty

* Delete legacy test case : testArbitraryObjectResponseMapInline
2019-01-01 10:27:52 +09:00
Akihito Nakano
e559474880
Add test case for InlineModelResolver: arbitrary request body (#1784)
* Uncomment a valid test case

* Add test case : inline request body with title

* Delete legacy test case

* Delete unused import

* Delete legacy test case which is already implemented by other test

see InlineModelResolverTest#resolveInlineArrayResponseWithTitle()

* Delete legacy test case which is covered by other test

* Add test case : arbitraryObjectBodyParam

* Delete legacy test case : testArbitraryObjectBodyParam

* Add test case : arbitraryObjectRequestBodyProperty

* Delete legacy test case : testArbitraryObjectBodyParamInline

* Add test case : arbitraryRequestBodyArray

* Delete legacy test case : testArbitraryObjectBodyParamWithArray

* Add test case : arbitraryRequestBodyArrayProperty

* Delete legacy test case
2019-01-01 07:28:29 +09:00
Akihito Nakano
354db2f3e6 Fix: Inline models can't be generated (#1768)
* Add a test case

* Fix that the inline models couldn't be flatten when "components" doesn't exist

* Rename yaml file

* Rename method name
2018-12-31 17:00:28 +08:00
Akihito Nakano
f96e64bd9e Add test case for InlineModelResolver: inline object response with additionalProperties (#1781)
* Add test case : inline object response with additionalProperties

* Delete legacy test case
2018-12-31 14:36:30 +08:00
William Cheng
3ec90a86cb
Add an option to generate the alias (map, array) as model (#1729)
* add option to generate alias as model

* fix issue due to incorrect merge
2018-12-31 11:59:58 +08:00
William Cheng
2f6381cb19
Add nullable support to C# client (refactor) (#1775)
* add nullable support to c# client (refactor)

* clean up methods

* move typemapping to constructor
2018-12-31 10:44:02 +08:00
Akihito Nakano
5730f6224a Delete unused method (#1744)
* Delete unused method

* Delete unused property "typeMapping"

* Delete unused "import" declaration
2018-12-31 10:10:07 +08:00
Christophe Bornet
0fca90133c Use JsonNullable wrapper on nullable/x-nullable fields (#1762)
* Use JsonNullable wrapper on nullable/x-nullable fields

Fix #1250

* update samples
2018-12-31 10:04:26 +08:00
William Cheng
2c051f265c
Add an option to use reflection in equals, hashCode (Java client) (#1767)
* add option to use reflection in equals, hashcode (java)

* add model test template to java client only

* update pestore samples

* update java samples

* update doc

* update usage, remove unused file
2018-12-31 10:03:05 +08:00
Yuriy Belenko
e8ac630ca5 [Slim] Encode path to support non-latin characters (#1687)
* [Slim] Add encodePath method

* [Slim] Add tests for encodePath method

* [Slim] Use unescaped path in router

Both variables basePathWithoutHost and path are already urlEncoded in
codegen itself. Builtin html encoding in mustache is redundant. We can
use these raw codegen values with no fear.

* [Slim] Refresh samples
2018-12-31 10:02:45 +08:00
Erik Timmers
a0e5b74b2b [elm] Add support for sending headers (#1704) 2018-12-31 09:58:45 +08:00
Akihito Nakano
321416e960
Add test case for InlineModelResolver: inline array response (#1778)
* Add test case : inline array response

* Add test case : inline array response with title

* Delete legacy test cases
2018-12-30 17:53:36 +09:00
William Cheng
2e727f6dc7
fix group parameter logic (#1779) 2018-12-30 16:50:21 +08:00