-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fe9636e
commit 1d4a343
Showing
43 changed files
with
2,135 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
generatorName: jaxrs-resteasy | ||
outputDir: samples/server/petstore/jaxrs-resteasy/java8 | ||
inputSpec: modules/openapi-generator/src/test/resources/2_0/petstore.yaml | ||
templateDir: modules/openapi-generator/src/main/resources/JavaJaxRS/resteasy | ||
additionalProperties: | ||
artifactId: jaxrs-resteasy-java8-server | ||
hideGenerationTimestamp: "true" | ||
dateLibrary: java8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
samples/server/petstore/jaxrs-resteasy/java8/.openapi-generator-ignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# OpenAPI Generator Ignore | ||
# Generated by openapi-generator https://github.com/openapitools/openapi-generator | ||
|
||
# Use this file to prevent files from being overwritten by the generator. | ||
# The patterns follow closely to .gitignore or .dockerignore. | ||
|
||
# As an example, the C# client generator defines ApiClient.cs. | ||
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: | ||
#ApiClient.cs | ||
|
||
# You can match any string of characters against a directory, file or extension with a single asterisk (*): | ||
#foo/*/qux | ||
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux | ||
|
||
# You can recursively match patterns against a directory, file or extension with a double asterisk (**): | ||
#foo/**/qux | ||
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux | ||
|
||
# You can also negate patterns with an exclamation (!). | ||
# For example, you can ignore all files in a docs folder with the file extension .md: | ||
#docs/*.md | ||
# Then explicitly reverse the ignore rule for a single file: | ||
#!docs/README.md |
32 changes: 32 additions & 0 deletions
32
samples/server/petstore/jaxrs-resteasy/java8/.openapi-generator/FILES
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
.openapi-generator-ignore | ||
README.md | ||
build.gradle | ||
pom.xml | ||
settings.gradle | ||
src/gen/java/org/openapitools/api/ApiException.java | ||
src/gen/java/org/openapitools/api/ApiOriginFilter.java | ||
src/gen/java/org/openapitools/api/ApiResponseMessage.java | ||
src/gen/java/org/openapitools/api/JacksonConfig.java | ||
src/gen/java/org/openapitools/api/LocalDateProvider.java | ||
src/gen/java/org/openapitools/api/NotFoundException.java | ||
src/gen/java/org/openapitools/api/OffsetDateTimeProvider.java | ||
src/gen/java/org/openapitools/api/PetApi.java | ||
src/gen/java/org/openapitools/api/PetApiService.java | ||
src/gen/java/org/openapitools/api/RFC3339DateFormat.java | ||
src/gen/java/org/openapitools/api/RestApplication.java | ||
src/gen/java/org/openapitools/api/StoreApi.java | ||
src/gen/java/org/openapitools/api/StoreApiService.java | ||
src/gen/java/org/openapitools/api/StringUtil.java | ||
src/gen/java/org/openapitools/api/UserApi.java | ||
src/gen/java/org/openapitools/api/UserApiService.java | ||
src/gen/java/org/openapitools/model/Category.java | ||
src/gen/java/org/openapitools/model/ModelApiResponse.java | ||
src/gen/java/org/openapitools/model/Order.java | ||
src/gen/java/org/openapitools/model/Pet.java | ||
src/gen/java/org/openapitools/model/Tag.java | ||
src/gen/java/org/openapitools/model/User.java | ||
src/main/java/org/openapitools/api/impl/PetApiServiceImpl.java | ||
src/main/java/org/openapitools/api/impl/StoreApiServiceImpl.java | ||
src/main/java/org/openapitools/api/impl/UserApiServiceImpl.java | ||
src/main/webapp/WEB-INF/jboss-web.xml | ||
src/main/webapp/WEB-INF/web.xml |
1 change: 1 addition & 0 deletions
1
samples/server/petstore/jaxrs-resteasy/java8/.openapi-generator/VERSION
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
5.2.1-SNAPSHOT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# JAX-RS/RESTEasy server with OpenAPI | ||
|
||
## Overview | ||
This server was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using an | ||
[OpenAPI-Spec](https://openapis.org), you can easily generate a server stub. | ||
|
||
This is an example of building a OpenAPI-enabled JAX-RS server. | ||
This example uses the [JAX-RS](https://jax-rs-spec.java.net/) framework. | ||
RESTEasy is used as JAX-RS implementation library and is defined as dependency. | ||
|
||
To run the server, please execute the following: | ||
|
||
``` | ||
mvn -Djetty.http.port=8080 package org.eclipse.jetty:jetty-maven-plugin:run | ||
``` | ||
|
||
You can then view the OpenAPI v2 specification here: | ||
|
||
``` | ||
http://localhost:8080/v2/swagger.json | ||
``` | ||
|
||
Note that if you have configured the `host` to be something other than localhost, the calls through | ||
swagger-ui will be directed to that host and not localhost! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
apply plugin: 'war' | ||
|
||
project.version = "1.0.0" | ||
project.group = "org.openapitools" | ||
|
||
repositories { | ||
maven { url "https://repo1.maven.org/maven2" } | ||
} | ||
|
||
dependencies { | ||
providedCompile 'org.jboss.resteasy:resteasy-jaxrs:3.0.11.Final' | ||
providedCompile 'org.jboss.resteasy:jaxrs-api:3.0.11.Final' | ||
providedCompile 'org.jboss.resteasy:resteasy-validator-provider-11:3.0.11.Final' | ||
providedCompile 'org.jboss.resteasy:resteasy-multipart-provider:3.0.11.Final' | ||
providedCompile 'javax.annotation:javax.annotation-api:1.2' | ||
providedCompile 'javax:javaee-api:7.0' | ||
providedCompile 'org.jboss.spec.javax.servlet:jboss-servlet-api_3.0_spec:1.0.0.Final' | ||
compile 'io.swagger:swagger-annotations:1.5.22' | ||
compile 'org.jboss.resteasy:resteasy-jackson2-provider:3.0.11.Final' | ||
providedCompile 'javax.validation:validation-api:1.1.0.Final' | ||
compile 'com.fasterxml.jackson.datatype:jackson-datatype-joda:2.9.9' | ||
compile 'joda-time:joda-time:2.7' | ||
//TODO: swaggerFeature | ||
compile 'io.swagger:swagger-jaxrs:1.5.12' | ||
|
||
testCompile 'junit:junit:4.13', | ||
'org.hamcrest:hamcrest-core:1.3' | ||
} | ||
|
||
sourceSets { | ||
main { | ||
java { | ||
srcDir 'src/gen/java' | ||
} | ||
} | ||
} |
Oops, something went wrong.