Commit Graph

4175 Commits

Author SHA1 Message Date
Ville Skyttä
85c7e7697a Perl example fixes (#3652)
* perl: Add configuration and classname imports to examples

* perl: Fix list container syntax in examples
2016-08-28 15:56:00 +08:00
Ville Skyttä
756f7a96f6 java: Fix model package import in example 2016-08-28 01:00:34 +03:00
Ville Skyttä
b4c139f19b Spelling fixes 2016-08-27 02:34:33 +03:00
Guo Huang
be0233c609 [Go] fixing code gen not recognizing 'object' type issue 2016-08-25 21:44:57 -07:00
wing328
419c3165ea Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-08-25 23:14:58 +08:00
wing328
81f947e723 update android petstore sample, add this to volley's model 2016-08-25 23:12:23 +08:00
wing328
12fbbfbd6d Merge branch 'mikesol-patch-android-classVarName' of https://github.com/mikesol/swagger-codegen into mikesol-mikesol-patch-android-classVarName 2016-08-25 23:05:09 +08:00
wing328
d590b849cc Merge pull request #3626 from medallia/flatten-composed-model
Adds flattener for ComposedModel
2016-08-25 23:04:01 +08:00
Tony Wang
beaf1fc7aa fix #3477, add RxSwift support for Swift (#3490)
* fix #3477, add RxSwift support for Swift

* make the SwaggerClient scheme shared
2016-08-25 19:34:12 +08:00
cbornet
194c389a06 fix some inheritance/composition issues and add allOf unit tests
Fix #3629 #3544 #3474 #3636
2016-08-24 17:11:45 +02:00
Jason Gavris
e89f914e8b [Swift] Handle String responses 2016-08-23 10:18:01 -04:00
Jason Gavris
3a457c6a7e [Swift] Handle Void responses 2016-08-23 10:03:51 -04:00
Diego de Estrada
84de96ef65 Adds flattener for ComposedModel 2016-08-22 17:54:30 -03:00
Ryan Martin
c1f3c51427 [Swift] Include HTTP status code and body data in response errors
This is useful when differentiating different error responses. Example:

if let e = error {
  switch e {
    case ErrorResponse.Error(400, _, _): responseLabel.text = "Unknown error"
    case ErrorResponse.Error(403, _, _): responseLabel.text = "Not logged in"
    default: responseLabel.text = "\(e)"
  }
}

The existing error is straight from Alamofire and only includes the HTTP
status code in the body of the message (not broken out as a separate value).
It also does not include the response body, which may be useful.
2016-08-22 12:30:03 -04:00
Damien Pontifex
54fe7a731c inject base_path opaque token for typescript angular2 (#3514)
* inject base_path opaque token for typescript angular2

* Readme note on providing base path to service
2016-08-22 21:40:51 +08:00
Yet Another Minion
9a77c48540 For Qt5 server generator, add BaseIntegerProperty to default values (#3622)
* For Qt5 server generator, add BaseIntegerProperty to default values

* move base property check to after checks of extended properties
2016-08-22 19:52:10 +08:00
wing328
dd52d666c5 Merge pull request #3623 from wing328/ruby_better_pattern
Add function to handle missing delimiter in regex
2016-08-22 19:12:03 +08:00
wing328
a58845bb0f add function to handle missing delimiter in regex 2016-08-22 18:01:06 +08:00
regga-ws
4d94511935 Allowing generators to be aware of original inputSpec path (#3592)
* Enabling knowledge of inputSpec path for custom generators

* Enabling knowledge of inputSpec path for custom generators

* Enabling direct use of "inputSpec" property in templates

* Fixing spaces
2016-08-22 16:04:53 +08:00
wing328
4e20bd9bab [Java][Spring][Inflector][Jax-RS] To fix various enum issues (#3615)
* fix spring enum deserialization issue

* fix enum class for spring

* update java inflector to fix enum tostring

* fix jaxrs jersey1 enum toString

* fix jaxrs jersey patch issue
2016-08-20 17:54:45 +08:00
Kevin Chabreck
64e03422c0 [Spring Boot] use port defined in spec file for server.port value (#3605)
* uncommented server.port property in application.mustache template and set it to serverPort value parsed from spec file

* update Petstore sample for Spring MVC and Boot
2016-08-19 17:29:36 +08:00
Mike Solomon
8536d7991c Uses this.{{name}} to scope instance
Otherwise, if {{classVarName}} is the same as a class member name, the function will not work.
2016-08-19 10:11:31 +03:00
wing328
24c0038cce [Java][Inflector] Fix enum issue with java inflector (#3606)
* fix enum issue with java inflector

* update pom to test java-inflector
2016-08-18 09:48:50 +08:00
wing328
661c911d27 Merge branch 'issue-3461-configurable-transport' of https://github.com/neilotoole/swagger-codegen into neilotoole-issue-3461-configurable-transport 2016-08-17 22:52:44 +08:00
wing328
0196cfad55 Merge pull request #3599 from ggood/okhttp-gson-template-path-fix
Don't escape path in generated okhttp-gson client code
2016-08-17 15:21:37 +08:00
wing328
c166609438 Merge pull request #3595 from MikeRalphson/patch-1
Fix typo, descripton -> description
2016-08-17 11:21:13 +08:00
Gordon Good
534e4db527 Don't escape path in generated okhttp-gson client code
The mustache templates for the other Java clients (e.g
Java/api.mustache) use 3 curly brackets around the path variable
so the path is not escaped. Make the okhttp-gson template
consistent with them.
2016-08-16 17:12:37 -07:00
Tony Tam
7bc9c4041b added configuration for swagger-yaml output file, #3597 2016-08-16 15:59:47 -07:00
Mike Ralphson
f6a91db2d3 Fix typo, descripton -> description 2016-08-16 22:42:00 +01:00
wing328
7a49f96a03 Merge pull request #3591 from scottrw93/read-only-fix
Create setter for models inline with Issue 3210
2016-08-16 16:03:14 +08:00
wing328
9858403f2e Merge pull request #3582 from regga-ws/compiler-customization
Adding support for JMustache compiler customization
2016-08-16 14:21:20 +08:00
Scott Williams
68d63ec783 Create setter for models inline with Issue 3210 2016-08-15 23:31:30 +01:00
Nekrasov Aleksander
91675c97e2 Fix resteasy offsetdatetime provier (#3332)
* Fix offsetDateTime and remove unnecessary override annotations

* Update petstore samples to CI for resteasy testing

* fix resteasy templates path

* add ability to hide generated annotations

* Update petstore resteasy samples

* Deduplicate artifact names in resteasy projects
2016-08-15 23:46:52 +08:00
Alexandre Estela
9d5e2c0224 Adding support for JMustache compiler customization 2016-08-12 12:21:10 +02:00
wing328
3d717bd874 add symbolic enum support to csharp 2016-08-12 16:27:47 +08:00
wing328
f7143727e7 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-08-12 15:38:00 +08:00
wing328
2943177d06 Merge branch 'kartenkarsten-patch-1' 2016-08-12 15:37:46 +08:00
wing328
621dee30a8 Merge branch 'patch-1' of https://github.com/kartenkarsten/swagger-codegen into kartenkarsten-patch-1 2016-08-12 15:33:02 +08:00
wing328
f746a93da4 Merge branch 'csharp/INotifyPropertyChanged' of https://github.com/jimschubert/swagger-codegen into jimschubert-csharp/INotifyPropertyChanged 2016-08-12 15:04:04 +08:00
wing328
4fe0b3350c Merge pull request #3576 from ModelSolv/issue-3572
Issue 3572 Remove duplicate CLI Options
2016-08-12 14:39:58 +08:00
wing328
02f43bc195 Merge branch 'feature/js-fix-types' of https://github.com/arikon/swagger-codegen into arikon-feature/js-fix-types 2016-08-12 10:08:24 +08:00
wing328
3c1e47c31d Merge branch 'feature/jack/update-swift-alamofire' of https://github.com/JackWink/swagger-codegen into JackWink-feature/jack/update-swift-alamofire 2016-08-12 08:59:12 +08:00
Sergey Belov
e01095f53b Fix Javascript types 2016-08-11 23:05:37 +03:00
Andy Lowry
90a113b441 Issue 3572 Remove dupe options in jaxrs-spec
Removed CLI option declarations in JavaJAXRSSpecServerCodegen that also
appear in AbstractJavaJAXRSServerCodegen.
2016-08-11 13:43:14 -04:00
wing328
752ba61e67 [Go] Add more test cases and fix numeric form/header parameters (#3574)
* add more tests for go, fix numeric form/header parameters

* update go sample
2016-08-11 14:28:31 +08:00
Ivan Vučica
cf0d9b48fd Go: Replace .Username with .UserName in generated API methods.
Right now, any generated code where the http basic authentication is
required is broken, as it tries to access nonexistent field in the
generated `Configuration` struct.

The alternative is to fix `configuration.mustache` to replace the
`UserName` field with `Username` field.
2016-08-10 21:36:35 +00:00
Ado Nishimura
eefb2152e9 [htmlDoc2] curl sample - conditionally add 'apiKey'. (#3561) 2016-08-10 16:43:47 +08:00
wing328
d2d5553a45 [Go] prefix go local var with localVar (#3570)
* prefix go local var with localVar

* remove pom from go, minor fix to headerParams
2016-08-10 16:14:33 +08:00
wing328
31fd1df26b Merge pull request #3562 from wing328/add_enum_endpoint
[Java][Spring] Add enum test cases and fix formParam's enum value
2016-08-09 23:32:04 +08:00
wing328
dbeb82f976 Merge pull request #3564 from cliffano/fix-incorrect-param-update-params-for-auth
Fix unknown parameter on api_client's update_params_for_auth method.
2016-08-09 23:27:15 +08:00
Karsten Hinz
03986761dc typo
eleif zu else if
2016-08-09 15:06:26 +02:00
wing328
d626200479 fix form enum parameters for spring generator, add more test cases 2016-08-09 19:49:38 +08:00
wing328
8ef3b61228 Merge pull request #3559 from wing328/java_jersey_indent
[Java] minor indentation fix for java enum models
2016-08-09 17:39:02 +08:00
Cliffano Subagio
aba2d35a18 Fix unknown parameter on api_client's update_params_for_auth method. 2016-08-09 19:11:26 +10:00
wing328
d4fa88a2ef Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-08-09 17:09:09 +08:00
wing328
79385aa503 Merge branch 'beingcoder-top-enum-error-securityscope-newline-error' 2016-08-09 17:08:51 +08:00
wing328
817a78e3a7 minor indentation fix for java enum models 2016-08-09 16:50:21 +08:00
wing328
e1fd176ae2 Merge branch 'patch-1' of https://github.com/kartenkarsten/swagger-codegen into kartenkarsten-patch-1 2016-08-09 16:26:25 +08:00
wing328
87c31188b7 Merge pull request #3550 from jimschubert/aspnet/models-casing
[aspnet] Honor casing of properties from definition
2016-08-09 14:55:03 +08:00
rynger
3faee1f6ce Amending Path annotation (#3553)
* Amending Path annotation

Changed the Path annotation value from "/" to "/{{baseName}}"

* jaxrs-cxf-petstore-server.sh script was not referencing cxf module directory. Included generated files following script run. Have amended Path annotation value to {{contextPath}} and removed public access modifier from template as this is redundant for Java interface definition.
2016-08-09 12:09:07 +08:00
wing328
c4835ea52e [TypeScript] fix array enum (#3538)
* better enum support for typescript angular2

* fix enum property for TS

* fix non-array enum datatype for TS

* update build name for TS fetch petstore client

* restore TS fetch enum naming

* [TS fetch]add test cases, fix enum integer naming
2016-08-09 10:49:26 +08:00
wing328
7a245e3189 [JavaScript] add enum tests cases for JS generator (java) (#3546)
* add enum tests cases for JS generator (java)

* fix typo quote
2016-08-08 18:52:24 +08:00
wing328
ad3d9cd3b4 Merge pull request #3529 from JackDanger/danger/allow-go-config
Restore ability to configure Go
2016-08-08 18:30:18 +08:00
wing328
39e0e22c57 Merge pull request #3534 from arnested/php-enums-in-containers
[PHP] Fix enum validation in container setters
2016-08-08 18:29:44 +08:00
wing328
aed66aeee9 Merge pull request #3524 from dmytrobr/bug/issue-3523
support Title as model name for any inline object
2016-08-08 18:28:57 +08:00
Cliffano Subagio
3f7127b042 [Java] Add maven-javadoc-plugin to all Java clients. (#3503)
* Add maven-javadoc-plugin to all Java clients.

* Update sample petstores for other Java clients.

* Fix unknown parameter on api_client's update_params_for_auth method.

* Revert "Fix unknown parameter on api_client's update_params_for_auth method."
To be moved to a separate PR.

This reverts commit 1ee186694241bb6d9a0dccefcdca5afe3f5a1dd2.
2016-08-08 18:27:05 +08:00
wing328
328eb5b9e3 Merge pull request #3548 from wing328/php_enum_test_cases
[PHP] add enum test cases for PHP generator (java)
2016-08-08 18:22:43 +08:00
Jim Schubert
c744e55217 [csharp] client property validations 2016-08-07 21:24:55 -04:00
Tony Tam
c4f3cb1d9e updated dev versions 2016-08-07 23:03:44 +02:00
Tony Tam
be3a49183e Merge branch 'master' into release-prepare 2016-08-07 18:41:16 +02:00
wing328
d8cdcbf042 fix jsoncreator annotation issue with java api clients using gson 2016-08-08 00:16:12 +08:00
Jim Schubert
adc445a5ff [aspnet] Honor casing of properties from definition 2016-08-07 09:14:07 -04:00
Tony Tam
c147cfde1b updated release versions 2016-08-07 11:49:01 +02:00
Jim Schubert
3d7f6ad099 [csharp] documented help switch for generating property change 2016-08-06 21:38:52 -04:00
wing328
b547d56d29 add enum test case to php generator (java) 2016-08-07 06:39:56 +08:00
Jim Schubert
797afe9d15 [csharp] PropertyChanged support .NET 4.x+ 2016-08-06 16:54:50 -04:00
wing328
e8095c6a04 Merge pull request #3543 from guohuang/compile_issue2
[GO] Fixing compilation issue when pathParams  is not presented
2016-08-06 14:07:00 +08:00
wing328
c220dbb2f5 Merge pull request #3541 from expectedbehavior/configuration-misspelling
Fix spelling in ruby ApiClient: Configuraiton -> Configuration
2016-08-06 13:10:46 +08:00
Guo Huang
bef5c74da7 removed unneeded "errors" import 2016-08-05 21:34:04 -07:00
Guo Huang
ab96b318e2 [GO] Fixing compilation issue when pathParams is not presented 2016-08-05 14:53:05 -07:00
Joel Meador
950fb43fdf fix spelling in ruby ApiClient: Configuraiton -> Configuration 2016-08-05 14:36:08 -04:00
wing328
148a842f3b fix #2538 (#3535) 2016-08-05 18:09:00 +08:00
Arne Jørgensen
03c7e3ea0b [PHP] Fix enum validation in container setters
When the setter is taking an array as argument we cannot use
`in_array()` to validate if the values are part of the allowed enum
values. Instead we use `array_diff()` for containers now.
2016-08-05 10:53:02 +02:00
wing328
47738f6cd6 [Sinatra][Nancyfx] fix enum in Sinatra and nancyfx (#3532)
* fix enum in sintra and nancyfx

* add isContainer check for sinatra allowable value

* fix EOL in nancyfx enum template
2016-08-05 16:30:59 +08:00
wing328
122af80881 better symbol mapping for enum name 2016-08-05 11:28:07 +08:00
Jack Danger Canty
6010c1e6d8 Restore ability to configure Go 2016-08-04 15:40:18 -07:00
wing328
89fe3403a7 add enum test case for jersey2 2016-08-05 01:57:34 +08:00
Dmytro Kryvoshei
fe5c235727 fixed InlineModelResolver to support Title as model name for any inline
object

InlineModels defined within MapProerty and ArrayProerty were not using
"title".
Added Unit Tests
2016-08-04 08:57:16 -04:00
wing328
670f103859 better enum naming for symbol (java) 2016-08-04 16:37:48 +08:00
Neil O'Toole
70d8041cb4 fixed config to support transport, and other options 2016-08-03 20:42:21 -06:00
wing328
0547f0d6d8 fix spring enum model 2016-08-03 16:38:02 +08:00
wing328
81f981c54d Merge pull request #3506 from wing328/fix_array_enum
[JaxRS][PHP] Fix issue with enum
2016-08-03 14:50:05 +08:00
wing328
26c33d344d Merge pull request #3507 from chrislewis/gen-readme-typo
s/It's/Its
2016-08-03 12:14:36 +08:00
Chris Lewis
3bd01b988e s/It's/Its 2016-08-02 15:50:25 -04:00
wing328
811b5940eb update jaxrs with better test, fix enum issue, patch operation 2016-08-03 01:36:34 +08:00
wing328
1fde95f997 fix java okhttp (array of enum property) 2016-08-03 01:36:34 +08:00
wing328
25fa3e86f9 add enumName to store the enum prefix 2016-08-03 01:36:13 +08:00
wing328
0b8acb5b0c set allowablevalues of inner enum's allowablevalues 2016-08-03 01:35:58 +08:00
Himanshu Mishra
24d8c621c2 Using baseName in place of paramName in request header. Closes #3502 2016-08-02 21:38:26 +05:30
wing328
bbe422947f Merge pull request #3501 from wing328/revert_3391_2
Revert "Merge branch 'feature/objc-tasks' of https://github.com/wberger/swagger-codegen"
2016-08-02 18:28:15 +08:00
wing328
ed9dea6a89 Revert "Merge branch 'feature/objc-tasks' of https://github.com/wberger/swagger-codegen"
This reverts commit 7c1daab896, reversing
changes made to aa58497247.
2016-08-02 17:49:55 +08:00
wing328
7bd37468bc Merge pull request #3496 from Kvezon/jersey2-byte-array-deserialize
Support byte[] downloading in Java jersey2 client
2016-08-02 16:24:40 +08:00
wing328
390ec38ec7 Merge pull request #3482 from cliffano/master
[Java] Add maven-javadoc-plugin in pom.xml of generated Java client.
2016-08-02 16:19:29 +08:00
wing328
1886abb9f9 Merge pull request #3487 from szantopeter/master
fixing bug of rendering an extra spaces into @FeignClient annotation
2016-08-01 23:12:39 +08:00
Kvezon
ef526422e9 Support byte[] downloading in Java jersey2 client 2016-08-01 16:33:58 +03:00
osher
30776d75a9 NodeJS generator - Harken to the the warnings ...
2 types of warnings are emitted in bulk whenever using the nodeJS generator.

I did some guesswork: since JS is a c-type language like C# and Java - I looked there for reference, and followed their example.
2016-08-01 13:40:29 +03:00
Arne Jørgensen
cfe8dfc112 [PHP] Fix invalid PHP syntax
Fixes 3480.
2016-08-01 11:46:57 +02:00
wing328
1bdd15c55c Merge branch 'feature/confluencewikidocs' of https://github.com/jhitchcock/swagger-codegen into jhitchcock-feature/confluencewikidocs 2016-08-01 17:25:20 +08:00
wing328
85c8eb3d76 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-08-01 17:25:13 +08:00
wing328
4895a35200 Merge pull request #3492 from wing328/ruby_optional_validation
[Ruby] fix validation for optional parameters/properties for ruby
2016-08-01 17:12:39 +08:00
wing328
8c357dd1d6 fix validation for optional parameters/properties for ruby 2016-08-01 16:50:11 +08:00
wing328
434b4fd359 Merge pull request #3447 from jhitchcock/feature/static-docs-2
[WIP] - Html Docs 2 - API and Client Library Documentation - Feedback / Assistance wanted
2016-08-01 16:13:16 +08:00
Arne Jørgensen
0f8e1f8105 [PHP] Client properties validation #3457 (#3480)
* [PHP] Avoid validation of unset, optional parameters

Fixes #3457.

* [PHP] Regenerate petstore samples
2016-08-01 15:24:47 +08:00
abcsun
d7c959fe42 [PHP] add AbstractPhpCodegen to be as the base class of PHP-related generators (#3310)
* add abstractPhpCodegen

* This base class should provide common functions to PHP-related generators so that the same enhancements or bug fixes can be applied to all clients.

Most source be moved from the PhpClientCodegen.

* change Lumen codegen to use the AbstractPhpCodegen

* remove the composerVendorName/composerProjectName. modify the LumenServerOptionsTest for unit test

* add context path

* reserve the apiDocPath and modelDocPath

* add the templateDir for lumen
2016-08-01 15:23:35 +08:00
Yao, Yao
62921e4eb4 issue fix: for top enum definition, either enum parameter or enum model definition, auto-generated code is invalid. 2016-08-01 14:40:35 +08:00
Yao, Yao
a772a855ee issue fix: when security.scope. description has a precedent | ,newline in markdown, generated api will break as an extra newline is added. 2016-08-01 14:35:27 +08:00
wing328
3d7ff26c67 [C#] Add C# Petstore test to AppVeyor (#3489)
* update appveyor.yml to test c# petstore client

* update csproj file

* add docker version test

* add docker version

* add docker

* add cpuid.ps1

* comment out cpuid

* use start process

* remove mvn test

* remove comments related to docker

* fix appveyor to run local petstore, shippable caching turned on

* add comments to ci config

* remove cpuid.ps1

* update C# petstore sample
2016-07-31 22:37:06 +08:00
Peter Szanto
c91b004b0b fixing bug of rendering an extra spaces into @FeignClient annotation properties 2016-07-31 04:16:22 +02:00
wing328
7c1daab896 Merge branch 'feature/objc-tasks' of https://github.com/wberger/swagger-codegen 2016-07-30 16:17:08 +08:00
Jack Wink
f2ebb08b33 [Swift] Use the latest Alamofire (3.4.1)
This commit updates the Swift client templates to be compatible with the
latest version of Alamofire. It bumps the dependency version in the
podspec and names the argument when calling `responseData`. We found
that XCode was having trouble with the overloaded methods and needed the
named argument for hinting.
2016-07-29 21:57:08 -07:00
jhitchcock
c377153336 Confluence Wiki Documentation 2016-07-29 12:09:03 +02:00
wing328
293096f565 Merge pull request #3476 from philicious/qt5-generator-fixes
Qt5: Added missing datatype handlers for QByteArray for swagger-type "byte"
2016-07-29 09:43:50 +08:00
wing328
4e17221494 Merge pull request #3471 from cbornet/fluent_containers
[JAVA] Add fluent methods to add items to list and put items to maps
2016-07-29 09:33:31 +08:00
philicious
a67f168fa6 Qt5: add handling for swagger type-format "byte" to Qt5 generator 2016-07-28 19:34:45 +02:00
philicious
b2cb215741 Qt5: added missing data type handler for QByteArray to SWGHelper 2016-07-28 19:29:33 +02:00
Cliffano Subagio
8d4cfcae78 Add maven-javadoc-plugin in pom.xml of generated Java client. 2016-07-28 23:06:57 +10:00
cbornet
3b4465d999 add fluent methods to add items to list and put items to maps 2016-07-27 18:18:48 +02:00
Neil O'Toole
75403f1900 removed unused import 2016-07-27 09:35:04 -06:00
Karsten Hinz
926d4a2b76 improved Multipart/form-data file upload support
this code will fix #3389 ( change of content Type to MediaType.APPLICATION_OCTET_STREAM_TYPE)
+ possibility for multi file upload (as List)
2016-07-27 13:06:05 +02:00
wing328
3cd37bf5e9 fix casting issue with ModelImpl in Haskell 2016-07-27 18:07:35 +08:00
Neil O'Toole
154d0fc9de #3462 using base name in request instead of caseified paramName 2016-07-26 18:11:36 -06:00
Neil O'Toole
39228c7c94 #3459 removed check for required params 2016-07-26 15:07:57 -06:00
wing328
0beb4aa303 Merge pull request #3458 from wing328/go_fix_apikey
[Go] fix API key issue with Go client
2016-07-27 01:17:03 +08:00
wing328
743219aa08 fix apikey issue with go client 2016-07-26 23:05:08 +08:00
wing328
2b66128954 Merge pull request #3454 from wing328/bug/fix_3223
Clear import mapping for gnereators that do not use it
2016-07-26 15:47:34 +08:00
Yi
b3403015fd fix scalatra path with basepath (#1425) (#3448) 2016-07-26 14:49:33 +08:00
wing328
9489f7d3eb clear import mapping for gnereators that do not use it 2016-07-26 14:40:29 +08:00
wing328
30c2503f9f [C#][NancyFX] Better "Add" for Dictionary and using {{packageName}} for NancyFX (#3449)
* use square bucket for C# dictionary

* use packageName for nancyfx generator, update info to debug for log

* use packageName for nancyfx generator, update info to debug for log
2016-07-26 14:10:48 +08:00
jhitchcock
aaba4b9e82 Html Docs 2 - API and Client Library Documentation 2016-07-25 15:36:05 +02:00
Jim Schubert
52cfd0f86f [C#] RootNamespace/AssemblyName use packageName
Uses packageName instead of packageTitle for RootNamespace and
AssemblyName in the C# generate client project. packageTitle is intended
to add additional information to AssemblyInfo.cs, and changing
packageTitle to non-FQN text breaks adding new files to the project.

packageTitle, per CodegenConstants description:

"Specifies an AssemblyTitle for the .NET Framework global assembly
attributes stored in the AssemblyInfo file."
2016-07-24 11:21:06 -04:00
Christian Loitsch
bf17a91275 dart codegen improvements (#3440)
* fix: query params may be ints as well

don't assume query params are Strings or List<String>s

* fix dart: use correct type for QueryParams

type is Iterable, not List

only check params for != null if they haven't been checked already

add some casts to make strong mode happy

update petstore

* feat dart: enable strong mode

* feat dart: generate both browser and vm library

move petstore client into subdirectory and reference
generated libraries using path in pubspec.yaml

* feat dart: refactor petstore test.

The new layout resembles a real project.

petstore test is now strong mode compatible.

* feat: add DateTimerParser transformer

* feat: improved exception reporting

* feat[dart]: handle patch requests

* fix[dart]: typo

* fix dart: remove findPetsByTag test; enable strong-mode

find pets by tag call is deprecated and returns 500

generated library is now strong mode compatible
2016-07-23 23:45:22 +08:00
Tao Qian
55bf8b1f96 Stop Shortening Underscore in Enum Value (#3401)
* stop shortening underscore

* use 4 space indentation

* remove fake class and use anonymous class instead

* rename
2016-07-21 21:37:54 +08:00
wing328
13ec3dc6bb [C#] fix remaining reference to NUnit 3.2.1 (#3433)
* fix remaining reference to 3.2.1 of nunit

* fix nunit runner path
2016-07-21 21:23:40 +08:00
wing328
f74bf84017 download C# nunit to 2.x (#3432) 2016-07-21 18:17:43 +08:00
wing328
a916696f28 fix #3427 using String() (#3431) 2016-07-21 17:44:10 +08:00
guohuang
f6c523bcd6 fixed all routing to v2 (#3428) 2016-07-21 11:44:43 +08:00
delenius
c888434580 Improve jsdoc for API return values (#3327)
* Add jsdoc for usePromises, add @link for callbacks

* Update petstore samples

* Improve jsdoc for void return type + usePromises

* Add back curly brackets correctly in model template

* Add link to Promise doc in jsdoc comment

* Fix jsdoc annotation for callApi method

The return type annotation was also broken here.
2016-07-20 20:14:51 +08:00
abcsun
bee6803bcb add context path (#3425) 2016-07-20 19:06:14 +08:00
Chris Jang
9c7710e695 Factory interface for typescript-fetch (#3398)
* Added Factory interface for typescript-fetch

* added tests

* Removed 'this.'

* Added Factory interface for typescript-fetch

* added tests

* Removed 'this.'
2016-07-20 18:00:52 +08:00
Andy
dfe4944552 Fix #3400 - incorrect MinLength and MaxLength on partial_model_generic.mustache template (#3415)
* fix maxLength and Regexp issue

* more fix

* revert some changes
2016-07-20 16:52:07 +08:00
wing328
889549a352 fix contextpath for php silex 2016-07-20 16:13:06 +08:00
wing328
9fcb8a310d fix #3418 - slim missing contextpath 2016-07-20 15:49:41 +08:00
wing328
d16b761aaf Merge pull request #3407 from lunat/csharp_api_key_header_issue_3295
Csharp api key header issue 3295
2016-07-20 15:29:53 +08:00
Jason Gavris
4f0b7dfaed [Swift] Handle binary data types 2016-07-19 11:05:40 -04:00
Jason Gavris
9e6896c8f0 [Swift] Fix pod authors in podspec 2016-07-19 10:37:20 -04:00
lunat
92e8efde1a Csharp api key header issue 3295 2016-07-19 14:37:03 +02:00
lunat
41bab483e0 Issue #3295
[csharp] header problem due to static method for adding header
2016-07-19 12:45:52 +02:00
wing328
ca4a90d64d Merge pull request #3404 from wing328/objc_fix_empty_desc
To set a default description if none is provided
2016-07-19 17:09:01 +08:00
wing328
37404909bf to set a default description if none is provided 2016-07-19 16:55:39 +08:00
wing328
118fd4d84d Merge pull request #3393 from cbornet/java_inheritance
Set supportInheritance to true for java based gens
2016-07-19 16:15:53 +08:00
wing328
d780e3a5f5 fix #3400 (ruby minLenght, maxLength) 2016-07-19 15:16:07 +08:00
wing328
b9479ae8b7 Merge pull request #3271 from ButterflyNetwork/swift-uuid
[Swift] Add support for NSUUID
2016-07-19 14:16:45 +08:00
wing328
60af9e7a83 Merge pull request #3375 from ButterflyNetwork/swift-progress
[Swift] Expose NSProgress to RequestBuilder
2016-07-19 13:46:50 +08:00
wing328
77097ec76a Merge pull request #3364 from michaelkourlas/michaelkourlas-patch-1
Correct reference to ApiClient default instance
2016-07-19 13:44:52 +08:00
wing328
b3a6535d1e Merge pull request #3385 from wing328/fix_mvn_warning
Fix maven warning and update maven plug-ins to the latest version
2016-07-19 13:10:49 +08:00
wing328
dc8eb8e8ad Merge pull request #3394 from clasnake/3171/scalatra_petstore_error
Fix the scalatra petstore sample compile error.
2016-07-19 13:10:26 +08:00
Jason Gavris
cd79ae1ab4 [Swift] Add support for NSUUID 2016-07-18 23:30:01 -04:00
Jason Gavris
87b79e5946 [Swift] Expose NSProgress to RequestBuilder 2016-07-18 23:29:29 -04:00
cbornet
34d3a5e8d0 make jersey tests wait that jetty is closed before terminating 2016-07-18 23:21:12 +02:00
clasnake
5e4e84ffe7 Fix the scalatra petstore sample compile error. 2016-07-18 23:58:03 +08:00
cbornet
421c462ba9 set supportInheritance to true for java based gens 2016-07-18 16:33:20 +02:00
wing328
4da6ecf6a6 Merge pull request #3384 from keithballdotnet/patch-1
[Go] ParameterToString can panic
2016-07-18 22:17:12 +08:00
Wolfgang Berger
f37bd4ab49 rename ApiClient to ApiSessionManager, return cancellable tasks instead of request IDs which greatly reduces state while offering real cancellation, change to a protocol-based configuration with a default implementation, include a workarount for current JSONModel concurrency issues, add missing super call in QueryParamCollection initWithValuesAndFormat 2016-07-18 13:01:57 +02:00
Wolfgang Berger
e73f2a5c64 Merge branch 'upstream-master' into feature/objc-sessionmanager-integration
* upstream-master:
  update JAR URL to 2.2.0
  updated dev versions
  set interface with discriminator as parent
  null check
  updated readme
  updated versions for release
  update java petstore sample
  derive invoker package name from api/modoel package name
2016-07-18 12:02:32 +02:00
Tony Tam
39cb6a24db updated dev versions 2016-07-17 15:43:30 -07:00
cbornet
8740b4d0ea set interface with discriminator as parent
If a composed model (allOf) doesn't have any parent and one of its interface has a discriminator field, then set this interface as parent.

See #2096
See https://github.com/swagger-api/swagger-parser/pull/246
2016-07-17 14:38:03 -07:00
Tony Tam
bd0340327b Merge branch 'wing328-java_fix_apiclient' into release-prepare 2016-07-15 22:37:35 -07:00
Tony Tam
3346388056 null check 2016-07-15 21:39:58 -07:00
Tony Tam
fbada6ef11 Merge branch 'java_fix_apiclient' of https://github.com/wing328/swagger-codegen into wing328-java_fix_apiclient 2016-07-15 14:41:46 -07:00
Tony Tam
c49db091ef updated versions for release 2016-07-15 13:45:22 -07:00
Wolfgang Berger
d120902e4b integrate latest objc changes into objc-sessionmanager 2016-07-15 15:36:24 +02:00
wing328
9056a5a56c fix mvn warning, update mvn plug-in version 2016-07-15 21:21:58 +08:00
keithballdotnet
cb547c113a ParameterToString can panic
Let the fmt package help convert the obj to a string.  Previously this could panic if the obj was an int.
2016-07-15 14:55:11 +02:00
wing328
67a674bf3d derive invoker package name from api/modoel package name 2016-07-15 17:42:05 +08:00
wing328
0405db7a97 Merge pull request #3264 from ButterflyNetwork/swift-iso-date
[Swift] Use ISO-8601 date format
2016-07-15 08:33:49 +08:00
wing328
2d35743b0d Merge pull request #3368 from wing328/ruby_fix_rspec
[Ruby] fix default rspec test cases for Ruby API client
2016-07-14 22:13:34 +08:00
wing328
069a6b2917 fix defeault rspec test for ruby, update security petstore 2016-07-14 18:22:01 +08:00
wing328
4f52cebf7a improve ts node enum naming 2016-07-14 17:14:06 +08:00
wing328
3ae0ffa819 Merge branch 'patch-1' of https://github.com/ircecho/swagger-codegen into ircecho-patch-1 2016-07-14 15:32:41 +08:00
Michael Kourlas
a4c589c346 Correct reference to ApiClient default instance 2016-07-13 13:56:43 -04:00
wing328
0986acd2a6 Merge pull request #3359 from sinofool/master
Not compare Java String with "=="
2016-07-13 20:50:36 +08:00
wing328
8da6e0a533 fix csharp enum naming 2016-07-13 19:11:22 +08:00
wing328
e2d74de6ca fix double hyphen in c# generator 2016-07-13 18:16:52 +08:00
Bochun Bai
f75a42f810 Remove more Java String comparison using "==" 2016-07-13 18:06:45 +08:00
Bochun Bai
6d4d81b652 Not compare Java String with "=="
Replaced with equals()
2016-07-13 17:27:11 +08:00
wing328
9bfb52dbc1 fix csharp code sample 2016-07-13 16:22:58 +08:00
wing328
c873a52f84 Merge pull request #3325 from inc-cloitsch/rmCrypto_fixRequiredParams_useAsyncAwait_addMultiQueryParams
dart: fix required params.  add 'multi' query params.  better deserialization.
2016-07-13 16:13:41 +08:00
Christian Loitsch
8003156fd8 feat dart: add pubName to all remaining library parts 2016-07-12 19:42:11 +02:00
ircecho
66619b1a09 fix[ruby]: Problem with List of Enum
Fixes #3323
2016-07-12 18:21:34 +02:00
Christian Loitsch
a5351f7ec0 feat dart: add pubName to library name.
Otherwise projects may not use different apis generated by swagger,
because library names must be unique.
2016-07-12 18:05:40 +02:00
Christian Loitsch
0d0d353b9d feat dart: mv basePath to ApiClient
Changing the basePath is pretty annoying otherwise, because
you would need to set the basePath for every Api.
2016-07-12 17:18:45 +02:00
wing328
394840e352 Add more security samples (#3344)
* add line break test to petstore-security-test.yaml

* add objc/swift security testing

* add go,scala,qt5cpp for security test

* add security test for typescript

* fix go security issue, fix consumes,produces line break
2016-07-12 19:51:28 +08:00
wing328
d4951bbf3c Leverage Shipable.io to validate mustache templates (#3333)
* add run all petstore shell script

* add run all petstore batch file for windows tests

* better output for travis and appveyor

* add shippable config to test all petstore

* show log after test script

* remo all-petstore, update travis build

* update shiippable config

* add run-all-petstore

* failure test using ruby model

* use bash script for run-all-petstore

* update script permission

* fix html batch script

* fix missing doc in jaxrs spec generator

* fix missing api, model test in jaxrs spec generator

* rename licenseInfo for lumen

* remove ruby model failure (for CI test)

* fix "the input line is too long"

* update windows batch file to shorten the commands

* update appveyor config

* update shippable config

* add build script

* update batch file to remove args option

* fix window batch file for spring mvc/boot

* remove logging output to file
2016-07-11 13:54:18 +08:00
wing328
1c5210581e fix model name "client" issue 2016-07-10 17:42:18 +08:00
wing328
0119a66479 fix https://github.com/swagger-api/swagger-codegen/pull/3313/files#r70178399 2016-07-10 16:55:36 +08:00
Christian Loitsch
9a65a5f0db feat: improve / fix deserialization by parsing type String
* added api_helper.dart for a helper function.
* defaultApiClient is now a variable instead of a static field inside
  ApiClient
* a lot of functions inside ApiClient are no longer static.
* optional params are now named params  (needed to introduce a
  justIgnoreFlag as hack)
* queryParams now support the multi format and are therefore no longer a
  Map<String, String>, but a List<QueryParam>
* renamed apiException.mustache to api_exception.mustache to conform
  with other file names.
* removed unused import: 'dart:html'
* removed 'package:crypto/crypto.dart' dependency.  'dart:convert' has a
  base64 converter now.
* use null-aware operator for apiClient assignment in xxxApi
  constructors.
* enable testStoreApi (which returned a Future nobody waited for)
* fix types in tests.  Some ids were passed as Strings instead of ints.
* adapt tests to use the optional named arguments (for optional query
  args)
* generate random ids in tests.  Otherwise insertion will always succeed
  if the test has been called once.
2016-07-08 15:02:28 +02:00
wing328
89741c75f7 Merge pull request #3276 from zhenjun115/issue2499
add more tips about npe;
2016-07-08 14:01:43 +08:00
tao
638319db09 add DefaultParam annotation 2016-07-07 11:45:22 -07:00
wing328
aaeae3f0d3 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-07-07 22:18:37 +08:00
wing328
89befeb45b fix long issue in python3 2016-07-07 22:17:27 +08:00
wing328
cb71c4ce31 Merge pull request #3313 from lunat/CSharp_documentation_with_anchor_link
CSharp Documentation with working anchor link within document
2016-07-07 21:15:58 +08:00
wing328
41e8273cb8 Merge branch 'master' of https://github.com/maneeshsahu/swagger-codegen into maneeshsahu-master 2016-07-07 19:13:29 +08:00
wing328
ef1666dd55 Merge pull request #3319 from wing328/word_full_java_util
[Java] update wording for fullJavaUtil option
2016-07-07 18:42:46 +08:00
wing328
1276941cc7 update wording for full util option 2016-07-07 18:31:18 +08:00
wing328
2418448a3c update swagger core to 1.5.9 for java feign client 2016-07-07 17:48:43 +08:00
wing328
6add9acfaf Merge branch 'issue3051' of https://github.com/zhenjun115/swagger-codegen into zhenjun115-issue3051 2016-07-07 17:35:45 +08:00
wing328
7fbe1aee07 Merge pull request #3317 from wing328/retrofit1_wording
[Java][Retrofit] update wording for java retrofit1
2016-07-07 17:05:30 +08:00
wing328
9c4d77ed1a update wording for java retrofit1 2016-07-07 16:35:59 +08:00
wing328
c5cc0bbb2a fix issue with java feign client 2016-07-07 15:53:17 +08:00
wing328
3b780e30d8 change java default lib to okhttp-gson 2016-07-07 15:53:16 +08:00
wing328
d402f35711 Merge pull request #3163 from DanGe42/master
Improve error message for connection failures
2016-07-07 14:29:27 +08:00
wing328
d621021fb1 Merge branch 'vovan--issue-3193' 2016-07-07 13:51:17 +08:00
wing328
612afe1809 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-07-07 11:38:57 +08:00
wing328
4d76dd24eb Merge branch 'master' of https://github.com/jencodingatwork/swagger-codegen into jencodingatwork-master
Conflicts:
	modules/swagger-codegen/src/main/resources/JavaJaxRS/formParams.mustache
2016-07-07 11:34:36 +08:00
wing328
d70989c2b3 Merge branch 'issue-3193' of https://github.com/vovan-/swagger-codegen into vovan--issue-3193 2016-07-07 11:06:16 +08:00
wing328
9830e82add Merge pull request #3294 from cbornet/spring_cloud
[Spring] Add a generator for spring cloud feign clients
2016-07-07 10:59:56 +08:00
wing328
b997dd15ad Merge pull request #3306 from jimschubert/aspnet5_.NET_Core_1.0
[aspnet5] update to asp.net core 1.0
2016-07-07 10:59:01 +08:00
Daniel Ge
b16eda17e8 Improve error message for connection failures
Previous ApiException message would simply print out the result of the
`curl_getinfo($curl)` call, which might be useful only if the developer
actually wanted very low-level information from curl about why a call
failed. The new message should print out a higher-level but more
informative, human-readable message. If necessary for debugging, the
ApiException's responseObject is set to the `curl_getinfo($curl)`.
2016-07-06 12:09:41 -07:00
tao
62d06f75b4 use baseName instead of paramName 2016-07-06 10:41:57 -07:00
Christian Loitsch
0466405fa5 fix: verification of requiredParams now works
other features:
- remove crypto dependency.  base64 encoding is now part of
  dart.convert.
- port Java query param handling to dart. → allows us to use 'multi'
  collectionFormat for queryParams
- use async await where possible.
2016-07-06 17:45:39 +02:00
lunat
5648c5af88 CSharp Documentation with working anchor link within document 2016-07-06 16:26:59 +02:00
cbornet
e2c7dc0147 don't repackage as a spring boot app 2016-07-06 15:29:54 +02:00
vovan-
01e06c01eb Fixed issue [Spring] Add support for the contextPath in Spring-boot gen #3193 2016-07-06 14:21:13 +03:00
wing328
f7b223e1a9 fix test cases in python 2016-07-06 16:34:09 +08:00
cbornet
412022b852 add petstore samples and fix some issues 2016-07-06 10:30:10 +02:00
cbornet
a761682115 add a generator for spring cloud feign 2016-07-06 10:30:09 +02:00
wing328
3a3461f961 Merge pull request #3299 from wing328/android_volley_license
[Android][Volley] add Apache v2 license to Android Volley API client
2016-07-06 11:27:58 +08:00
wing328
c1d835dcfc Merge pull request #3287 from lrimkus/patch-1
Python vnd content-type header support
2016-07-06 11:27:20 +08:00
Jim Schubert
ae73bb7553 [aspnet5] Update to ASP.NET Core 1.0.0
This migrates the server generator for aspnet5 from 1.0.0-rc1-final to
1.0.0.

Changes are fairly significant in how Kestrel hosts the application, as
well as how Swagger finds XML comments for documentation. Changes are
only related to hosting, docker, and configuration.
2016-07-05 22:17:14 -04:00
jencodingatwork
c3a9d6c9c3 Modified JavaJaxrs resources to fix duplicated variable names. See issue
#3300 for full description.
2016-07-05 12:36:08 -04:00
laurynas
560f50ab9a case insensitive search for "json" in content-type headers 2016-07-05 11:31:18 -04:00
wing328
6b4b2025ee add license to android volley 2016-07-05 22:39:38 +08:00
wing328
b699fe57fc add license header to java default client 2016-07-05 22:16:53 +08:00
lunat
43d1c5bffc CSharp client header problem
CSharp client may cause an error adding an header because the header
list is static.
Added a check and a function tu set up the ApiKey
2016-07-05 14:42:43 +02:00
wing328
430f49aae6 fix javadoc error 2016-07-05 20:38:04 +08:00
wing328
5e6a6de351 fix javadoc error 2016-07-05 19:38:33 +08:00
wing328
dfc05f4bba fix doc warning in java retrofit2 client 2016-07-05 17:49:50 +08:00
Laurynas
23b81324d1 Python vnd content-type header support
Adding vendor header support like : "Content-Type: application/vnd.api+json" and "Content-Type: application/vnd.api+json; version=1"
2016-07-04 15:27:54 -04:00
Laurynas
df695ee2c4 Python vnd content-type header support
Adding vendor header support like : "Content-Type: application/vnd.api+json" and "Content-Type: application/vnd.api+json; version=1"
2016-07-04 15:22:54 -04:00
wing328
785d1a5648 add option to set ssl host setting in ruby client 2016-07-04 22:13:25 +08:00