Commit Graph

4328 Commits

Author SHA1 Message Date
wing328
aed21bba73 better code format for nodejs server (#4411) 2016-12-23 02:05:10 +08:00
Jun Mukai
27f1b6ee98 Introduce NodeJS codegen for Google Cloud Functions. (#4406)
* Another approach: extending NodeJS server to support GCF.

This does not add a new language, but adding some client options
to support Google Cloud Functions (GCF).

* Add URLs for how to deploy the generated code.

Adds the client options help message and the README.md file.
2016-12-22 23:11:52 +08:00
Anton Vasin
41701a15b0 Fix typo. Creactor -> Creator (#4443) 2016-12-22 23:08:06 +08:00
Ezekiel Templin
e189388371 [Ruby] Add Rakefile and Gemfile (#4448)
* Add Rakefile, Gemfile, and update client generator

* Update sample
2016-12-22 21:37:12 +08:00
Michael Fulton
d7afb22f1f Fix Integer stub value defaulting to String in nodejs-server if format not specified (#4436)
* check if property is a BaseIntegerProperty. This can occur when format is not specified in Swagger definition

* Change coding style to be more consistent
2016-12-21 15:08:14 +08:00
wing328
204c05442d [ObjC] minor code style enhancement to ObjC API client (#4437)
* minor code style enhancement to objc api client

* update petstore sample

* remove datatype from docstring (objc)
2016-12-20 19:13:03 +08:00
wing328
4870cf4ab1 Merge branch 'Ignore_Javatypes_On_ModelPre_and_Suffixes' of https://github.com/d0x/swagger-codegen into d0x-Ignore_Javatypes_On_ModelPre_and_Suffixes 2016-12-20 17:46:52 +08:00
Vincent Giersch
7f980cd9dd fix(swift3): lowercase enum value before checking reserved words (#4357)
Signed-off-by: Vincent Giersch <vincent@giersch.fr>
2016-12-20 16:35:03 +08:00
Greg Rashkevitch
36b97c22af Fix warning docs return type (#4429)
* Objective C: Fix compilation warnings

If returnType is not provided, set the @return as void

* Run the `./bin/objc-petstore.sh`

* OBJECTIVE C SDK: Remove the return line for methods that return nothing all together

* obj-c sdk: Updated petstore sample
2016-12-20 16:10:47 +08:00
Johan Nystrom
ff70105484 Fix CSV collection parameter issues for scalatra server (#4426)
* Fix scalatra handling of CSV query parameters

* Ran petstore for scalatra server
2016-12-20 16:02:45 +08:00
wing328
4c398a4cba Merge pull request #4434 from chasetec/master
Update DefaultGenerator.java to call close()
2016-12-20 15:52:00 +08:00
wing328
43ff85db76 Merge pull request #4421 from wing328/fix_isfile_boolean
Fix `isPrimitiveType` for file property
2016-12-20 15:48:55 +08:00
Matthieu Chase Heimer
da1e07af21 Update DefaultGenerator.java to call close()
Need to call out.close() after IOUtils.copy(in, out); when writing supporting files.
2016-12-19 13:25:10 -06:00
wing328
7fd895b37d fix isPrimitiveType for file 2016-12-18 19:02:26 +08:00
wing328
8ccf9828e4 [Python] add hasConsumes/hasProduces to Python API template (#4419)
* add hasConsumes/hasProduces to python api template

* remove unused code in python

* fix isFile in the api doc (python)
2016-12-18 17:20:10 +08:00
wing328
6bf721f2e3 add parameter as reserved keyword (#4410) 2016-12-17 00:29:06 +08:00
wing328
2172cfef84 add warning message for null inner type (map/array) (#4408) 2016-12-16 19:41:54 +08:00
Hamed Ramezanian Nik
6af43dc720 [csharp] Escape special characters in the API doc (#4183)
Special characters like <> should be HTML escaped.
2016-12-16 19:07:00 +08:00
Nicholas DiPiazza
c6c8ffe4e0 Do not NPE when array properties items are not specified (#4063) 2016-12-16 19:04:13 +08:00
Brian Shamblen
bd81f3264d [html2] Fix import statements for most languages (#4243)
* [html2] Clean up namespace issues in code samples

* pull c# and php package namespace from --additional-properties arg

phpInvokerPackage arg now sets the PHP namespace and packageName sets
the CSharp namespace. invokerPackage still works for Java and Android
namespace.
2016-12-16 18:06:28 +08:00
Christoph Keller
6ade001663 CodegenResponse.isListContainer is false for array types. (#4400)
CodegenResponse's isListContainer property is always false for "array" types. Don't know where the check for "list" comes from but in CodegenOperation, there's a check for "list" and "array".
No mustache file makes use of isListContainer inside responses yet, so should not change any existing behavior.
2016-12-16 12:08:24 +08:00
Yohana Khoury
91af8066cd boolean values from JSON are treated as strings (#4229)
* Change the value types in additionalProperties and dynamicProperties to Object instead of String.
Change methods that insert values to these maps to use Object as the type of the value instead of String.

* Fix run-all-petstore run: use toString instead of casting
2016-12-16 11:56:38 +08:00
wing328
ffbead3f9d Merge branch 'master' into typescript-angular2-build-to-dist-folder 2016-12-15 21:40:48 +08:00
wing328
131cbeb350 remove generation timestamp 2016-12-15 19:34:15 +08:00
wing328
870c745e6f minor fix to java client options test 2016-12-15 19:30:35 +08:00
Cliffano Subagio
3bc3a40073 [java] Add licenseName and licenseUrl options. 2016-12-15 19:30:35 +08:00
wing328
7fc8b24001 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-12-15 00:42:51 +08:00
wing328
7b7e5e25ee Merge branch 'angular2-standalone-enums-support' of https://github.com/SamuelBeliveau/swagger-codegen into SamuelBeliveau-angular2-standalone-enums-support 2016-12-15 00:09:34 +08:00
wing328
a143e9c10c add int/long check for @min/@max in java model (#4395) 2016-12-14 22:21:52 +08:00
lukoyanov
a13dee7167 [Java] Play! Framework 2.4 WS client support + retrofit2 (#4270)
* implemented core integration with play 2.4 ws

* added shell script to test on CI

* added shell script to composite file for all java generators

* added some comments
changed promise param to Response<T> to allow access to http status code and raw response if needed

* removed unnecessary whitespace changes

* added java7 compatibility, play ws deps to pom.xml

* added generated play24 client

* fixed imports
2016-12-14 17:32:49 +08:00
wing328
0df8bd2140 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-12-14 16:27:14 +08:00
wing328
3957a1db1a Merge branch 'feature/file-response' of https://github.com/www2k/swagger-codegen into www2k-feature/file-response 2016-12-14 16:26:34 +08:00
Matan Rubin
5867728724 [JaxRS-CXF][bug #4330] support containers in return types (#4339)
* [JaxRS-CXF][bug #4330] support containers in return types

before this commit if a method returned a container (List or Map) of
THING (i.e. List<THING> or Map<String, THING>) the generated return type would
drop the container and only leave THING.
this commit fixes this issue such that the container type is properly
generated.

* regenerate jaxrs-cxf petstore sample
2016-12-14 13:58:56 +08:00
Bruno Santos
90cf1cab53 Date type should not include time (#4385)
Removed time section from Date type in example generators.

Issue #4359
2016-12-14 11:51:14 +08:00
Chris Putnam
4fa3595a41 [typescript-angular2] Fix syntax error (#4383)
* allow function so access token can be derived for each api call

* update tests

* update type for accessToken to be string or function that returns string

* fix syntax error
2016-12-14 11:50:02 +08:00
wing328
dbb66af73d [C#] Add auto-generated doc for c# 2.0 generator (#4354)
* add auto-generated doc for c# 2.0 generator

* update readme for c# 2.0

* update readme

* update namespace in the doc
2016-12-14 11:49:15 +08:00
wing328
a291d3113a [Android] better code format for Android (volley) API client (#4384)
* better code format for android volley

* better code format for apiinvoker, add docstring

* use 2-space indentation for pair class

* use 2 spaces indentation for other classes in android
2016-12-14 00:40:21 +08:00
wing328
b33d4ec30c add enum_outer_doc.mustache for android (#4381) 2016-12-13 17:54:23 +08:00
Dan Wilson
e55664cdc9 Remove invalid code from mustache for arrays. (#4266)
Rewrite ParameterToString to handle other slice types other than just string.
2016-12-13 16:13:06 +08:00
wing328
5818f2c882 [C++] better code format for cpprest templates (#4379)
* replace tab with 4-space in cpprest templates

* remove trailing whitespaces from templates

* fix code indentation in cpprest templates

* remove empty block in cpprest templates
2016-12-13 16:09:56 +08:00
weiyang
beeb02a2dc [html] Add type anchor to body param block (#4368)
* [html] Add type anchor to 'bodyParam' block

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

* [html][samples] Add type anchor to 'bodyParam' block

Signed-off-by: weiyang <weiyang.ones@gmail.com>
2016-12-13 15:52:22 +08:00
Scott Richter
da9d64d053 Fix for issue #4370 - Cpprest does not set Content-Type header on POST requests. (#4374)
* Fixed cpprest generator to include Content-Type header in requests.

* Fixing indent to use spaces.
2016-12-13 15:01:47 +08:00
Chris Putnam
0b5a6f25da [typescript-angular2] access token function (#4361)
* allow function so access token can be derived for each api call

* update tests

* update type for accessToken to be string or function that returns string
2016-12-13 00:39:09 +08:00
Paul Vollmer
77b92d7d11 Fix go client auth UserName var issue (#4245) 2016-12-13 00:19:20 +08:00
wing328
62aabfc6c1 Merge branch 'jfiala-beanval_2549' 2016-12-13 00:05:03 +08:00
wing328
d9de3b540d Merge branch 'beanval_2549' of https://github.com/jfiala/swagger-codegen into jfiala-beanval_2549 2016-12-13 00:01:44 +08:00
Dmitry Solovyov
bf50ea1366 fix the value for @Generated java annotation (#4366)
com.my.Generator.class.toString() returns "class com.my.Generator", and this value is then used in the javax.annotation.Generated annotation like that: @Generated(value = "class com.my.Generator").
Should use Generator.class.getName() instead, so we end up with @Generated(value = "com.my.Generator")
2016-12-12 18:38:39 +08:00
Frederick Cai
8e200970d4 [typescript-angular2] build to dist folder 2016-12-11 23:39:18 +13:00
wing328
130161fc43 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-12-10 01:02:22 +08:00
Sreenidhi Sreesha
c83c813865 Refactor Boolean properties to boolean. (#4326)
There is no good reason to use Boolean instead of boolean.
Using Boolean will lead to handling "null" state which is confusing.

This change removes changes the type of Boolean properties to boolean.
2016-12-10 00:37:50 +08:00