Commit Graph

95 Commits

Author SHA1 Message Date
mobreza
b433afebdd withXml replaces useJaxbAnnotations (#6152)
* Regenerated bin/jaxrs-*

* Replace `useJaxbAnnotations` with `withXml`
2017-08-03 15:35:33 +08:00
wing328
11d9cbd597 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-07-16 16:10:08 +08:00
wing328
34e94fbed0 Updated versions for 2.2.3 release and other minor enhancements (#6070)
* update pom to prepare 2.2.3 release

* add header support to qt5, update samples

* update version in java help

* update to xcode 9

* rollback to xcode8.2
2017-07-16 01:03:40 +08:00
zmoore-usgs
7e723e4ae5 Updated comments 2017-07-14 14:17:12 -05:00
zmoore-usgs
4e40d370a6 Switched methods to use the list application functions rather than the string application functions. 2017-07-14 14:10:48 -05:00
zmoore-usgs
7d82b05d4c Moving instantiationTypes, typeMappings, languageSpecificPrimitives, additionalProperties, and reservedWordsMappings out of configOptions and converting it into a list, rather than being a comma-separated string. 2017-07-14 12:54:09 -05:00
wing328
67bbb8349e Merge remote-tracking branch 'origin/master' into 2.3.0 2017-07-13 15:39:05 +08:00
wing328
eb498e23b8 run "mvn formatter:format" on maven plug-in 2017-07-13 15:37:15 +08:00
wing328
e964702550 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-07-12 21:54:23 +08:00
mobreza
5d32edd964 Java support for application/xml (#5962)
* WIP: CodegenProperty with XML

* WIP: CodegenModel XML bits

* WIP: Jackson XML

* WIP: Java templating

* WIP: Java client withXml flag

* WIP: resttemplate work

* WIP: withXml only when Jackson is used

* WIP: Tabs to spaces

* WIP: java-petstore-resttemplate-withxml sample

* WIP: language: spring

* WIP: language "spring" using library "spring-boot" should include apiPackage in @ComponentScan to detect the API

* WIP: javax.xml for non-Jackson Java and enabled payload logging for jersey2

* WIP: updated java petstore samples

* WIP: JavaSpring with non-jackson XML

* WIP: bin/spring-all-pestore.sh
2017-07-11 17:01:51 +08:00
wing328
9269dac6cf Merge remote-tracking branch 'origin/master' into 2.3.0 2017-07-01 15:47:27 +08:00
Dennis Kieselhorst
a64c7d7986 updated jackson-version (#5943) 2017-06-29 10:56:12 +08:00
Dennis Kieselhorst
eb6c6d0698 use enforcer-plugin to fix Maven warning (#5940) 2017-06-29 00:22:26 +08:00
wing328
5d7ff49658 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-28 16:23:55 +08:00
Dennis Kieselhorst
4f6e2857cc removed obsolete jersey2-version (#5933) 2017-06-28 16:22:29 +08:00
wing328
41527ead54 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-05-24 20:13:31 +08:00
mtakaki
165c116661 Moving import-mappings out of configOptions and converting it into a list, rather than being a comma-separated string. (#5384)
* Moving import-mappings out of configOptions and converting it into a list, rather than being a comma-separated string. #5383

* Making the change to importMappings backwards compatible
2017-05-23 21:46:27 +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
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
7662924ce1 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-10 23:32:06 +08:00
Simon Marti
1734ac4ed0 Add option to skip Maven plugin execution (#5337)
* Add option to skip Maven plugin execution

The execution is skipped if either the codegen.skip property or the <skip>
configuration parameter is set. This is consistent with how many other Maven
plugins, such as maven-exec-plugin and maven-clean-plugin, handle this.

* Add documentation for Maven `skip` property
2017-04-10 23:31:58 +08:00
Simon Marti
fea8699d8b Fix environment variable support in successive Maven plugin executions (#5351)
* Fix environment variable support in successive Maven plugin executions

System properties were retained across multiple successive executions,
resulting in unpredictable behavior. Property values are now properly reset
to their original value after plugin execution.

Fixes #5350

* Add explanation to environment variable reset mechanism in Maven plugin
2017-04-10 23:25:09 +08:00
wing328
c35fdc3bda Merge remote-tracking branch 'origin/master' into 2.3.0 2017-04-10 14:39:48 +08:00
Johannes
e147fdec48 swagger-codegen-maven-plugin: hint added how to generate server code (#5342)
addresses issue #5332
2017-04-07 08:46:42 +08:00
wing328
004cf6611e Merge remote-tracking branch 'origin/master' into 2.3.0 2017-03-23 14:15:10 +08:00
Simon Marti
375e34fe12 Fix selective generation in successive Maven plugin executions (#5152)
Options passed as system properties are properly reset when
disabled in the execution configuration.

Fixes #5151
2017-03-23 00:49:57 +08:00
wing328
9749585886 Merge remote-tracking branch 'origin' into 2.3.0 2017-03-18 15:47:15 +08:00
Brian Towles
0895e292c4 Add Selective Generation support to the Maven plugin. (#5036)
* Updated maven plugin to allow for selective generation

* Documentation of Selective generation options.
2017-03-18 15:46:10 +08:00
wing328
775f108d4e update version to 2.2.3-SNAPSHOT (#4894) 2017-03-02 16:54:37 +08:00
Tony Tam
8504c12ce0 update to release versions 2017-03-01 14:22:34 -05:00
wing328
acd10318f7 Merge remote-tracking branch 'origin' into sync_master_230 2017-02-10 23:31:36 +08:00
eblis
869374125f #4625 - Check if configOptions are set before trying to get the source folder, otherwise assume null/empty. (#4626)
(reworked pr)
2017-01-27 17:04:32 +08:00
wing328
029728d851 [maven-plugin] allow for ignore file override (#4597)
* [maven-plugin] allow for ignore file override

The .swagger-codegen-ignore file is beneficial for existing source
directories to provide pattern-based exclusion rules for existing source
to be ignored by swagger codegen. Until now, there's been no utility
other than skipOverwrite to modify the initial generation of code
(either via CLI or maven plugin).

This commit adds support for an ignoreFileOverride option to both the
CLI and the maven plugin.

Example CLI usage:

```
java -jar swagger-codegen.jar generate \
    -i swagger.json -l csharp \
    -o target --ignore-file-override /path/to/ignore-file
```

Example Maven Plugin configuration:

```
    <build>
        <plugins>
            <plugin>
                <groupId>io.swagger</groupId>
                <artifactId>swagger-codegen-maven-plugin</artifactId>
                <version>2.2.2-SNAPSHOT</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>generate</goal>
                        </goals>
                        <configuration>
                            <inputSpec>${project.basedir}/src/main/resources/swagger.yaml</inputSpec>
                            <language>csharp</language>
                            <invokerPackage>io.swagger</invokerPackage>
                            <modelPackage>io.swagger.models</modelPackage>
                            <apiPackage>io.swagger.apis</apiPackage>
                            <ignoreFileOverride>/Users/jim/projects/swagger-codegen/.sample-ignore</ignoreFileOverride>
                            <configOptions>
                            </configOptions>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
```

* [maven-plugin] update new javadocs

* fix bad merge due to missing }
2017-01-19 23:17:25 +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
Alex Nolasco
26ead9b58f Issue 4416 (Assist escapeReservedWord with custom mappings) (#4480)
* Preliminary implementation for issue-4416

* Updated README.md with  reserved-words-mappings  parameter.
2017-01-09 18:22:25 +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
Tadhg Pearson
79a71fd697 Update docs for Java code generation (#4303)
* Updated documentation to support Java code generation

* Tabs to spaces in example pom
2016-12-05 17:34:37 +08:00
Nick Maynard
4c05d5f098 Allow Java source formatting mvn formatter:format (#4214)
Uses Eclipse formatting tools with a configuration matching Google's style guide (plus our customisations).
2016-11-23 15:07:25 +08:00
wing328
43af07a2d4 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-11-16 16:44:39 +08:00
mbohlool
355e694fb2 Add gitUseID and gitRepoID flags to maven plugin 2016-11-15 17:35:13 -08:00
wing328
255bc02b83 Merge remote-tracking branch 'origin/master' into 2.3.0 2016-11-09 16:37:11 +08:00
Stephan Wienczny
9436ba106c Default added sourceFolder to src/main/java
Fallback to "src/main/java" for added source folder instead of a NullpointerException when no source folder ist configured in the pom
2016-11-04 15:35:48 +01:00
wing328
c7efb7000c Merge remote-tracking branch 'origin/master' into 2.3.0 2016-10-19 15:45:15 +08:00
wing328
1e57ba96d7 Correct source folder for generated files 2016-10-17 00:48:14 +08:00
wing328
766b04a2bd Merge remote-tracking branch 'origin/master' into 2.3.0 2016-09-12 23:30:15 +08:00
Brent Ryan
95d63a6f1f Bump version of pom to 2.3.0-SNAPSHOT for the 2.3.x release 2016-09-07 09:22:56 -04:00
Ville Skyttä
b4c139f19b Spelling fixes 2016-08-27 02:34:33 +03:00
wing328
d7d351682f Merge pull request #3610 from michalyao/master
update to version 2.2.2
2016-08-18 10:17:35 +08:00