Commit Graph

3661 Commits

Author SHA1 Message Date
wing328
cd0ec4ed71 Merge branch '2.3.0' of https://github.com/swagger-api/swagger-codegen into 2.3.0 2017-06-28 15:36:14 +08:00
wing328
e7561a11f4 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-28 15:35:24 +08:00
Brendan Burns
91f470e41f Add a function for injecting your own Authentication into the Typescript-node client (#5865) 2017-06-28 00:23:40 +08:00
Tony Tam
1e2465735b [2.3.0] Update Swagger Codegen to v1.5.15 (#5929)
* updated versions

* match fix in 2.2.x branch

* updated with 73df07d64c

* regenerate pom.xml for jaxrs-cxf-petstore-server-annotated-base-path

* regenerate pom.xml for jaxrs-cxf-petstore-server-non-spring-application
2017-06-28 00:13:52 +08:00
Tony Tam
73df07d64c Merge branch 'master' into issue-5753 2017-06-26 13:15:00 -07:00
wing328
1011b3ae7c Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-27 00:42:19 +08:00
wing328
5fbb674cac fix retrofit okhttp version 2017-06-27 00:41:08 +08:00
wing328
e84b789f78 remove unused files from C# petstore folder 2017-06-26 23:41:22 +08:00
wing328
49dbb51957 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-26 23:39:04 +08:00
wing328
522d704f7a [Java] Update dependencies for Java clients (#5926)
* update dep for java jersey1, jersey2

* update sbt dependency for jersey2

* update dep for java okhttp-gson, resteasy, resttemplate

* update dep for java retrofit 1.x, 2.x

* update java petstore samples
2017-06-26 23:18:45 +08:00
wing328
6eb987919f minor fix to js promise test cases 2017-06-26 21:48:44 +08:00
Dennis Kieselhorst
68d878c244 update to latest CXF release (#5923) 2017-06-26 15:55:34 +08:00
wing328
02f30a27f9 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-23 22:09:45 +08:00
wing328
5b4e8a8ed5 [JavaScript] fix JS shell scripts, add log to show template version (#5907)
* fix JS shell script, add log to show es version

* change CLI option default value for useES6

* fix shell script in JS ES6 promise

* fix windows batch files

* set useES6 to false
2017-06-23 22:09:07 +08:00
wing328
f32dd6f7bc Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-23 15:24:04 +08:00
Stanislav Bondarenko
69ce921371 Python - Increase range of valid status codes (#5901)
swagger-client shouldn't throw ApiException if status code in range 200-299
2017-06-23 11:31:30 +08:00
wing328
9c3476b014 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-22 22:42:01 +08:00
wing328
999c4dbfb5 Merge branch '2.3.0' of https://github.com/swagger-api/swagger-codegen into 2.3.0 2017-06-22 22:41:51 +08:00
wing328
d35239c661 recursively add import for parameters (#5891) 2017-06-21 21:35:45 +08:00
Austin Green
81d69eef1c [Typescript-Angular2] Removed invalid BASE_PATH InjectionToken type (#5866) 2017-06-21 03:39:59 +08:00
wing328
8d0c7128b0 add option to specify c# client path in powershell generator (#5887) 2017-06-21 00:58:29 +08:00
wing328
adedaf6adc Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-20 22:20:23 +08:00
wing328
e53b3a03aa [PowerShell] Add PowerShell API client generator (WIP) (#5789)
* add powershell generator (wip)

* minor fix to api template

* rename model files

* Powershell generator fix (#11)

* Fix typo

pacakge -> package

* Add missing `petstore` subfolder to $ClientPath

* Resolve $ClientPath to absolute path

Start-Process needs WorkingDirectory to be absolute

* Fix spaces in variable name

${ somevar } is a vairable that literally has spaces in name. We need to
temporarily redifine mustache delimiters so we can generate var. names
without spaces.

* Fix typo

Remove stray `r`

* Fix *.ps1 import in module

Directory structure has changed + we should export functions using
manifest.

* Remove erroneous file

* various fixes and enhancements

* remove nullable for string

* change function name based on feedback by beatcracker

* set index to start at 0

* fix file type

* Powershell generator fix 1 (#12)

* Add closing curly brace

* Fix duplicated '['

* Get FunctionsToExport using AST

Discussion: swagger-api/swagger-codegen#5789

* add guid option to powershell generator

* add test files, remove docs

* fix array of items

* clean up powershell comment, update model/api test files
2017-06-20 22:20:05 +08:00
wing328
c4356dd9c3 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-20 22:18:28 +08:00
Vlad Frolov
c26b5a1e1b [JavaScript] Fixed *WithHttpInfo methods in 'usePromises' mode to be ES5 compatible (#3654) (#4902) (#5871) 2017-06-20 16:27:07 +08:00
Vlad Frolov
3546361b33 [JavaScript] Added README section for Webpack configuration (howto disable AMD) (#3466) (#5872) 2017-06-20 16:25:06 +08:00
stkrwork
8ab2b84c97 [CPP] [CPPREST] first steps on fixing the template (#5877)
* - Added Restbed Generator

* - Added Json processing functions to model
- Removed unnused code from restbed codegen class
- Added response header processing to api template

* Changed it to respect alphabetical order

* Made the string joining java 7 compatible

* Added samples

* First step in fixing the cpp rest template
regenerated new samples

TODO: Fix the other functions

* Updated samples
2017-06-20 01:29:42 +08:00
wing328
9f83a1adb1 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-19 23:17:35 +08:00
sabras75
24c55d1f0e Fix#5856 - Add support for PATCH (#5875)
* Changing QBuffer to use a QByteArray solves the issue for me since there is no real use-case for using a QBuffer.

Documentation of QT5 states:

QBuffer::QBuffer(QByteArray *byteArray, QObject *parent = Q_NULLPTR)

Constructs a QBuffer that uses the QByteArray pointed to by byteArray as its internal buffer, and with the given parent. The caller is responsible for ensuring that byteArray remains valid until the QBuffer is destroyed, or until setBuffer() is called to change the buffer. QBuffer doesn't take ownership of the QByteArray.

Since the variable “request_content” is allocated on the stack, this is clearly wrong and a bug. The construction of QBuffer is designed this way so that whenever you write to the buffer, it is also written to the byte array that it is pointing to

* Add a retro-compatible solution based on QNetworkAccessManager SourceCode

* update samples
2017-06-19 23:08:32 +08:00
wing328
4fb4887fec pod install for swift3 clients 2017-06-19 15:17:30 +08:00
wing328
502b6eac00 Redo #5569 to 2.3.0 branch (#5869) 2017-06-19 12:02:12 +08:00
wing328
c988afa766 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-19 11:23:58 +08:00
wing328
3a32857790 PR to roll back #5569 (#5868) 2017-06-19 11:19:21 +08:00
wing328
84334146f9 better code format for cpprest 2017-06-19 09:59:19 +08:00
wing328
b5411a94f0 update swfit3 petstore samples 2017-06-19 01:29:41 +08:00
wing328
3ad576a53d update js es6 samples 2017-06-19 01:21:22 +08:00
Kevin Murphy
aa37b9747f [javascript] Use arrow function with usePromises in ES6 ApiClient.js for superagent callback to preserve this context (#5814) 2017-06-19 00:27:52 +08:00
Tony Tam
9286e26162 updated versions 2017-06-16 11:49:32 -07:00
Ahmet Taha Sakar
3ced146a65 Swift3 configuration (#5725)
* added headers to makeRequest function for swift3 template

* Added configuration file to Swift3 template

* added comments about the value read only once

* added comments about the value read only once

* comments fix

* Added Configuration.swift to Project File

* swift 3 promisekit, rxswift updates
2017-06-17 00:25:03 +08:00
wing328
1f1e92d964 update run xcodebuild command for objc client to reduce log 2017-06-16 17:28:57 +08:00
SiMing Weng
32a6f19933 [Java][RestTemplate] fix compilation issue with API client (resttemplate) (#5832)
* adapt the resttemplate target for the threeten Time API

* add threeten dependencies to build.gradle

* fix missing dollar sign

* fix missing dollar sign
2017-06-16 00:58:11 +08:00
Paŭlo Ebermann
1a803af54a Update samples for typescript-angular2. (#5826) 2017-06-15 22:17:02 +08:00
wing328
fee54157c0 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-15 17:14:39 +08:00
wing328
410b2d301f update c# petstore samples 2017-06-15 16:33:31 +08:00
wing328
5d03905a63 update spring petstore sample 2017-06-15 15:41:21 +08:00
Lorenzo Nicora
01100d56f0 [spring] improve build-time code generation, for CI and maven integration (#5545)
* Do not generate pom.xml and README.md when interfaceOnly=true #5542

* New swaggerDocketConfig option, to generate Spring configuration class for Swagger Docket bean. Ignored when interfaceOnly=false or library=spring-cloud #5542

* Updated tests running ./bin/spring-all-petstore.sh

* Run ./bin/spring-all-petstore.sh
2017-06-15 15:37:10 +08:00
wing328
e58342bacb udpate spring samples 2017-06-15 14:33:16 +08:00
Moscagus
f2276e5b35 Fix for issue #5777 - java/jersey2 ApiClient.invokeAPI doesn´t close the Response object (#5782)
* Update ApiClient.mustache

Fix for issue #5777

* Update ApiClient.mustache

* Create ApiClient.mustache

* Run java-petstore-jersey2.sh
2017-06-15 00:45:14 +08:00
wing328
b21e0ca763 update Java petstore samples 2017-06-15 00:24:37 +08:00
Michael Kourlas
d20f83e643 [Java] Fix for issue #3638: Generated Java APIs incorrectly encode commas in certain query parameters (#4908)
* Fix for issue #3638

* Update tests for fix for issue #3638

* Fix bug when queryParams and collectionQueryParams are both specified

* Update tests

* Add certain tests back, address CI failures
2017-06-15 00:20:04 +08:00
Paŭlo Ebermann
4b9988c4f2 Update samples for several language (just whitespace changes, reordering, VERSION) (#5828)
* Update samples for several languages.

Just whitespace changes and some reordering where the order doesn't matter.

* Adding generated .swagger-codegen/VERSION files.
2017-06-14 01:17:31 +08:00
Paŭlo Ebermann
29db258e65 Update samples for akka-scala. (#5825) 2017-06-14 00:48:31 +08:00
Paŭlo Ebermann
b288991c6c Updating samples for csharp. (#5822) 2017-06-14 00:41:53 +08:00
wing328
d6c717263c [Python] add project name to setup.py in python client (#5836)
* add project name to setup.py in python client

* update python README to use project name

* add cli option project name for python
2017-06-14 00:18:54 +08:00
wing328
2bc4710e36 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-12 20:57:26 +08:00
wing328
2c7cd07cc3 add back petstore-security-test/typescript-angular 2017-06-12 20:55:53 +08:00
wing328
ab1ecbff38 remove petstore-security-test/typescript-angular folder 2017-06-12 20:52:40 +08:00
wing328
1da52bf8ba Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-11 21:43:34 +08:00
wing328
8224688ca3 Merge branch '2.3.0' of https://github.com/swagger-api/swagger-codegen into 2.3.0 2017-06-11 21:40:46 +08:00
wing328
12bcb18e9e Merge branch 'java-spring-throw-exceptions-#5686' of https://github.com/stevecookform3/swagger-codegen into stevecookform3-java-spring-throw-exceptions 2017-06-11 17:30:53 +08:00
wing328
2d385d8bcb update retrofit2 dep (#5820) 2017-06-11 16:12:04 +08:00
wing328
b7fe612cc7 minor code format enhancement to swift3 client 2017-06-11 13:31:45 +08:00
Jason Gavris
ef8365ecd2 [Swift3] Fix handling of query item with array value (#5684) 2017-06-11 12:30:51 +08:00
wing328
7cddd17acc [Java] Add JSON-patch support to other Java API clients (#5808)
* add JSON-patch support to other Java API clients

* minor fix to java jersey1 json check
2017-06-09 21:46:40 +08:00
Brendan Burns
53bd931f5c Add JSON-patch as a JSON mime-type (#5764) 2017-06-09 16:47:38 +08:00
Björn Petersen
e9a0d7ea83 Add android dependency to pom if 'parcelableModel' is set (#5801) (#5802)
* Add android dependency to pom if 'parcelableModel' is set

* Update java-okhttp-gson-parcelableModel sample
2017-06-09 16:16:53 +08:00
Jim Schubert
dabf01c3fa [kotlin] support collection format multi (#5792)
* [kotlin] support collectionFormat:multi

Adds "multi" support to collections.

Also changes generic lists (List<T>) to arrays. Generic lists and nested
lists can be problematic and require customized json factories. The
previous implement appeared to work because the results in the test were
LinkedHashMap with count greather than 0. The functional test has been
updated to force serialization and verify the results.

* [kotlin] Regenerate sample

* [kotlin] Update model test for Array changes
2017-06-09 15:40:18 +08:00
wing328
022eb0d379 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-09 15:24:53 +08:00
Romain d'Alverny
73f5266596 [Swift3] Set more liberal Swift3 decoder, behind lenientTypeCast option (#5795)
* [Swift3] Add lenientTypeCast option

When set to true, this generates a client JSON decoder
that will accept and cast mistyped values.

Here:
 - String => Bool ("true" instead of true),
 - String => Int ("123" instead of 123),
 - NSNumber => String (123 instead of "123").

The point is to allow the same client code to handle several
server implementations that may (sadly) not be up to spec,
or still be "evolving".

The conversion is not guaranteed if the input

Not a perfect/complete solution, not sure if it should be
activated along other casts, so kept behind an option.

* Update Petstore client code
2017-06-08 09:10:21 +08:00
Akihito Nakano
4612c12560 [PHP] Add support for async requests (#5771)
* Add xxxAsyncWithHttpInfo

* Add xxxAsync

* Tweak doc comment

* apply DRY principle to the creation process for request

* Fix undefined variable $statusCode

* error handling

* Fix undefined variable $url

* Tweak syntax

* Update samples

run './bin/php-petstore.sh'

* Update samples (security)

run './bin/security/php-petstore.sh'

* Fix doc comment

xxx(Async|AsyncWithHttpInfo) returns \GuzzleHttp\Promise\PromiseInterface

* Update samples (./bin/php-petstore.sh)

* Update samples (./bin/security/php-petstore.sh)

* Add AsyncTest
2017-06-07 20:35:28 +08:00
Ralph Langendam
ec19e8f407 Fixed minor compiler error and warning (#5762)
* 5762 Fixed minor compiler error and warning

* 5762 Regenerated cpprest petstore client
2017-06-07 18:37:45 +08:00
Trent Albright
676e2a04f5 Fix issue with buffered sink handling in OkHttp (#5786)
* Fix issue with buffered sink handling in okhttp

Fixes unexpected end of stream exceptions when using the okhttp-gson library
and making asynchronous calls.

* update petstore samples for okhttp-gson

$ ./bin/java-petstore-okhttp-gson.sh
$ ./bin/security/java-petstore-okhttp-gson.sh

* WIP: trigger ci
2017-06-07 18:15:06 +08:00
Vlad Frolov
6a986975e4 [javascript] Fixed fs files support for Electron (#5765) 2017-06-07 17:01:47 +08:00
wing328
6183960d86 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-06 17:11:49 +08:00
Kevin Murphy
6239ec0807 [javascript] Mark "fs" package as absent in browser in package.mustache (#5768) 2017-06-06 17:09:50 +08:00
Kevin Murphy
151d1b2783 [javascript] Fix documentation for ES6 ApiClient (#5783) 2017-06-06 16:03:36 +08:00
wing328
0b998f0684 add xcpretty to objc test output 2017-06-06 15:23:15 +08:00
wing328
001960a2c2 remove podfile for promisekit/rxswift of swift3 petstore 2017-06-06 00:34:22 +08:00
wing328
87bbbc1a1b Merge remote-tracking branch 'origin/master' into 230_merge_master 2017-06-05 23:27:11 +08:00
wing328
6ee332a513 [Swift] Fix issue with Swift Petstore integration tests due to pod install (#5774)
* add pod file for swift3

* skip pod install

* avoid pod install in swift3 petstore (promisekit,rxswift)

* use https instead of http for cocoapod spec

* avoid timeout in swift3 test
2017-06-05 22:22:56 +08:00
wing328
faf082589d Enable Travis CI tests for Swift, ObjC clients and move some tests to CircleCI (#5687)
* enable travis CI tests for swift, objc, move some tests to circleci

* fix comment in xml file

* use xcode8.3

* use ruby 2.2.5

* fix objc core data pom.xml

* use cocoapods 1.2.1

* use xcpretty for clearer test results

* fix pom with relative path to script

* comment out objc test

* fix xcpretty exit code

* add && exit ${PIPESTATUS[0]} for swift3 xcodebuild script

* use xcode 8.2

* update promisekit version for swift 2x, 3x

* add pod repo update

* remove Pods directory

* update swift dependencies to the latest version

* update podfile.lock

* rollback Alamofire to 4.0 for swift3

* fix swift3 rxswift api cliiet

* fix testDeletePet test in Swift3 rxswift petstore

* update clojure petstore

* comment out clojure test in travis (already covered in circleci)

* run pestore server locally

* use wing328/swagger-samples to run petstore

* run petstore server in the background

* test ruby petstore client

* add /Users/travis/.cocoapods/repos/master to cache

* add back ruby test, use public pestore server

* add back bash client test

* add npm config set registry to avoid time out

* use docker branch in swagger samples

* remove bash test

* show go version, reorder

* debug go petstore client

* reinstall go

* comment out pod repo update

* uncomment pod repo update

* test go in circleci

* remove go from travis test

* brew install sbt
2017-06-05 15:43:20 +08:00
wing328
40163b26d2 update objc petstore to use petstore.json 2017-06-05 12:25:51 +08:00
Zack Lemmon
f3da691a72 Fix typo in Ruby examples/mustache files (#5773) 2017-06-05 11:19:29 +08:00
wing328
4fd52d17c5 minor build warning fix for C# client 2017-06-05 01:05:19 +08:00
Jim Schubert
bc8fe0fd03 [csharp] date proper format (#5734)
* [csharp] Honor Swagger/OpenAPI 'date' format

Per spec
(https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types),
DateTime instances defined as 'date' datatype need to be serialized as
defined by full-date - RFC3339, which has the format:

full-date       = date-fullyear "-" date-month "-" date-mday

ref:
https://xml2rfc.tools.ietf.org/public/rfc/html/rfc3339.html#anchor14

see #5513
see #5531

* [csharp] Regenerate sample

* [csharp] Include date format test
2017-06-05 00:57:00 +08:00
Arne Jørgensen
d5b3cc0534 [PHP] Fix date format serialization (#5754)
* [PHP] Honor Swagger/OpenAPI 'date' format

Per spec
(https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types),
DateTime instances defined as 'date' datatype need to be serialized as
defined by full-date - RFC3339, which has the format:

full-date       = date-fullyear "-" date-month "-" date-mday

ref:
https://xml2rfc.tools.ietf.org/public/rfc/html/rfc3339.html#anchor14

see #5531
fixes #5607

* [PHP] Add `date` and `date-time` serializer tests

See #5531
See #5607

* [PHP] Improve codestyle of generated code

* [PHP] Regenerate PHP Petstore sample

* [PHP] Regenerate PHP Security sample
2017-06-05 00:47:56 +08:00
davidgri
00f2dc422d Issue5613 (#5616)
* Fixed Issue5162 consumes in GET-Methods

* Fixed Issue5613

* Ran the shell scripts under bin

* Tab removed
2017-06-05 00:38:43 +08:00
baartosz
d7202a7c76 [php] 2.3 - fix form params json encoding (#5701)
* fixed tests expectations not compatible with phpunit 4

* added test and endpoint definition, updated template

* regenerated sample

* regenerated security sample
2017-06-05 00:36:40 +08:00
Cliffano Subagio
9bc8f37aa6 [javascript] Fix empty response body when schema type is string (#5759)
* [javascript] Fix response body when return type is String.

* [javascript] Regenerate javascript petstores with fixed String return type.
2017-06-05 00:20:11 +08:00
Jim Schubert
ef07a02a01 [kotlin] Support nested enums in models (#5769)
* [kotlin] Add model enum support

Model variables marked isEnum=true are nested class enums. Top-level
enums will not be isEnum=true, but rather have a datatype specific to
the enum's type.

* [kotlin] Regenerate client sample
2017-06-05 00:04:58 +08:00
wing328
879149bb69 Revert "[javascript] Added README section for Webpack configuration (closes #3466) (#5767)" (#5770)
This reverts commit 54f5d73ee2.
2017-06-04 16:52:50 +08:00
Vlad Frolov
54f5d73ee2 [javascript] Added README section for Webpack configuration (closes #3466) (#5767) 2017-06-04 15:42:41 +08:00
sdoeringNew
ffc0d32b9c #5712 put @JsonValue to appropriate place in generated enum, add TypeAdapter for Gson enums, enhance tests (#5713) 2017-06-02 16:03:32 +08:00
wing328
08a11c1d75 fix c# net35 issue, add xml doc to new C# class (#5756) 2017-06-01 07:53:35 +08:00
wing328
98684d872c Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-01 07:10:03 +08:00
Jim Schubert
b671129557 [csharp] Refactor Configuration usage (#5740)
* [csharp] refactor ApiClient and Configuration usage

* # This is a combination of 2 commits.
# The first commit's message is:

[csharp] refactor ApiClient and Configuration usage

[csharp] Regenerate sample

# This is the 2nd commit message:

[csharp] Simplify setting apikey/prefix/headers

* # This is a combination of 2 commits.
# The first commit's message is:

[csharp] refactor ApiClient and Configuration usage
* Simplify setting apikey/prefix/headers
*  Regenerate sample

# This is the 2nd commit message:

[csharp] Pass-through configuration timeout to client

* [csharp] refactor ApiClient and Configuration usage

* Simplify setting apikey/prefix/headers
* Regenerate sample

* [csharp] Regenerate all client samples

* [csharp] regenerate .net standard/core samples

* [csharp] Fix Timeout diff between netstandard and non-netstandard

* [csharp] Resolve additional netStandard issues after merge

* [csharp] Update doc for Configuration usage
2017-06-01 06:06:36 +08:00
Jonathan Leitschuh
d6f2424152 Fix spring generated controller annotations only generating for first return type (#5399)
Fixes the spring java code generator so that the ApiResponse fields are populated correctly
on the controller.

Related to #4693
2017-05-31 17:27:32 +08:00
imgx64
bee999056a [typescript-angular2] Avoid tslint "Unused import" warnings (#5723)
Move the tslint comment that disables `no-unused-variable` to before the
import statements, to avoid "Unused import" warnings
2017-05-31 17:13:22 +08:00
stevecookform3
b185d03a1b update Spring petstore examples 2017-05-31 09:48:34 +01:00
wing328
0a8e845e47 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-31 16:30:52 +08:00
wing328
6473949737 Merge branch 'kotlin-api-model-docs' of https://github.com/jimschubert/swagger-codegen into jimschubert-kotlin-api-model-docs 2017-05-31 00:28:08 +08:00
Jim Schubert
23cf641e8a Kotlin client lists (#5729)
* [kotlin] array->List instead of Array

Serialization to/from primitive arrays can cause issues with valid
responses. This commit considers swagger 'array' types as 'List' which,
although not as memory efficient should provide a cleaner interface for
users (and avoid serialization issues).

Also, updates README.md to list new generator and excludes
folder at samples/client/kotlin/bin/, which is not used.

* [kotlin] Move sample under conventional directory

samples/client/kotlin/ -> samples/client/petstore/kotlin/

Updated new.sh to generate client/server/docs into similar structure.
Current documentation generators (cwiki, html, html.md, html2) aren't
following a convention like client/server generators.
2017-05-31 00:18:37 +08:00
wing328
4cffea4626 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-30 15:28:21 +08:00
Jim Schubert
87265d9ac7 [kotlin] api/model docs
This commit adds Api/Model/Auth documentation to the generated
README.md. Because auth support is not yet fully implemented (users can
manually set default headers globally), there aren't examples for helper
auth methods.

Models with inline enums document allowed values rather than pointing to
a generated enum class.

Two global additionalProperties were added (generateApiDocs,
generateModelDocs) to allow templates to conditionally display
documentatoin depending on these mutually exclusive settings. All
current generators supporting docs will attempt to link to generated
models when only api docs are specified.

This also moves the $@ bash parameter in bin/kotlin-client-petstore.sh
to the end of the args variable. This is because $@ can only be used to
pass System properties like -DdebugModels, can can already be passed as:

JAVA_OPTS="$JAVA_OPTS -DdebugModels" ./bin/kotlin-client-petstore.sh

By moving the $@ to the end of the args, it allows us to pass additional
properties and other switches directly to the script.
2017-05-29 22:12:55 -04:00
Jim Schubert
d6a98fa444 Kotlin client (#5727)
* Add new.sh helper script to create generator files

* [kotlin] Initial Kotlin client generator

* [kotlin] Generate sample

* [kotlin] Sample helper files not needed for generation, but for sample evaluation
2017-05-30 00:38:15 +08:00
wing328
18e6440bcc Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-30 00:12:34 +08:00
wing328
b84769d1e3 fix enum float value in C#, minor format fix in doc (#5726) 2017-05-29 22:16:42 +08:00
wing328
3df5b6f303 [Java] Fix float enum value by adding "f" (#5724)
* fix java float enum value

* update java petstore samples

* add comment explaining the fix
2017-05-29 19:34:04 +08:00
Cliffano Subagio
ea30a4a7f8 [Ruby] Chunked file download (#5718)
* [Ruby] Modify file download to be written in chunks in order to handle large files. #5704

* [Ruby] Update Ruby Petstore with file download improvement. #5704
2017-05-29 14:56:48 +08:00
René Winkelmeyer
3d97d83f7a Apex update for NamedCredentials and Salesforce DX (#5717)
* Added mustache file for namedCredentials

* Removed Basic and OAuth from Apex API in favor of NamedCredentials

* Moved old README to README for ant deployment

* Added SFDX OSS descriptor

* Removed remoteSite mustache

* Changed package.xml from RemoteSite to NamedCredential

* Update ApexClientCodegen to support SFDX and namedCredentials

* Created initial README for Salesforce DX

* Ran Petstore test for Apex commit

* Fixed error in README mustache
2017-05-29 11:16:06 +08:00
wing328
999f901d2b update clojure petstore cient 2017-05-27 00:33:49 +08:00
Michael Langford
b1ccaf69ac Updates http-client dependency to correctly handles certificates (#5707)
* Updates http-client dependency to one that correctly handles certificates

This is important as amazon AWS gateway and several other types of certificates will not work correctly due to the old java library used by the 2.0.0 version of http-client.

* Runs the petstore updates switch for clojure

* Runs the petstore updates switch for clojure
2017-05-27 00:27:11 +08:00
wing328
39d79de6f7 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-05-26 22:50:06 +08:00
wing328
54119a7ac1 roll back clojure petstore to use petstore.json 2017-05-26 22:49:30 +08:00
wing328
4d705081c8 [PHP] Fix broken links in the auto-generated documentation (#5715)
* remove trailing space in cpprest, update samples

* remove unused pom.xml in go pestore

* fix broken links in php api doc by fixing baseType

* fix csharp api doc

* fix php examples

* fix examples for abstract php generator
2017-05-26 21:47:49 +08:00
wing328
424a70bd8c Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-26 17:35:36 +08:00
Svarog
84df23f025 Made httpMethod in curl example actually upper case in html2 to support firefox (#5558) (#5705) 2017-05-26 17:19:09 +08:00
rompic
ef53f08b09 fixed #5692 and regenerated samples (#5698) 2017-05-24 23:26:33 +08:00
wing328
41527ead54 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-24 20:13:31 +08:00
wing328
b024288df2 JS ES6 enhancements 2017-05-24 16:50:32 +08:00
Dinuka De Silva
ca139ffc05 Gh-4044: Enabling ES6 in javascript client (#5593)
* gh-4044: Added useES6 as an option for javascript templates

* gh-4044: Enabled ES6 in `javascript/api.mustache`

* gh-4044: Enabled ES6 in `javascript/ApiClient.mustache`

* gh-4044: Enabled ES6 in `javascript/enumClass.mustache`

* gh-4044: Added useES6 cli option to `javascript` clients and updated the test cases

* gh-4044: Enabled ES6 in `javascript/index.mustache`

* gh-4044: Enabled ES6 in `javascript` model templates
* `javascript/model.mustache`
* `javascript/partial_model_generic.mustache`
* `javascript/partial_model_enum_class.mustache`
* `javascript/partial_model_inner_enum.mustache`

* gh-4044: Separated `javascript-es6` templates to another folder

* gh-4044: Updated `javascript-es6/index.mustache`

* gh-4044: Enabled ES6 in `javascript-es6/api_doc.mustache`

* gh-4044: Added required dependencies for ES6

* gh-4044: Updated Supportig files for ES6 and non ES6

* gh-4044: Added test scripts to verify `javascript` useEs6 option

* gh-4044: Commented `javascript-es6` scripts due to the permission issues.
2017-05-24 16:35:54 +08:00
wing328
bd227df4db update ts angualr2 petstore clients 2017-05-24 15:55:34 +08:00
wing328
f33e1d0026 add new files for C# API client 2017-05-23 22:20:08 +08:00
wing328
b18121ee9c Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-23 21:41:13 +08:00
kirpit
e12b22d5ce Implement generating interfaces option for api resources, closes #5453. (#5519)
* Implement generating interfaces option for api resources, closes swagger-api/swagger-codegen#5453.

This commit introduces another _system property_ for typescript-angular2, called `withInterfaces` that is default to `false`. You can activate this flag by:

```
java -jar modules/swagger-codegen-cli/target/swagger-codegen-cli.jar generate \
-i http://petstore.swagger.io/v2/swagger.json \
-l typescript-angular2 -o samples/server/petstore/springboot/typescript-angular2 \
-D withInterfaces=true
```

If set to `true`, generated api resource classes will be implemented with their interfaces in separate files.

This change should not break and change the behaviour even though `withInterfaces` flag set to `true`. You are also welcome to create your own custom resource class by implementing those generated interfaces as they support defining new attributes with `[others: string]: any;` signature.

* Fix unit test for typescript/angular2 client options for "withInterfaces"

* Use double quote to follow coding standard

* Respect interface naming convention for typescript/angular2

 Create respectful interface names that ends with `Interface` suffix, instead of prefixing with `I` according to typescript naming convention. This is also consistent with their file names that also ends with `Interface.ts`.

 Also fixes the merge conflicts.

* Have better explanation for the `withInterfaces` system config
2017-05-23 21:40:21 +08:00
wing328
802641bf91 update apex petstore client 2017-05-21 16:12:47 +08:00
wing328
651a3e388b Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-21 01:35:13 +08:00
wing328
8314f4e78a Add removeOperationIdPrefix option (#5674)
* add removeOperationIdPrefix option

* remove removeOperationIdPrefix from cli option for generators
2017-05-21 01:28:06 +08:00
wing328
7edf744426 [Apex] add petstore samples, shell scripts, batch files (#5672)
* add apex petstore samples, shell scripts, batch files

* add wording "beta" to Apex help
2017-05-20 01:02:08 +08:00
Takuro Wada
ad0838f0a0 [ts-ng2] add check whether header parameter is undefined or not (#5668) 2017-05-19 18:23:17 +08:00
wing328
bd2f03f1c0 update objc, swift2,3 petstore samples 2017-05-18 17:22:20 +08:00
wing328
fdbd13b368 update objc, swift2,3 petstore samples 2017-05-18 17:18:43 +08:00
wing328
cc55dfbf13 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-18 16:22:42 +08:00
Harald Walker
4417bb6b32 #5649 Fix FileAlreadyExistsException when downloading file using jersey2 (#5654)
* #5649 Fix download file copy

* Include generated pet store samples and fix indentation

* Regenerate petstore sample to fix indentation
2017-05-18 15:12:53 +08:00
Jason Gavris
97a4bacc4e [Swift3] Use thread safe manager dictionary (#5610) 2017-05-17 23:35:49 +08:00
wing328
5c17cb3a78 Merge branch 'swift-2.3.0-models' of https://github.com/ButterflyNetwork/swagger-codegen into ButterflyNetwork-swift-2.3.0-models 2017-05-17 22:34:33 +08:00
wing328
2ff548d80b update C# petstore samples 2017-05-17 22:07:58 +08:00
wing328
e1e5ac4d37 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-17 22:00:06 +08:00
Cas Perl
a6b7f60ac7 Python improved (#5512)
* ignore .vscode

* fixed test case for models requiring mandatory attributes. added deserialize test for enum class

* construct model with mandatory attributes. improve class reflection (e.g. deserialize). disable generated empty model unit test for further FIXME

* rebuilt samples

* FIXME comment

* FIXME comment

* fix deserialization enum test
2017-05-17 21:18:51 +08:00
Benjamin Douglas
be3cfda3ce Disable Jackson FAIL_ON_INVALID_SUBTYPE in feign (#5597)
* Disable Jackson FAIL_ON_INVALID_SUBTYPE in feign

With this change, Jackson does not fail even if it doesn't recognize a
discriminator type name. This is helpful when upgrading a microservice with
a new subtype while keeping compatibility with its old clients. The instance
is returned as null instead of throwing an exception deep in the feign
framework, allowing clients to gracefully degrade.

* Disable FAIL_ON_INVALID_SUBTYPE for all Jackson-based projects
2017-05-16 21:20:05 +08:00
wing328
0a67696de8 Merge branch 'empty_classes' of https://github.com/bbdouglas/swagger-codegen into bbdouglas-empty_classes 2017-05-16 17:51:42 +08:00
wing328
1fc969b050 Merge branch 'sync_samples' of https://github.com/bbdouglas/swagger-codegen into bbdouglas-sync_samples 2017-05-16 16:51:41 +08:00
Brendan Burns
c5d1c5d73b Extract out a new helper method from java ApiClients (#5648) 2017-05-16 13:59:06 +08:00
Marcus Low Junxiang
2b56384887 Adding enum generation support for golang client (#5635)
* adding enum support for golang client

* indentation correction
2017-05-15 15:41:13 +08:00
wing328
96a8440a57 fix missing private datetime var in java okhttp client 2017-05-14 23:42:31 +08:00
wing328
7dd42483a4 update all petstore samples for java clients 2017-05-14 23:21:05 +08:00
wing328
67c61eed0b update java petstore 2017-05-14 22:53:25 +08:00
wing328
7fc36f1e1e Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-14 22:32:12 +08:00
Takuro Wada
a7d5684679 [Python] add an option to Config in order to specify safe chars for path parameter (#5628) 2017-05-14 11:54:26 +08:00
Adam Fanello
fb04b5a26a Fix for issue #5349. (#5560)
With this change, users providing custom configuration must provide an exported Configuration factory, rather than just an object. This is needed to be Angular AoT compatible.

Example use:

import * as api from '../api';

/** Configuration settings for the backend API */
export function backendConfigurationFactory(): api.Configuration {
    return new api.Configuration({basePath: '/api'});
}

@NgModule({
    imports: [api.ApiModule.forConfig(backendConfigurationFactory)],
...
2017-05-14 11:52:10 +08:00
Takuro Wada
11baad6e4b [TypeScript-jquery] set default return type as any (#5630)
* [TypeScript-jquery] fix bug of empty returnType appearing if returnType is not provided

* chore: add security sample for typescript-jquery
2017-05-14 11:36:09 +08:00
sdoeringNew
98d53bc8d2 #5619 added getValue() method in generated Enum classes in Java (#5620) 2017-05-13 00:03:44 +08:00
Brendan Burns
e7a1f5fb17 [Java] Add custom SSL KeyManagers for okhttp-gson Java clients (#5629)
* Add the ability to set SSL KeyManagers for okhttp-gson Java clients

* Update generated code.

* Update security model files.
2017-05-12 23:49:00 +08:00
wing328
68864a2eea [JavaScript] Minor fix to JS doc and add swagger-codegen version to the file header (#5623)
* fix JS doc using instance instead of default

* update JS header with codegen version

* roll back change in swagger codegen version in pom.xml
2017-05-12 16:49:20 +08:00
Jason Gavris
b582c46e4b [Swift3] Fix compilation of models file 2017-05-10 12:05:07 -04:00
wing328
b8715fc4a5 add back example support to java spring (breaking changes) (#5606) 2017-05-10 23:31:25 +08:00
wing328
59075d105e update java parcelable model petstore 2017-05-10 18:06:49 +08:00
wing328
45ff39c237 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-10 18:04:49 +08:00
wing328
9b68f02f83 [Java][Spring] Undo "Add examples defined in the spec to Spring MVC server generator " (#5599)
* remove unused pom.xml in go pestore

* remove example support in JavaSprin (undo changes)
2017-05-10 17:31:43 +08:00
kenisteward
ec7b80abab #4962 Empty Response body handling in typescript-angular2 - added returning an empty object on response.json() failure (#5585) 2017-05-10 15:46:33 +08:00
Voydz
5a257a0558 [csharp] fixes for netstandard (json serializing and project files) (#5590) 2017-05-10 15:24:43 +08:00
wing328
fd3cae6c4b rename .swagger folder to .swagger-codegen 2017-05-09 17:07:45 +08:00
sabras75
824842290d Fix#5510 (#5582)
* Add overloads on signals.
The overload adds the NetworkError and the error string to the signal. Both signal will be emitted. Clients are supposed to subscribe to  only one of the overloads.

* refactor generated code alignement

* Do not use method overload for signals. Instead, have another naming convention for signal that carries Error information.
 Why ? Because signal overloading and QT5 connector with method referencing do not mix well (see http://stackoverflow.com/questions/16794695/connecting-overloaded-signals-and-slots-in-qt-5). It would need to specify exactly which overload to take. That is cumbersome to write AND is a breaking change for the consumer of the generated code.

* update qt5 sample files
2017-05-09 16:34:17 +08:00
wing328
621ff06a89 update java petstore sample 2017-05-08 18:33:25 +08:00
Vincent Coetzee
409638676e Added code to templates to ensure correct generation of code for Swift3 (#5390)
* Added code to templates to ensure generation of code for Swift3 that builds on both Apple platforms and Linux. Fixed a bug in the Model decoders that prevented code from building for Linux

* Ran the script to generate the PetStore API
2017-05-08 18:26:30 +08:00
Takuro Wada
a81cff0ed0 [typescript-angular2] change OpaqueToken to InjectionToken<string> (Issue #5565) (#5569)
* change OpaqueToken to InjectionToken<string> and add useOpaqueToken option for typescript-angular2 (#5565)

* run security shell
2017-05-08 18:08:54 +08:00
Marcus Low Junxiang
adb213bc00 Modifying resty dependency to use stable release instead of HEAD (#5579)
* Modifying resty dependency to use stable release instead of HEAD

* adding dependency to pre-integration test
2017-05-08 09:55:13 +08:00
mguan-trulia
918343b684 issue #3365 adding accept encoding for PHP (#5525) 2017-05-06 10:40:08 +08:00
Alexander
9212c21567 [PHP] Add default value to method signature if present in Swagger spec (#5571)
* Add default value to method signature if present in Swagger spec

* Update pet store PHP code
2017-05-06 10:39:14 +08:00
beatcracker
d214e0ad4b [PowerShell] module to serve as template for PowerShell generator (#5509)
* Added PowerShell module. See #4320

MVP PowerShell module to serve as a template for a PowerShell generator.

* Fixed function name

* Removed module manifest

It should be generated by the build script

* Ignore module manifests

* Removed binding from prop. name for Pet
2017-05-05 17:21:11 +08:00
wing328
167cbe9726 remove trailing comma in ts angular template (#5563) 2017-05-05 17:05:45 +08:00
wing328
8e0d940e0a update cpprest petstore sample 2017-05-05 16:20:59 +08:00
Jim Schubert
8e6dfce83e [csharp2] Extend generator from AbstractCSharpCodegen (#5552)
* [csharp2] Extend generator from AbstractCSharpCodegen

* [csharp2] regenerate sample
2017-05-05 15:58:01 +08:00
Ravi
f101a43b9e [C++][CppRest] Add CMake file template to generate CMakeLists build file (#5561)
* Add operationId in exception message

* add number data type mapping

* removing mergetool lines

* first draft of cmake file

* compiles generated source files with 64 bit cpprest and boost

* using glob recurs to add source files

* using glob recurse for source files

* cmake to build statuc library

* add cmake style comments, use project source dir and lib

* fix_issue5488: Add supporting files and source files separately

* fix_issue5488: Add supporting files and source files separately

* fix_issue5488: Add supporting files and source files separately

* fix_issue5488 - updated header comments

* updated samples
2017-05-05 15:47:39 +08:00
wing328
fb357086c8 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-04 19:04:39 +08:00
wing328
1e9fe51175 use original value of pattern (#5554) 2017-05-04 18:01:52 +08:00
Andrea Polci
fd17955685 #5548 Avoid html escaping of pattern in bean validation (#5549)
* Issue #5548 Avoid html escaping of pattern in bean validation

* Run spring-all-petstore.sh and java-petstore-all.sh scripts
2017-05-04 17:12:13 +08:00
wing328
6f944b243d Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-03 21:45:07 +08:00
wing328
a7e42ee2b6 add validatable flag for .net 3.5 (#5544) 2017-05-03 21:32:25 +08:00
wing328
b87851bd27 update spring cloud petstore client 2017-05-03 17:47:49 +08:00
wing328
3b98cc7ca0 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-03 17:32:24 +08:00
wing328
e28471341c add switcgh to determine java8, java7 (#5541) 2017-05-03 16:41:58 +08:00
Benjamin Douglas
7406d07aca Reverting petstore sample gen (fails tests) 2017-05-02 19:55:47 -07:00
Benjamin Douglas
34d9dca5e7 Update samples to current code/scripts
This is the result of

  - `$ git checkout master`
  - `$ bin/run-all-petstore`

No change was made to the code, just ran the aggregate sample generation
script.
2017-05-02 10:33:06 -07:00
wing328
413a00ef40 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-03 00:09:14 +08:00
wing328
3744a3f8f5 add option to skip client side validation in ruby client (#5528) 2017-05-02 21:30:59 +08:00
herrerog
70f4c72421 [Python]: correct query_params type. (#5503)
query_params is a list of tuple, so defined it as a list by
default instead of a dict.

This fix below issue on the client side.

Traceback (most recent call last):
  File "test.py", line 13, in <module>
    api_response = api_instance.seek("the")
  File "python-client/swagger_client/apis/seek_api.py", line 168, in seek
    (data) = self.seek_with_http_info(recherche, **kwargs)
  File "python-client/swagger_client/apis/seek_api.py", line 245, in seek_with_http_info
    collection_formats=collection_formats)
  File "python-client/swagger_client/api_client.py", line 323, in call_api
    _return_http_data_only, collection_formats, _preload_content, _request_timeout)
  File "python-client/swagger_client/api_client.py", line 135, in __call_api
    self.update_params_for_auth(header_params, query_params, auth_settings)
  File "python-client/swagger_client/api_client.py", line 512, in update_params_for_auth
    querys.append((auth_setting['key'], auth_setting['value']))
AttributeError: 'dict' object has no attribute 'append'

Signed-off-by: Gregory Herrero <gregory.herrero@gmail.com>
2017-04-29 12:07:09 +08:00
weiyang
1091ebce5a [go][model] Use pointers to avoid circular references (#5478)
* [go][model] Use pointers to avoid circular references

Signed-off-by: weiyang <weiyang.ones@gmail.com>

* [samples][go][model] Use pointers to avoid circular references

Signed-off-by: weiyang <weiyang.ones@gmail.com>
2017-04-29 01:08:07 +08:00
wing328
556be7dfd6 update qt5 c++ petstore samples 2017-04-28 22:47:05 +08:00
sabras75
994e4fd8ff Fix#5481 (#5499)
* Add CPP_NAMESPACE option

* update mustache template to exploit cppNamespace option

* update sample files

* correction : missing namespace replacement in template
2017-04-28 22:19:37 +08:00
Xin Meng
c7979da74d add withCredentials to the configuration (#5484)
* add withCredentials to the configuration

1. `withCredentials` in Request is `false` default
2. if want to set the `withCredentials` as `true` (for CORS request),
 instance `Configuration` object and set the `withCredentials` as `true`.

* simplify the code according to the code review
2017-04-28 18:11:23 +08:00
wing328
2ac169c750 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-28 02:03:42 +08:00
Daniel Woodel
bfae01cd35 [swift3] Swift3 code generator & templates fixed to support additional properties, updated petstore for CI (#5407) 2017-04-28 01:58:54 +08:00
guidovezzoni
663db1b72a Fix issue5425 (#5483)
* issue 5425 : [Android] Bug generating parcelables constructors for custom classes ( missing getClassLoader() )

* issue 5425 : changes in generated code

* ran ./bin/java-petstore-all.sh and committed the changes
2017-04-28 01:23:32 +08:00
wing328
2324e927bd [Java][Spring] fix missing import for java.io.IOException (#5501)
* fix issue about import io exception for spring mvc

* fix spring-mvc-petstore-j8-async script, config

* update spring cloud client, restore petstore.yaml
2017-04-28 00:45:06 +08:00
wing328
7b57dd0c04 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-27 21:18:52 +08:00
wing328
42a5a13fef [Java][Spring] Fix spring cloud client due to enhancement in adding server example responses. (#5497)
* add use spring cloud client option

* uncomment spring cloud client test

* remove scala-related tests from pom.xml for circleci

* fix mismstach tag
2017-04-27 20:00:56 +08:00
wing328
e8feca2753 [Android] add windows batch, better code foramt (#5496)
* remove trailing space in cpprest, update samples

* add android batch files, better code format, sync petstore.json with
petstore.yaml

* restore petstore.json and sync it to petstore.yaml

* update circleci pom.xml

* add new android files

* add new android files
2017-04-27 17:58:38 +08:00
wing328
f4d78079de Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-25 23:34:45 +08:00
Elizabeth Thomas
efb337dd92 Issue 5413 - Use ConstructorBased Injection for ObjectMapper (#5430)
* Converting to constructor based injection

* Correcting spelling mistake

* Adding the bean for ObjectMapper

* Adding files modified by running the petstore scripts

* Adding final qualifier to objectMapper variable in apiController mustache
2017-04-25 23:11:18 +08:00
wing328
2dd051fd4e Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-25 21:46:44 +08:00
wing328
3ef7694b9f Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-25 21:39:17 +08:00
sabras75
00651dd340 Fix#5463 - [QT5CPP] missing SWGUUID when generating client based on swager.yaml containing a string with format 'uuid' (#5472)
* Add support to UUID type

* Simplify and use a simple QString instead of a QUuid.
Work for using a QUuid is way larger than supporting QString (imply modifying multiple c++ templates).
Current needs are fullfill with the use of a simple QString, so I let the use of QUuid for future enhancement.

* - add windows executable for generating qt5 security samples
- update sample clients
PS : some modifications on the samples are not related to the patch I applied. Were the samples up-to-date ?
2017-04-25 20:54:05 +08:00
nikitozz
80dccfe395 The new .NET project file format support (#5439) 2017-04-25 10:22:59 +08:00
Jani Väinölä
9055dfc42e Jaxrs jersey2 support (#5058)
* [JAVA/] jaxrs/jersey2 (Issue: 4662) Made java8-date codegeneration to work with jersey2

* Ran shellscripts for  jaxrs-jersey-petstore-server and java8-petstore-jersey2  to update petstore samples
2017-04-25 00:53:34 +08:00
wing328
aa85468932 remove trailing space in cpprest, update samples 2017-04-24 22:45:16 +08:00
Martin Brown
fc2b3d49ea Issue 4632 (#4803)
* Updated the Petstore samples

* This change uses std::stringstream for string conversions instead of std::to_string(). Android doesn't yet support std::to_string(). This should fix #4632
2017-04-24 22:27:51 +08:00
wing328
176b6829c4 add back toString to form parameters in ts angular2 (#5457) 2017-04-24 18:44:49 +08:00
wing328
e969b35ea2 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-24 18:07:17 +08:00
wing328
f09372e2ec replace tab with spaces 2017-04-24 17:27:07 +08:00
wing328
e4608745b0 update java resteasy sample 2017-04-24 17:12:00 +08:00
wing328
640b16b58a Merge branch 'master' into master 2017-04-24 17:00:27 +08:00
wing328
30d0b11801 update java petstore samples 2017-04-24 16:22:11 +08:00
nbruno
ddc309ec19 Add support for Spring's RestTemplate in Java client codegen (#5404)
* Add support for Spring's RestTemplate in Java client codegen

Resolves #1176

* Update all Java samples to include change for Jackson enums

Currently enums are deserialized from a String value with an
explicit @JsonCreator. However, they are not being serialized with
this String value. This change introduces the @JsonValue annotation
on the toString() method of enums, so they will be serialized as a
String with the correct value.
2017-04-24 14:40:47 +08:00
wing328
863f431dfb update all spring petstore samples 2017-04-24 00:27:20 +08:00
wing328
0c5cc4621a Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-23 23:07:28 +08:00
wing328
56d4382d75 update swift3 petstore samples 2017-04-23 23:06:16 +08:00
wing328
c8d9450db5 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-23 22:46:10 +08:00
wing328
1277db61bd [Ruby] add generator version to Ruby template (#5459)
* add generator version to ruby template

* remove tab in java generator
2017-04-23 22:41:56 +08:00
wing328
397b440e60 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-23 18:36:37 +08:00
Xin Meng
c3d51357a8 fix the typescript angular 2 http request option issue #5374 (#5380)
* fix the typescript angular 2 http request option issue #5374

https://github.com/swagger-api/swagger-codegen/issues/5374

add `withCredentials:true` to the request option

*  run ./bin/typescript-angular2-petstore-all.sh to update Petstore samples
2017-04-23 18:31:00 +08:00
wing328
fee410d84e Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-23 18:02:02 +08:00
wing328
f10886b490 remove csharp/SwaggerClient.v5 2017-04-23 16:04:33 +08:00
wing328
f7cbb2c0e6 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-23 15:26:15 +08:00
antihax
3ed1aa8e79 Rewrite of Go Client #2 (#5037)
* Rewrite of Go Client

* Revert to older version of context.Context

* Clean and bulk up concurrency test.

* Correct {{path}} to {{{path}}}

* change custom date type to string.

* Add APIKey authentication

* Correct missing line from resolving conflicts.

Correct missing line from resolving conflicts.
2017-04-22 01:17:18 +08:00
Sergey Novikov
6685f18e5f Reuse allowed values (#5435) 2017-04-22 00:30:52 +08:00
Ravi
e9a438b73f [CppRest] Overload toJson for bool in Modelbase (#5448)
* Add operationId in exception message

* add number data type mapping

* fix_issue5434
2017-04-21 22:20:46 +08:00
Cas Perl
122db78b1a Issue 5375 (#5403)
* use py3 instead of py34

* fixed test to test invalid enum

* ADDED: assign variable in the ctor with property setter to check validity if possible. CHANGE: move required property check to proper place. CHANGE: remove double quotes from allowed_values for none-string enum property

* rebuilt samples

* comment for improvement

* ADDED: post process enum model for python.

* comment

* rebuilt samples

* rebuilt samples
2017-04-21 22:05:54 +08:00
Julien Fouilhé
edb80df0ba fix(swift3): fix infinite loop with inheritance and check if parent decoder exists before calling (#5416) 2017-04-20 22:54:35 +08:00
Julien Fouilhé
c65e663a11 fix(swift3): decoders call parents decoders too (#5433) 2017-04-20 22:54:01 +08:00
wing328
813949dd00 add lamda to clean up examples, fix spring tempalate format 2017-04-18 18:14:00 +08:00
Benjamin Douglas
07ba1eb6f8 Fixup generation of Javascript samples
The generation code was ignoring top-level aliases for any language config that
contained "java", which included "javascript", a completely different language.

Changed this to be those configs based on the JavaAbstractGenerator class.
2017-04-17 17:50:01 -07:00
Benjamin Douglas
73454e95dc Fixed up duplicate pom ids
These were generated by bin/run-all-petstore, so ultimately that script should
be modified to not generate the duplicate artifact ids.
2017-04-17 16:30:38 -07:00
Benjamin Douglas
9058099e5b Add alias type definitions for Java
When a spec defines a Model at the top level that is a non-aggretate type (such
as string, number or boolean), it essentially represents an alias for the simple
type. For example, the following spec snippet creates an alias of the boolean
type that for all intents and purposes acts just like a regular boolean.

    definitions:
      JustABoolean:
        type: boolean

This can be modeled in some languages through built-in mechanisms, such as
typedefs in C++. Java, however, just not have a clean way of representing this.

This change introduces an internal mechanism for representing aliases. It
maintains a map in DefaultCodegen that tracks these types of definitions, and
wherever it sees the "JustABoolean" type in the spec, it generates code that
uses the built-in "Boolean" instead.

This functionality currenlty only applies to Java, but could be extended to
other languages later.

The change adds a few examples of this to the fake endpoint spec for testing,
which means all of the samples change as well.
2017-04-17 12:58:31 -07:00
Julien Fouilhé
b1a39ac820 fix(swift3): decoders call parents decoders too (#5369) 2017-04-18 00:03:52 +08:00
wing328
34a99d6dba update spring petstore samples 2017-04-17 23:32:03 +08:00
wing328
c7ccb1a9a9 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-17 23:05:46 +08:00
Tino Fuhrmann
e858f2390b [TypeScript] fix class filename in import/export (#5396)
* Fixed classFilename in typescript-angular and recreated samples

* Changed classname to classFilename in ts-angular2/models.mustache
Also recreated ts-angular2 sample
2017-04-17 22:43:33 +08:00
wing328
50c6f87d98 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-13 17:48:34 +08:00
wing328
0682e41d6d update spring petstore sample 2017-04-13 17:44:38 +08:00
Benjamin Douglas
ab69ce5dc3 Add null pointer check to add/put methods (#5385) (#5386)
Commit e3d04ee01 (issue #5240) introduced unsafe add/put methods for optional
list/map parameters. This change maintains the spirit of issue #5240 (optional
containers are null by default) while still making add/put calls safe. It does
this by checking for null first and, if so, initializing it with an empty
container.

Also updated the affected samples using the various scripts in bin/.
2017-04-13 17:37:49 +08:00
wing328
942c77b530 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-12 22:11:52 +08:00
Gayathri
a774ff9587 Latest from master - merge conflict resolution 2017-04-12 09:03:54 -05:00
nikitozz
78c4928908 Fixes #5367. Async support is enabled for .NET netstandard API clients (#5368) 2017-04-12 10:39:42 +08:00
wing328
1f4261d20b Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-11 22:29:28 +08:00
wing328
1fdd3e6ffa [Java][Spring] fix enum allowable values in Spring generators (#5364)
* fix enum allowable values in spring generators

* use values instead of enumVars in spring annoation
2017-04-11 22:23:09 +08:00
wing328
e3d04ee01f [Java] remove initialization for optional list property (#5363)
* set list to null in java if not required

* update petstore sample for java server stub

* update sample for msf4j

* add null assignment to new list/map in java
2017-04-11 19:07:48 +08:00
Michael Kourlas
0e65f649bc [JavaScript] Fix for issue #5358: Regression in 2.3 using multi parameters (Cannot read property 'buildCollectionParam' of undefined) (#5362)
* Fix for issue #5358

* Update tests for #5358
2017-04-11 17:52:32 +08:00
wing328
2d0c8c4060 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-11 01:03:28 +08:00
wing328
d3ac4b686a fix CI issue by declaring originalEnvironmentVariables as a protected
member
2017-04-11 00:57:22 +08:00
wing328
7991cf75ae Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-10 23:21:36 +08:00
Vincent Giersch
aef98f464e fix(php): should not check enum value if not unspecified and optional (broken since #4886) (#5357)
Signed-off-by: Vincent Giersch <vincent@giersch.fr>
2017-04-10 23:21:14 +08:00
tbe
d59ac2ae65 [Perl] remove singleton (#5353)
- removed Singleton from ApiClient

fixes #5336
2017-04-10 22:52:32 +08:00
Ahmet Taha Sakar
c6959b0d21 Swift3 headers (#5340)
* added headers to makeRequest function for swift3 template

* petstore update
2017-04-10 22:36:22 +08:00
wing328
8dbdc31ba7 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-08 00:29:26 +08:00
lukoyanov
a7652d508d Updated CallAdapter & CallAdapterFactory for retrofit 2.2.0 (#5345) 2017-04-07 07:35:47 +08:00
baartosz
13cccccb67 fixed error handling in async requests in python client (#5308) 2017-04-06 16:55:53 +08:00
wing328
f9825b01d3 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-06 11:58:20 +08:00
Paŭlo Ebermann
0c1ad9b2ba Update security samples for Scala + typescript-node. (#5325) 2017-04-05 18:05:21 +08:00
Paŭlo Ebermann
be83329946 Update security samples for swift. (#5324) 2017-04-05 18:04:53 +08:00
wing328
956e7b4cb5 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-04 23:04:25 +08:00
wing328
22c80588f6 fix retrofit2 rxjava2 script (#5321) 2017-04-04 22:58:03 +08:00
wing328
ad2552ace6 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-04 15:27:17 +08:00
Paŭlo Ebermann
8bd67c9f7f Fix template directory used by samples script. (#5284) 2017-04-04 14:47:22 +08:00
Paŭlo Ebermann
41b04e0e01 Update security samples for typescript-clients (Angular1/2). (#5288) 2017-04-04 14:44:25 +08:00
Paŭlo Ebermann
ca976c524a Update security samples for ObjectiveC client. (#5286) 2017-04-04 14:44:09 +08:00
Paŭlo Ebermann
35ce3f48b9 Updating security samples for C++/QT5. (#5291) 2017-04-04 14:43:52 +08:00
Paŭlo Ebermann
66bf83e911 Update security samples for Javascript clients (#5289) 2017-04-04 14:43:25 +08:00
Paŭlo Ebermann
0695a58f3c Updating security samples for Python client. (#5294) 2017-04-04 14:42:48 +08:00
Paŭlo Ebermann
7462cf70cf Updating security samples for PHP client. (#5293) 2017-04-04 14:42:01 +08:00
Paŭlo Ebermann
cac803351b Updating security samples for Go-client. (#5290) 2017-04-04 14:41:43 +08:00
Paŭlo Ebermann
f44949db58 Update security samples for Ruby-Client. (#5287) 2017-04-04 14:41:22 +08:00
Paŭlo Ebermann
bebeac8ae8 Updating security samples for Perl. (#5292) 2017-04-04 14:40:58 +08:00
Paŭlo Ebermann
f7b39a85a5 Updating security samples for scala. (#5295) 2017-04-04 14:40:36 +08:00
Paŭlo Ebermann
eb3565b6c0 [C#] Fix guid for C# security samples (#5283)
* Issue #5196: also fix the packageGuid for the C# security samples.

* Update C# security samples.
2017-04-04 14:38:47 +08:00
wing328
c5e6401b89 fix C# api client template for multi query parameter support 2017-04-03 16:55:55 +08:00
wing328
5453d61a4c fix PrepareRequest method signature 2017-04-03 16:45:32 +08:00
Sean O'Hare
f102d675d6 Initial commit to support "multi" formatted collections as query strings in csharp. 2017-04-03 16:36:29 +08:00
wing328
3f8f13e3fd Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-03 15:49:44 +08:00
wing328
e5b3e3cdac replace tab with 4space for ts jquery client (#5299) 2017-04-03 15:48:51 +08:00
baartosz
2315ef2a7f Php client using guzzle6 & psr7 instead of curl (#5190)
* reimplemented basic requests with httpplug

* added returning headers

* added query params support

* removed constant reference to model class

* some extra @throws; form params

* form and query params encoding

* file upload / form multipart

* added missing response headers in WithHttpInfo calls

* removed Store test From PetApiTest class

* removed configuration overriding test as its now task of client adapters

* updated store tests with new client initialization code

* updated composer.json template

* not using json_decode if response is string

* renamed some variables to camelCase

* removed ApiClient and Configuration classes

* added HeaderSelector template

* added ObjectSerializer injection

* regenerated all samples

* added AuthConfig and readded support for custom api keys

* readded support for oauth tokens

* readded basic auth; moved auth tests to separate test class

* readded header params

* readded support for collections in paths

* readded  config option; readded exception handling

* file downloading; readded some Configuration properties removed earlier

* readded default headers

* made responses and return types work same way as earlier

* made all methods static in ObjectSerializer

* updated test.php, replaced autoload.php with composer's autoloader

* updated api doc template

* removed classes used for testing; regenerated Fake_classname_tags123Api

* replaced httplug with guzzle6

* updated required php version to 5.5

* clean up

* readded missing userAgent feature; removed default headers from Configuration

* updated test.php

* downgraded phpunit back to 4.8 to work with php5.5; fixed client initialization in some tests
2017-04-03 15:47:57 +08:00
wing328
028cbc77b6 Merge branch '2.3.0' of https://github.com/swagger-api/swagger-codegen into 2.3.0 2017-04-03 15:05:58 +08:00
wing328
d1350b006e comment out scala test 2017-04-03 15:05:02 +08:00
clasnake
39bd0175b7 Pr4855 cherrypick (#5115)
* Add async support to scala client.

* Format api endpoints.

* Modify build.sbt.

* Change date format and pass StoreApis tests.

* Add StringReader and StringWriter to support string serialization/deserialization.

* update petstore samples for scala clients

* Update maven and gradle dependency. Update tests to pass compilation.
2017-04-03 15:01:43 +08:00
wing328
cf8a9a0de0 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-03 14:54:50 +08:00
wing328
7db3388fdc Update maven compiler plugin to the latest version (3.6.1) (#5300)
* update maven compiler plugin to the latest version

* update feign petstore
2017-04-02 21:39:48 +08:00
Paŭlo Ebermann
ce41a343d8 Updating all samples (except feign) (#5281) 2017-04-02 17:01:15 +08:00
wing328
4916142450 Merge remote-tracking branch 'origin' into 2.3.0 2017-04-02 16:06:33 +08:00
jfiala
ca6b5d09d0 [Jaxrs-cxf] Add check for useGenericResponse for jaxrs-cxf server + client (#4779)
* add check for useGenericResponse for jaxrs-cxf

* move check for genericresponse to cxf codegen #4713
2017-04-02 16:05:16 +08:00
wing328
bfa18a0ce8 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-01 16:39:54 +08:00
Granjow
64c7e23a04 TypeScript client API: Add public getter/setter for base path (#5270) 2017-04-01 16:33:29 +08:00
wing328
e96db74918 update java jersey2 petstore clients 2017-04-01 16:19:31 +08:00
Griffin Schneider
5de19e3214 [Swift3] Fix bug where non-camel-case path params didn't work. (#5267)
* [Swift3] Fix bug where non-camel-case path params didn't work.

* [Swift3] Fix bug where int enums generated non-compiling code. Swift3 integration tests now pass.

* [Swift3] Add a non-camel-case path parameter to petstore-with-fake-endpoints-models-for-testing. This would have caused the Swift3 tests to be broken before 7387e49fef56a624045aa52b65ffb9c19b3853ec.
2017-04-01 16:06:31 +08:00
wing328
22fcea1c91 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-01 15:57:43 +08:00
Benjamin Douglas
5c3fe23e9f Support Swagger collectionFormat encodings in Feign (#5266)
* Support Swagger collectionFormat encodings in Feign

Feign only natively supports the "multi" collectionFormat for encoding lists
of parameter values. This change adds manual encoding of the other formats, such
as "csv" (the default for collections), "tsv", space-separated, and pipes.

* Fix typo in anchor tag.
2017-04-01 15:33:20 +08:00
wing328
9c18c32b93 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-31 01:21:03 +08:00
wing328
b71fe61bb7 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2017-03-31 00:37:05 +08:00
wing328
08be483dab add new python files 2017-03-31 00:36:51 +08:00
Paŭlo Ebermann
36d1406493 Update samples for javascript + javascript-promise. (#5241) 2017-03-30 23:04:49 +08:00
wing328
c9182ba00f Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-30 22:49:11 +08:00
niku
4e1d9ea010 [Elixir] Add documentation for functions (#5260) 2017-03-30 22:45:39 +08:00
Usman Iqbal
833db27101 [Typescript - Angular2] Add support for multiple API Keys (#5236)
# Conflicts:
#	modules/swagger-codegen/src/main/resources/typescript-angular2/configuration.mustache
#	samples/client/petstore/typescript-angular2/default/configuration.ts
#	samples/client/petstore/typescript-angular2/npm/configuration.ts
2017-03-30 22:27:39 +08:00
David Harrigan
fc01457d77 [JAVA][#5172] Allow vendor json media types (#5189)
* [#5172] Allow vendor json media types

* Revert unnecessary diffs

* Update petstore sample

* Didn't run mvn after some edits

* Rerun ' ./bin/java-petstore-all.sh' and './bin/security/java-petstore-okhttp-gson.sh'

* Added more realistic test cases for isJsonMime
2017-03-30 22:23:24 +08:00
wing328
e4ca7744df Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-30 17:36:35 +08:00
Paŭlo Ebermann
46cb158733 Updating C# samples. (#5242) 2017-03-30 10:02:42 +08:00
wing328
ad4de91d92 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-30 09:57:07 +08:00
Paŭlo Ebermann
db71d97370 Updating samples after #5232. (#5243)
* Updating samples after #5232.

* Fix tests after #5232.

* Fix Javascript client tests.

* JaxRS server: set serverPort only when not given from outside.

* Update JaxRS sample creator scripts to fix serverPort.

* Preliminary test fix for JaxRS server generators.

* Updating samples for JaxRS with Jersey1/2.

* Updating JaxRS samples again.
2017-03-30 01:28:53 +08:00
wing328
bed3cfcfdc Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-29 18:48:57 +08:00
wing328
6debbdb652 [C#] Add C# v5.0 Petstore sample (.NET Standard 1.3 compatible) (#5249)
* add csharp .net standard petstore client, update appveyor to build the
client as part of ci

* add new files
2017-03-29 18:43:30 +08:00
wing328
8f37e68049 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-29 17:25:10 +08:00
wing328
996acc05f5 [Java][Retrofit2] update gradle, sbt build file with latest dependencies (#5238)
* update build.gradle for retrofit2

* update retrofit2 rx2 sample

* update gradle and sbt build file for retrofit2
2017-03-28 21:05:12 +08:00
wing328
55e648c0b1 update retrofit2 dependencies (#5235) 2017-03-28 18:50:24 +08:00
wing328
e41dd761b5 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-28 10:37:19 +08:00
wing328
d68859cfbc fix c# docstring typo (#5223) 2017-03-27 18:06:34 +08:00
wing328
b32fe8230a fix retrofit2 indentation (#5221) 2017-03-27 17:21:45 +08:00
wing328
f4d1261522 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-27 16:05:44 +08:00
Paŭlo Ebermann
b275b8f9da Updating samples for spring-stubs, springboot-delegate, springboot-delegate-j8. (#5211) 2017-03-27 15:24:18 +08:00
Paŭlo Ebermann
ee1ef2c1f6 Update samples for okhttp-gson-parcelableModel. (#5208) 2017-03-27 14:22:56 +08:00
Paŭlo Ebermann
4ec23e6694 Update samples for Ruby-Client + Rails server. (#5214) 2017-03-27 13:27:13 +08:00
wing328
05a3c8d5df Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-27 12:01:56 +08:00
Paŭlo Ebermann
200b10e2da Update samples for QT5. (#5216) 2017-03-27 11:48:16 +08:00
Paŭlo Ebermann
356774ceb2 Update samples for clojure + dynamic-html. (#5217) 2017-03-27 11:47:56 +08:00
wing328
b37a7c81b0 add comments to csharp methods (#5206) 2017-03-27 11:43:14 +08:00
wing328
20cc80d170 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-26 23:05:46 +08:00
Paŭlo Ebermann
c812d81e9a Issue #3084: remove timestamps from bash samples. (#5192) 2017-03-26 22:56:34 +08:00
Paŭlo Ebermann
9b25c0f529 Update samples for JaxRS/CXF. (#5201) 2017-03-26 22:55:55 +08:00
wing328
9acefcffdd Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-26 22:54:17 +08:00
Julien Dupouy
e50e653e3d Binary support for javascript client (#5194) 2017-03-26 22:53:35 +08:00
Paŭlo Ebermann
a3e639ccee Issue #3084: remove timestamps from C# .NET2 samples. (#5197) 2017-03-26 22:48:20 +08:00
wing328
597ceae3da Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-26 22:47:32 +08:00
Paŭlo Ebermann
8c575b0f0c Update samples for ObjC&core-data. (#5202) 2017-03-26 22:44:18 +08:00
Paŭlo Ebermann
f8c3a69ebe Update samples for Swift3. (#5200) 2017-03-26 22:44:00 +08:00
wing328
41a505a1f8 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-25 14:37:59 +08:00
Benjamin Douglas
65b6660c55 Fixes a bug in #5142 for multi-word parameters (#5185)
In the convenience class defined for generating a Map of query parameters, the
parameter name was mistakenly being set to the Java variable name, not the
actual parameter name. These are often the same, but can be different in the
case of multi-word parameters, such as in the sample API's `enum_query_string`
vs `enumQueryString`.
2017-03-24 22:04:11 +08:00
Joseph Moore
b7fc11b089 Modify retrofit OAuth templates for #5039 (#5082)
The updateAccessToken method returns `true` when it means `false` and
vice versa.
2017-03-23 23:27:04 +08:00
wing328
aa3a5c6347 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-23 16:54:49 +08:00
Paŭlo Ebermann
9dc8cf3fa6 Update samples for java/jersey2-java6 (and fix artifact ID) (#5118)
* Update samples for java/jersey2-java6.

* Let the sample generation script set the right name for jersey2-java6.

This is the equivalent change to #5095, for jersey2-java6.

* Update samples for Java/Jersey2-java6.
2017-03-23 15:22:14 +08:00
Benjamin Douglas
55b7db3456 #5142: Add @QueryMap support for Feign API (#5143)
* use builder pattern for operations

* @QueryMap parameter only for query parameters

The previous iteration had replaced all parameters (body, path, query, etc)
within a single @QueryMap. But Feign only supports this style of parameter
passing for query parameters. Besides, for the case of a body parameter (like
soxhlet uses) it only added extra verbosity. With this change, the query
parameters are gathered together in a single @QueryMap and the other parameters
are left alone.

* Adding template for generating test code

* Make javadoc consistent with rest of file's conventions/indents

* Update samples

The files in src/main were generated by running

  $ bin/java-petstore-feign.sh

The files in src/test were manually fixed.

* Correct capitalization of @QueryMap class in feign

Adds a field operationIdCamelCase (a la operationIdLowerCase) to the
CodegenOperation container and uses it in the feign-generated classes
with @QueryMap parameters. Also re-generated the feign samples.

* Adding hyphen to javadocs for extra readability.

* Adding (not replacing) api method with @QueryParam overload.

In order to keep backwards compatibility, switched to adding a new method to
the interface instead of replacing the old call.

* Adding newline to generated source for readability.
2017-03-23 15:01:07 +08:00
baartosz
8b891be7d7 [Python] remove singleton (#5012)
* updated tests relying on configuration's singleton

* regenerated samples

* removed singleton from templates

* regenerated samples

* removed broken sample and its test

* reverted accidental change

* regenerated security/ samples

* removed singleton from RESTClientObject

* removed unused Configuration import

* reverted unrelated change

* updated usage examples in api_doc template
2017-03-22 22:25:46 +08:00
wing328
bea9e265e9 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-22 20:52:26 +08:00
wing328
df2f406849 update csharp generator help text (#5140) 2017-03-22 16:18:59 +08:00
wing328
4f6b3bd48b Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-22 15:55:56 +08:00
wing328
1209cdb194 delete model return file to clear incorrect git status 2017-03-22 00:09:03 +08:00
wing328
1c329483e4 [TypeScript] fix class filename in TS Angular2 template (#5131)
* fix class filename in ts angular2 template

* remove trailing comma in ts angular2 template
2017-03-21 23:48:35 +08:00
wing328
e45284806f add gradle cache 2017-03-21 21:48:40 +08:00
wing328
3ebee288ad add back missing changes from #4539 (#5109) 2017-03-21 16:17:28 +08:00
Ben Herila
42a7110d90 Fix Bug/4952 by explicitly implementing IValidatableObject (#4954)
* Explicitly implement IValidatableObject interface to avoid conflict with potential ValidationResult classes

* Missed one

* Rebuilt tests
2017-03-21 15:57:56 +08:00
Paul English
59fe50dd74 Ensure identifiers get sanitized; Ensure model names also have the same formatting (#5098) 2017-03-21 14:35:38 +08:00
Paŭlo Ebermann
9e38621266 Update samples for javascript-closure-angular. (#5117) 2017-03-21 14:31:18 +08:00
wing328
439563bd70 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-21 14:30:10 +08:00