Commit Graph

452 Commits

Author SHA1 Message Date
jfiala
8952815b5f [Spring] Add beanvalidation annotations (#4600)
* update generated sample for spring boot #4091

* add beanvalidation annotations to spring #4091

* add tests for spring #4091

* cleanup spring-cloud (client lib) #4091

* update client sample spring-cloud #4091

* replace tabs

* add beanvalidation annotations to spring #4091

* add tests for spring #4091

* cleanup spring-cloud (client lib) #4091

* update client sample spring-cloud #4091

* replace tabs

* update spring-cloud sample
2017-01-26 23:45:36 +08:00
wing328
658b650285 Merge branch 'master' of https://github.com/karnik/swagger-codegen into karnik-master 2017-01-26 16:30:51 +08:00
Tony Tam
ecaa8b1ede tests, fix for #4647. Proper escaping project name per npmjs (#4648) 2017-01-25 17:08:54 +08:00
Jonathan Leitschuh
78f38f1a1f Add support for read-only values in spring model (#4629) 2017-01-25 16:34:55 +08:00
Johannes Fiala
c0bea5ead9 move beanvalidation code to AbstractJavaJAXRSServerCodegen.java #4091 2017-01-23 21:18:01 +01:00
Jonathan Leitschuh
36c3fa05e0 Allows for generation of spring controller code using the delegate pattern (#4439)
* Allows for generation of spring conroller code using the decorator pattern

* Change Decorator to Delegate in spring codegen
2017-01-19 17:58:39 +08:00
jfiala
6f4e82dc03 [Jaxrs-Resteasy] Add beanvalidation annotations (#4506)
* add beanvalidation to jaxrs-resteasy #4091

* replace tabs
2017-01-19 17:45:17 +08:00
wing328
157fcbc4aa fix invalid spec, update petstore samples (jaxrs, ruby) 2017-01-19 16:54:16 +08:00
wing328
5f1b11827a Merge branch 'master' into master 2017-01-19 16:03:15 +08:00
wing328
a8afaa8f77 remove /r from templates 2017-01-19 15:53:51 +08:00
wing328
ccecc2aac0 new file for jaxrs jersey1 2017-01-19 15:31:24 +08:00
wing328
1ae60b1f61 Merge branch 'jaxrs_jersey_beanval2' of https://github.com/jfiala/swagger-codegen into jfiala-jaxrs_jersey_beanval2 2017-01-19 15:30:54 +08:00
jfiala
ee7f9fc56c [Jaxrs] Add beanvalidation annotations and fix outer Enums (#4492)
* add beanvalidation to jaxrs and add support for outer Enums #4091

* cleanup Codegen #4091

* cleanup samples #4091

* cleanup tabs

* updated samples to petstore.yaml (before petstore.json)

* add support for DecimalMin/DecimalMax/Min/Max #4091

* add check for hideGenerationTimestamp #4091

* replace tabs

* correct line endings to lf
2017-01-19 15:13:11 +08:00
Jim Schubert
da6b57f3fc [aspnetcore] use default in model constructors, supports enums (#4573)
* [aspnetcore] Use default rather than null in ctor

See original issue #3608

This adds same model constructor logic to aspnetcore as what was added
to csharp generator by PR #4145.

This doesn't include NancyFX because model construction relies more on
object initialization in that generator.

* [aspnetcore] ctor defaults + enum support

This follows up to #4145, and modifies model constructors to use
default(x) instead of initializing to nulls. default(x) works in all
cases using intuitive default values it is intended to support.

Example:

  csharp> public enum Color { RED = -1, BLUE = 0, GREEN }
  csharp> var color = default(Color)
  csharp> color
  BLUE

In the above example, The default of BLUE=0 is expected. For nullable
enums, this would be null as a default.

The aspnetcore generated code is also updated to support enums and
nested enums to account for changed to the petstore.yaml used to
generate the sample.

* [aspnetcore] Regenerate sample
2017-01-18 16:43:12 +08:00
Dan Mikita
0a559f0dd2 Add support for modifier within the Jaxb XMLElement annotation (#4433)
* fixes #4432 Adding support for the  modifier within the Jaxb XMLElement annotation. Updated README with JaxbAnnotations configuration option.

* #4432 Running the Petstore files
2017-01-17 15:26:30 +08:00
Articus
4001503e63 PHP server generator ze-ph (Zend Expressive + Path Handler) (#4559)
* Server generator ze-ph (Zend Expressive + Path Handler)

* Command line scripts for new ze-ph generator
2017-01-16 01:05:04 +08:00
Yuta HIGUCHI
de5ea8a9d6 [JAX-RS/jersey2] Fix for incorrect JSON field name capitalization (#4458)
* Fix for all capital field name

* Cosmetic: remove trailing spaces

* Adding ./bin/jaxrs-petstore-server.sh output.
2017-01-10 23:37:25 +08:00
J. Fiala
6b17b92bb6 add check for isInteger (integer/decimal) 2017-01-06 16:46:59 +01:00
J. Fiala
5b532fd10e update language jaxrs (Jersey2) and samples 2017-01-06 15:16:39 +01:00
J. Fiala
dde24eb9c2 update jaxrs jersey1 templates and sample output #4091 2017-01-06 15:10:40 +01:00
Kevin Locke
df0c54d043 Support the empty string as an enumeration value (#4450)
When a string enumeration has the empty string as one of its available
values, the generated code for many languages is invalid because the
empty string can not be used as an identifier.  As with numbers and
symbols, provide a mapping to an English name which can be used as a
replacement.  In this case, "empty" for the empty string/empty value.

Signed-off-by: Kevin Locke <kevin@kevinlocke.name>
2017-01-06 19:30:47 +08:00
Simon Morris
aa1dc0fdd2 Updated Nancy from 1.4.1 to 1.4.3 (#4482) 2017-01-06 01:09:32 +08:00
William Cheng
ce899e3776 Merge remote-tracking branch 'origin/master' into 2.3.0
Conflicts:
	appveyor.yml
	modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractJavaCodegen.java
	modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/AbstractTypeScriptClientCodegen.java
	modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaClientCodegen.java
	modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/SpringCodegen.java
	modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/TypeScriptAngular2ClientCodegen.java
	modules/swagger-codegen/src/main/resources/Java/libraries/feign/pom.mustache
	modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/pom.mustache
	modules/swagger-codegen/src/main/resources/TypeScript-Fetch/api.mustache
	modules/swagger-codegen/src/main/resources/go/api.mustache
	modules/swagger-codegen/src/main/resources/objc/api-body.mustache
	modules/swagger-codegen/src/main/resources/objc/api-header.mustache
	modules/swagger-codegen/src/main/resources/typescript-angular2/configuration.mustache
	modules/swagger-codegen/src/main/resources/typescript-angular2/tsconfig.mustache
	modules/swagger-codegen/src/test/java/io/swagger/codegen/swift/SwiftModelTest.java
	modules/swagger-codegen/src/test/java/io/swagger/codegen/swift3/Swift3ModelTest.java
	modules/swagger-codegen/src/test/java/io/swagger/codegen/typescript/typescriptangular2/TypeScriptAngular2ModelTest.java
	samples/client/petstore-security-test/typescript-angular2/configuration.ts
	samples/client/petstore/go/go-petstore/docs/FakeApi.md
	samples/client/petstore/go/go-petstore/fake_api.go
	samples/client/petstore/go/go-petstore/pet_api.go
	samples/client/petstore/java/feign/pom.xml
	samples/client/petstore/java/feign/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/feign/src/main/java/io/swagger/client/api/PetApi.java
	samples/client/petstore/java/jersey1/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/jersey2-java8/src/main/java/io/swagger/client/RFC3339DateFormat.java
	samples/client/petstore/java/jersey2-java8/src/main/java/io/swagger/client/model/Animal.java
	samples/client/petstore/java/jersey2-java8/src/main/java/io/swagger/client/model/EnumTest.java
	samples/client/petstore/java/jersey2-java8/src/main/java/io/swagger/client/model/FormatTest.java
	samples/client/petstore/java/jersey2-java8/src/main/java/io/swagger/client/model/MixedPropertiesAndAdditionalPropertiesClass.java
	samples/client/petstore/java/jersey2/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/JSON.java
	samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/api/PetApi.java
	samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/PetApi.java
	samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/FakeApi.java
	samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/PetApi.java
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGPetApi.h
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGPetApi.m
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGStoreApi.h
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGStoreApi.m
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGUserApi.h
	samples/client/petstore/objc/core-data/SwaggerClient/Api/SWGUserApi.m
	samples/client/petstore/objc/core-data/SwaggerClient/Core/SWGApiClient.h
	samples/client/petstore/objc/core-data/SwaggerClient/Core/SWGConfiguration.h
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGPetApi.h
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGPetApi.m
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGStoreApi.h
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGStoreApi.m
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGUserApi.h
	samples/client/petstore/objc/default/SwaggerClient/Api/SWGUserApi.m
	samples/client/petstore/objc/default/SwaggerClient/Core/SWGApiClient.h
	samples/client/petstore/objc/default/SwaggerClient/Core/SWGConfiguration.h
	samples/client/petstore/objc/default/SwaggerClient/Core/SWGJSONResponseSerializer.h
	samples/client/petstore/qt5cpp/client/SWGPetApi.h
	samples/client/petstore/qt5cpp/client/SWGStoreApi.h
	samples/client/petstore/qt5cpp/client/SWGUserApi.h
	samples/client/petstore/typescript-angular2/default/configuration.ts
	samples/client/petstore/typescript-angular2/npm/README.md
	samples/client/petstore/typescript-angular2/npm/configuration.ts
	samples/client/petstore/typescript-angular2/npm/package.json
	samples/client/petstore/typescript-angular2/npm/tsconfig.json
	samples/client/petstore/typescript-fetch/builds/default/api.ts
	samples/client/petstore/typescript-fetch/builds/es6-target/api.ts
	samples/client/petstore/typescript-fetch/builds/with-npm-version/api.ts
	samples/client/petstore/typescript-fetch/tests/default/test/PetApiFactory.ts
	samples/client/petstore/typescript-fetch/tests/default/test/StoreApiFactory.ts
	samples/server/petstore/jaxrs-resteasy/default/src/gen/java/io/swagger/api/PetApi.java
	samples/server/petstore/jaxrs-resteasy/default/src/gen/java/io/swagger/api/PetApiService.java
	samples/server/petstore/jaxrs-resteasy/joda/src/gen/java/io/swagger/model/User.java
	samples/server/petstore/spring-mvc/src/main/java/io/swagger/api/FakeApi.java
	samples/server/petstore/spring-mvc/src/main/java/io/swagger/api/FakeApiController.java
	samples/server/petstore/springboot/src/main/java/io/swagger/api/FakeApi.java
	samples/server/petstore/springboot/src/main/java/io/swagger/api/FakeApiController.java
2017-01-05 17:44:39 +08:00
Johannes Fiala
1a1d0aebc8 add beanvalidation to jersey1 and jersey2 #4091 2017-01-04 17:36:28 +01:00
mkarnik
45002ec1fd [JAX-RS RESTEasy][issue #4447] Updated RESTEasy petstore samples 2016-12-23 10:37:17 +01:00
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
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
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
cbornet
bcc7e69fcc [Flask] Add packaging support 2016-11-23 18:40:37 +01:00
wing328
44ca30df63 Merge pull request #4215 from cbornet/flask_param_name
[Flask] fix parameter naming
2016-11-23 15:42:42 +08:00
wing328
474dae08cf update NodeJS readme to remove oudated doc (#4232) 2016-11-22 10:42:15 +08:00
cbornet
9322c8fb0e [Flask] fix parameter naming 2016-11-20 11:21:09 +01:00
Christophe Bornet
df15799839 [Flask] Add generated tests (#4209) 2016-11-19 16:31:31 +08:00
jfiala
b02d505ad9 Refine CXF Add Spring Annotation-Config + Jboss flag for CXF/Resteasy + fix OuterEnum (#4164)
* add json annotations

* add cli flag to check for jaxb annotations

* add CLI-flag for switching Spring-XML or annotation config #4088

* add cli flag for generating jboss depl. descriptor #4088

* add JbossFeature CLI flag to Resteasy #4088

* update/add tests #4088

* cleanup tabs #4088

* improve api formatting #4088

* refine formatting #4088

* refine formatting again #4088

* add separate CLI-flags for controlling junit test features #4088

* add json annotations

* add cli flag to check for jaxb annotations

* add CLI-flag for switching Spring-XML or annotation config #4088

* add cli flag for generating jboss depl. descriptor #4088

* add JbossFeature CLI flag to Resteasy #4088

* update/add tests #4088

* cleanup tabs #4088

* improve api formatting #4088

* refine formatting #4088

* refine formatting again #4088

* add separate CLI-flags for controlling junit test features #4088

* add check for void methods + assertNotNull(response) #4088

* add spaces for @Produces #4088

* allow build with no web.xml config #4088

* comment invocations of tests #4088

* update petstore sample jaxrs-cxf server with gen/java first #4088

* re-generate jaxrs-cxf with src/gen/java #4088

* add client jaxrs-cxf #4088

* add switch to load SwaggerUI automatically #4088

* update to CXF 3.1.8 including supportSwaggerUi flag #4088

* update to cxf 3.1.8 and swagger-core 1.5.10 #4088

* update generated petstore for jaxrs-cxf #4088

* change Spring Boot urls to root #4088

* fix spring xml config #4088

* fix external enum usage for jaxrs-cxf #4160

* cleanup jaxrs-annotations in impl class

* fix handling of multiparts #4088

* fix @Min/@Max comments in beanValidationQueryParams #4088

* add swagger-codegen-ignore file+add src/test/resources #4088

* add cli-flag for produces/consumes json in api #4088

* add test case for outerEnum #4160
2016-11-19 16:09:13 +08:00
wing328
cde24f1113 Merge pull request #4189 from cbornet/spring_cloud_operations
[Spring] Use tag operation grouping for spring-cloud
2016-11-18 16:51:36 +08:00
wing328
359e52b173 Merge pull request #4188 from cbornet/flask_operations
[Flask] Use x-swagger-router-controller in for operation routing
2016-11-18 14:23:45 +08:00
Nick Maynard
b7e9603e63 jaxrs-cxf-cdi :: Add a basic JAX-RS Application and CDI fixes (#4196)
* Add a basic JAX-RS Application and CDI fixes

* jaxrs-cxf-cdi :: Fix samples generation template dir

* jaxrs-cxf-cdi :: Regenerate samples

* jaxrs-cxf-cdi :: Clean up some checkstyle warnings
2016-11-18 14:00:53 +08:00
wing328
3d476debaf Merge pull request #4178 from cbornet/flask
[Flask] Add models support to Flask Connexion codegen
2016-11-18 13:56:59 +08:00
cbornet
1e6cab8a03 [Flask] Use x-swagger-router-controller in swagger.yaml for operation routing
Fix #4106
2016-11-17 19:21:05 +01:00
cbornet
e5daa6855c add models support to flask 2016-11-17 18:30:59 +01:00
wing328
88227e08e3 Remove Apache license from server stub generators (#4200)
* remove php apache license

* remove license in sample code, update nodejs to use unlicnese

* remove license from jaxrs generator

* remove license from server generator

* update pom.xml for jaxrs resteasy joda server
2016-11-17 00:37:21 +08:00
cbornet
4a196a9187 [Spring] Use tag operation grouping for spring-cloud
Instead of basepath based grouping that is used by Spring boot/MVC
2016-11-15 18:46:48 +01:00
wing328
255bc02b83 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-11-09 16:37:11 +08:00
wing328
cce410c463 add vendor extension to handle void response in jaxrs-cxf 2016-11-08 21:06:38 +08:00
wing328
46c4eb3869 update mxf4j sample 2016-11-07 23:54:47 +08:00
wing328
e78ce6fb1e Merge pull request #4059 from markus-wa/issue-4045
[JAXRS-CXF] Issue 4045 - Fixed enum marshalling & fromValue()
2016-11-07 23:42:29 +08:00
wing328
636623d0e9 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-11-04 19:17:35 +08:00
Christophe Bornet
70d93883cf [Java] Threetenbp dates support (#4029)
* [feign] add threetenbp support for feign clients

* [okhttp] add threetenbp support for okhttp clients

* [jersey] add threetenbp support for jersey clients

* [retrofit2] add threetenbp support for retrofit2 clients

* [spring] add threetenbp support for spring generators

* add a workaround in tests for a bug in the petstore

The petstore doesn't manage fractional digits of dates correctly when there are less than 3
2016-11-04 17:55:16 +08:00
Simon Morris
8fb33980dc Nancy fx work (#4107)
* Added switch to config to toggle use of yaml base path as module paths

* NancyFX template updated to return collections as array to allow framework to find views by type name for text/html mime type

* Added some more parser fixes for NancyFX

* Refactored collection parsers in Parameters.cs and changed some to return nullable collections to match the parameter mappings in AbstractCSharpCodegen

* re-ran petstore build
2016-11-02 21:35:01 +08:00
wing328
4eb75f8088 add back setter to spring model (readonly attr) 2016-11-02 15:40:00 +08:00
wing328
07c6fe9d0d Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-26 15:42:59 +08:00
wing328
983aec6250 add sample for java-msf4 2016-10-26 11:31:43 +08:00
Simon Morris
5855b479aa nancyfx basePath => modulePath toggle (#4053)
* fix NancyFX string parser

parser needs to access the Value parameter to enable the direct cast at line 102 when handling string parameters

* Updated nancyfx sample

* Added switch to config to toggle use of yaml base path as module paths
2016-10-24 23:07:16 +08:00
walthema
1e975637c9 Fixed enum marshalling & fromValue()
Added toString() to enums
2016-10-24 15:07:46 +02:00
wing328
af16601654 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-22 23:08:36 +08:00
Simon Morris
27be0ed197 fix NancyFX string parser (#4048)
* fix NancyFX string parser

parser needs to access the Value parameter to enable the direct cast at line 102 when handling string parameters

* Updated nancyfx sample
2016-10-22 22:53:56 +08:00
wing328
91923311e0 update undertow readme 2016-10-19 16:23:18 +08:00
wing328
c7efb7000c Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-19 15:45:15 +08:00
wing328
702344ed75 better handling of reserved words for sintatra, dart 2016-10-18 17:58:19 +08:00
Jim Schubert
c70a2a7481 [aspnetcore] Deprecating aspnet5 for aspnetcore
This moves previous aspnet5 functionality to aspnetcore, aspnet5 now
derives from the aspnetcore generator and logs a warning that it's
deprecated.

This will help resolve any confusion because ASP.NET 5 is terminology
referring to the project of around a year ago. ASP.NET Core 1.0 is the
new name for the technology, and further enhancements should target .NET
Core 1.0 rather than any old vNext or preview stuff.
2016-10-16 21:22:34 -04:00
wing328
6ac9f0f351 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-16 16:04:17 +08:00
cbornet
12a0fd6471 fix issues in spring templates
Wrong indentation and extra lines in api templates
Java8 default methods are used if dateLibrary is java8

Fix #3408
2016-10-14 17:57:20 +02:00
wing328
b3caf1d0c0 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-12 17:54:16 +08:00
Nick Maynard
823ce72e2e jaxrs-cxf-cdi POM template (#3958)
* Don't refer to missing class in Impl classes

* Add POM for jaxrs-cxf-cdi

* Correct jaxrs-cxf-cdi artifactId

* Update samples for jaxrs-cxf-cdi

* Regenerate jaxrs-cxf-cdi samples
2016-10-12 15:43:44 +08:00
wing328
a73ad79b9b Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-11 11:52:26 +08:00
wing328
d921a2b0c5 Merge branch 'resteasy_dates' of https://github.com/cbornet/swagger-codegen into cbornet-resteasy_dates 2016-10-11 00:51:34 +08:00
wing328
ba3f2eafd5 Merge branch 'master' of https://github.com/swagger-api/swagger-codegen 2016-10-11 00:48:08 +08:00
wing328
671f73b97f Merge branch 'jersey_dates' of https://github.com/cbornet/swagger-codegen into cbornet-jersey_dates 2016-10-11 00:47:02 +08:00
Christophe Bornet
6f2c139ff8 [Spring] Format datetime in rfc3339 (#3777)
* [spring-boot] format datetime in rfc3339

See #3727

* [spring-mvc] format datetime in rfc3339
2016-10-11 00:43:28 +08:00
Nick Maynard
dc2b8c29e2 Add a new JAX-RS server generator - jaxrs-cxf-cdi (#3940)
* Generate a JAX-RS server that assumes an Apache CXF framework on a Java EE server supporting CDI

* Samples for jaxrs-cxf-cdi

* Don't refer to missing class NotFoundException

* Update samples without missing NotFoundException reference
2016-10-10 17:18:27 +08:00
wing328
0712ebc33d Merge pull request #3954 from jimschubert/aspnet/3680
[aspnet] Fix .sln/.xproj guids
2016-10-10 09:17:49 +08:00
Jim Schubert
a94a27307d [aspnet] Fix .sln/.xproj guids
The AspNet5 generator was originally written to support project.json.
The Project.xproj was implemented without a valid project guid or root
namespace. During the transition period from project.json to
Project.xproj, VS2015 would fallback to project.json. Newer versions of
VS2015 don't seem to do this any longer.

This commit defines the project's guid correctly, and sets the project's
root namespace.

See: #3680
2016-10-09 08:31:35 -04:00
wing328
c1a6bbb86a [Python][Flask] fix python2 support in Flask (#3952)
* flask python2 petstore sample

* fix python2 support in flask
2016-10-09 14:06:55 +08:00
Jonathan Leitschuh
40610373f6 Update JavaJaxRS/resteasy/api.mustache to have swagger annotations (#3924)
* Update JavaJaxRS/resteasy/api.mustache to have swagger annotations

The annotations should now appear on generated resteasy API classes.

* Re-generate resteasy petstore sample

* Add swagger-annotations to rest-easy samples as a dependency

* Regenerat pom.xml and build.gradle files for resteasy
2016-10-06 13:18:50 +08:00
wing328
677f5f913f Merge pull request #3909 from apanzerj/apanzerj/fixupRails5Server
WIP: Fixup rails5 server
2016-10-05 01:16:47 +08:00
Adam Panzer
2aadbee8ed
validate(s)_presence_of
Migration should create pluralized table names
Change controller filenames
2016-10-03 14:47:01 -07:00
wing328
1840956320 Merge pull request #3913 from wing328/python_flask_no_tags
[Python][Flask] fix python flask controller issue without tag
2016-10-03 09:56:49 +08:00
wing328
4a74e788ec fix python flask controller without tag (default_controller) 2016-10-03 09:32:20 +08:00
Jim Schubert
b7708a44bf [aspnet5] Fix basePath application to operations (#3911)
* [aspnet5] Fix basePath application to operations

* [aspnet5] Regenerate sample
2016-10-02 21:56:19 +08:00
wing328
ec25bd793f [Java] Remove duplicated model description in Spring, JAX-RS models (#3887)
* fix duplicated description in spring model

* fix duplicated description in jaxrs models

* fix resteasy dependency
2016-09-28 19:34:38 +08:00
wing328
fa12cd3787 Replace ^M with new line (\r) in mustache template (#3865)
* fix jaxrs line break

* fix java gradle bat line break

* fix scala gradle line break

* fix undertow crt line break

* fix spring line break

* fix undertow line break in pom

* rollback undertwo petstore to use petstore.yaml
2016-09-26 16:49:44 +08:00
Yuta HIGUCHI
2155b7b09e [JaxRS]Show correct default value on CLI option description (#3862)
* Show correct default value on CLI option description

Fixes #3861

* Changes after ./bin/jaxrs-petstore-server.sh
2016-09-24 15:11:15 +08:00
wing328
f69d1500c3 [Python][Flask] use tags to organize Python Flask controllers (#3767)
* use tag to organize flask controller

* fix typo in python flask code gen

* fix operationId for flask generator
2016-09-20 21:11:06 +08:00
Steve Hu
d74a1fbed4 Add a new language generator for undertow-server framework (#3820)
* add undertow generator

* add apiException

* add undertow server code gen

* reovery sprintboot sample

* update handler

* output swagger.json and handler template change

* remove api template

* remove api.mustache

* update pom.xml

* update readme

* add config files

* add basePath to the handler and upgrade to 0.1.1 framework

* add additional files for release

* fixed the mvn verify issue

* update one template to fix compile error for fake petstore
2016-09-19 22:45:10 +08:00
cbornet
b7f2b28534 [resteasy] configure jackson to use rfc3339 dates 2016-09-14 17:37:04 +02:00
cbornet
1b1fe95855 [jersey] configure jackson to use rfc3339 dates 2016-09-14 12:17:33 +02:00
wing328
ac69f45ddc better format of model properties 2016-09-11 18:44:36 +08:00
Paŭlo Ebermann
bd3a15e273 Feature/#3738 extract abstract scala codegen (#3755)
* Issue #3738: extract AbstractScalaCodegen.

This seems to not change anything in the output, at least for the Petstore samples.

* Issue #3738: move languageSpecificPrimitives initialization to the super class

* Issue #3738 move CliOptions to AbstractScalaCodegen.

* Issue #3738 update samples.

Only one change, remove of unnecessary imports.
2016-09-11 18:00:38 +08:00
wing328
dcdea19cb8 erlang update readme, add petstore samples 2016-09-09 16:42:26 +08:00
Paul Ebermann
65ca059221 Issue #3738: regenerate Scala samples (no code changes). 2016-09-08 13:00:40 +02:00
wing328
4f0f128ddb fix enum value issue for jaxrs cxf 2016-09-08 17:30:20 +08:00
wing328
11ae12b09d [Scalatra] replace {} with : in scalatra path (#3694)
* replace {} with : in scalatra path

* remove unused var in scalatra code gen
2016-09-02 00:25:07 +08:00
Ville Skyttä
77a2973da4 lumen: Update petstore 2016-08-30 08:05:04 +03:00
Ville Skyttä
b4c139f19b Spelling fixes 2016-08-27 02:34:33 +03: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
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
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
wing328
d626200479 fix form enum parameters for spring generator, add more test cases 2016-08-09 19:49:38 +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
Jim Schubert
adc445a5ff [aspnet] Honor casing of properties from definition 2016-08-07 09:14:07 -04: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
670f103859 better enum naming for symbol (java) 2016-08-04 16:37:48 +08:00
wing328
0547f0d6d8 fix spring enum model 2016-08-03 16:38:02 +08:00
wing328
811b5940eb update jaxrs with better test, fix enum issue, patch operation 2016-08-03 01:36:34 +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
wing328
3cd37bf5e9 fix casting issue with ModelImpl in Haskell 2016-07-27 18:07:35 +08:00
wing328
81f5108bac [Scala][Scalatra] Include scalatra pestore in the CI tests (#3456)
* add CI coverage for scalatra server

* move scalatra test to the end
2016-07-26 16:04:54 +08:00
Yi
b3403015fd fix scalatra path with basepath (#1425) (#3448) 2016-07-26 14:49:33 +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
guohuang
f6c523bcd6 fixed all routing to v2 (#3428) 2016-07-21 11:44:43 +08:00
abcsun
bee6803bcb add context path (#3425) 2016-07-20 19:06:14 +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
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
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
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
2d24e9971c update jaxrs sample 2016-07-07 11:38:07 +08:00
wing328
e1fead8ee5 update spring petstore sample 2016-07-07 11:32:05 +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
wing328
1f0f08f886 update jaxrs jersey1 sample 2016-07-07 10:51:42 +08:00
cbornet
57f518fe93 change spring-mvc petstore artifact-id 2016-07-06 11:47:48 +02:00
Jim Schubert
4d5905c736 [aspnet5] Regenerate sample server 2016-07-05 22:22:20 -04:00
wing328
e2e0af1e6c Merge branch 'master' of https://github.com/arturdzm/swagger-codegen into arturdzm-master
Conflicts:
	README.md
2016-07-02 17:00:21 +08:00
wing328
3c9b172996 Merge pull request #3274 from wing328/fix_lumne
Remove security test from petstore-with-fake-endpoints-models-for-testing
2016-07-02 11:48:45 +08:00
wing328
393b44dcd2 remove security test from petstore-with-fake-endpoints-models-for-testing 2016-07-02 11:32:25 +08:00
wing328
691957875e Merge pull request #3185 from cbornet/common_jersey
[Jax-rs][jersey] Mutualize jersey 1 and jersey 2 templates
2016-07-02 11:19:40 +08:00
wing328
386d41db7f fix duplciated artifact id 2016-07-01 21:56:11 +08:00
wing328
c9d2bb8a96 add test for jaxrs resteasy joda 2016-07-01 21:40:34 +08:00
wing328
4a3d9358ee Merge pull request #3165 from abcsun/lumen
[PHP Lumen] sort the endpoints in ascending to avoid the route priority issure
2016-06-30 15:51:32 +08:00
wing328
de6b3cea70 fix slim windows path 2016-06-29 23:24:27 +08:00
wing328
a71c072609 Merge pull request #3224 from wing328/security_fix
[PHP] Better code injection handling for PHP API client
2016-06-28 15:19:41 +08:00
wing328
174222390a Merge pull request #3190 from thebignet/asyncCompletableFuture
using CompletableFuture instead of Callable for asynchronous controller in Spring Boot
2016-06-28 12:34:23 +08:00
wing328
ec2abe78e3 apply security fix to php lumne, silex, slim 2016-06-28 12:21:41 +08:00
Pedro J. Molina
4eb1565fad Update petstore sample for changes on PR #3212 2016-06-27 08:10:01 +02:00
Jean Detoeuf
4183bfc90c updated Java8 spring sample with CompletableFuture feature #3190 2016-06-26 11:25:54 +02:00
wing328
e0d030d33a Merge pull request #3139 from stunney/master
Issue #3138
2016-06-22 10:06:37 +08:00
wing328
c2f5d83d06 Merge branch 'nancyfx-codegen' of https://github.com/FinderSystems/swagger-codegen into FinderSystems-nancyfx-codegen
Conflicts:
	modules/swagger-codegen/src/main/java/io/swagger/codegen/CodegenModel.java
2016-06-21 23:47:49 +08:00
cbornet
426cc6b6b4 better enums and dependency update 2016-06-21 16:19:37 +02:00
cbornet
d4150d9a02 remove jersey2 sample as its now the jax-rs default 2016-06-20 23:48:42 +02:00
cbornet
5a489f334e mutualize jersey 1 and 2 server templates 2016-06-20 22:59:32 +02:00
cbornet
1062fa467e fix issues 2016-06-20 15:13:17 +02:00
cbornet
ec6a9257e2 put spring-mvc and spring-boot under the same language gen 2016-06-20 15:12:03 +02:00
cbornet
6c5def6936 fix missing java client library files 2016-06-20 10:32:02 +02:00
Marcin Stefaniuk
0d9a490c17 Petstore sample for NancyFX. 2016-06-20 10:13:25 +02:00