diff --git a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaClientCodegen.java b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaClientCodegen.java
index 7e0aa4ca0fd9..530c5aab2ba2 100644
--- a/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaClientCodegen.java
+++ b/modules/swagger-codegen/src/main/java/io/swagger/codegen/languages/JavaClientCodegen.java
@@ -549,16 +549,17 @@ public class JavaClientCodegen extends DefaultCodegen implements CodegenConfig {
}
} else if ("Long".equals(type)) {
if (example == null) {
- example = "56L";
+ example = "56";
}
+ example = example + "L";
} else if ("Float".equals(type)) {
if (example == null) {
- example = "3.4F";
+ example = "3.4";
}
+ example = example + "F";
} else if ("Double".equals(type)) {
- if (example == null) {
- example = "3.4D";
- }
+ example = "3.4";
+ example = example + "D";
} else if ("Boolean".equals(type)) {
if (example == null) {
example = "true";
diff --git a/modules/swagger-codegen/src/main/resources/Java/README.mustache b/modules/swagger-codegen/src/main/resources/Java/README.mustache
index 50e2cf3fbe99..cf447dcfff8b 100644
--- a/modules/swagger-codegen/src/main/resources/Java/README.mustache
+++ b/modules/swagger-codegen/src/main/resources/Java/README.mustache
@@ -4,7 +4,7 @@
Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
-## Installation & Usage
+## Installation
To install the API client library to your local Maven repository, simply execute:
@@ -29,9 +29,90 @@ After the client library is installed/deployed, you can use it in your Maven pro
{{artifactVersion}}
compile
-
```
+## Getting Started
+
+Please follow the [installation](#installation) instruction and execute the following Java code:
+
+```java
+{{#apiInfo}}{{#apis}}{{#-first}}{{#operations}}{{#operation}}{{#-first}}
+// Import classes:{{#hasAuthMethods}}
+//import {{{invokerPackage}}}.ApiClient;{{/hasAuthMethods}}
+//import {{{invokerPackage}}}.ApiException;{{#hasAuthMethods}}
+//import {{{invokerPackage}}}.Configuration;
+//import {{{invokerPackage}}}.auth.*;{{/hasAuthMethods}}
+//import {{{invokerPackage}}}.model.*;
+//import {{{package}}}.{{{classname}}};
+
+{{#hasAuthMethods}}
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+{{#authMethods}}{{#isBasic}}
+// Configure HTTP basic authorization: {{{name}}}
+HttpBasicAuth {{{name}}} = (HttpBasicAuth) defaultClient.getAuthentication("{{{name}}}");
+{{{name}}}.setUsername("YOUR USERNAME");
+{{{name}}}.setPassword("YOUR PASSWORD");{{/isBasic}}{{#isApiKey}}
+// Configure API key authorization: {{{name}}}
+ApiKeyAuth {{{name}}} = (ApiKeyAuth) defaultClient.getAuthentication("{{{name}}}");
+{{{name}}}.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//{{{name}}}.setApiKeyPrefix("Token");{{/isApiKey}}{{#isOAuth}}
+// Configure OAuth2 access token for authorization: {{{name}}}
+OAuth {{{name}}} = (OAuth) defaultClient.getAuthentication("{{{name}}}");
+{{{name}}}.setAccessToken("YOUR ACCESS TOKEN");{{/isOAuth}}
+{{/authMethods}}
+{{/hasAuthMethods}}
+
+{{{classname}}} apiInstance = new {{{classname}}}();
+{{#allParams}}
+{{{dataType}}} {{{paramName}}} = {{{example}}}; // {{{dataType}}} | {{{description}}}
+{{/allParams}}
+try {
+ {{#returnType}}{{{returnType}}} result = {{/returnType}}apiInstance.{{{operationId}}}({{#allParams}}{{{paramName}}}{{#hasMore}}, {{/hasMore}}{{/allParams}});{{#returnType}}
+ System.out.println(result);{{/returnType}}
+} catch (ApiException e) {
+ System.err.println("Exception when calling {{{classname}}}#{{{operationId}}}");
+ e.printStackTrace();
+}
+{{/-first}}{{/operation}}{{/operations}}{{/-first}}{{/apis}}{{/apiInfo}}
+```
+
+## Documentation for API Endpoints
+
+All URIs are relative to *{{basePath}}*
+
+Class | Method | HTTP request | Description
+------------ | ------------- | ------------- | -------------
+{{#apiInfo}}{{#apis}}{{#operations}}{{#operation}}*{{moduleName}}.{{classname}}* | [**{{operationId}}**]({{apiDocPath}}{{classname}}.md#{{operationId}}) | **{{httpMethod}}** {{path}} | {{#summary}}{{summary}}{{/summary}}
+{{/operation}}{{/operations}}{{/apis}}{{/apiInfo}}
+
+## Documentation for Models
+
+{{#models}}{{#model}} - [{{classname}}]({{modelDocPath}}{{classname}}.md)
+{{/model}}{{/models}}
+
+## Documentation for Authorization
+
+{{^authMethods}}All endpoints do not require authorization.
+{{/authMethods}}Authentication schemes defined for the API:
+{{#authMethods}}### {{name}}
+
+{{#isApiKey}}- **Type**: API key
+- **API key parameter name**: {{keyParamName}}
+- **Location**: {{#isKeyInQuery}}URL query string{{/isKeyInQuery}}{{#isKeyInHeader}}HTTP header{{/isKeyInHeader}}
+{{/isApiKey}}
+{{#isBasic}}- **Type**: HTTP basic authentication
+{{/isBasic}}
+{{#isOAuth}}- **Type**: OAuth
+- **Flow**: {{flow}}
+- **Authorizatoin URL**: {{authorizationUrl}}
+- **Scopes**: {{^scopes}}N/A{{/scopes}}
+{{#scopes}} - {{scope}}: {{description}}
+{{/scopes}}
+{{/isOAuth}}
+
+{{/authMethods}}
+
## Recommendation
It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
@@ -40,4 +121,3 @@ It's recommended to create an instance of `ApiClient` per thread in a multithrea
{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
{{/hasMore}}{{/apis}}{{/apiInfo}}
-
diff --git a/modules/swagger-codegen/src/main/resources/Java/api_doc.mustache b/modules/swagger-codegen/src/main/resources/Java/api_doc.mustache
index 6249e9b12d37..870e889d2085 100644
--- a/modules/swagger-codegen/src/main/resources/Java/api_doc.mustache
+++ b/modules/swagger-codegen/src/main/resources/Java/api_doc.mustache
@@ -35,12 +35,12 @@ HttpBasicAuth {{{name}}} = (HttpBasicAuth) defaultClient.getAuthentication("{{{n
{{{name}}}.setUsername("YOUR USERNAME");
{{{name}}}.setPassword("YOUR PASSWORD");{{/isBasic}}{{#isApiKey}}
// Configure API key authorization: {{{name}}}
-ApiKeyAuth {{{name}}} = defaultClient.getAuthentication("{{{name}}}");
+ApiKeyAuth {{{name}}} = (ApiKeyAuth) defaultClient.getAuthentication("{{{name}}}");
{{{name}}}.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//{{{name}}}.setApiKeyPrefix("Token");{{/isApiKey}}{{#isOAuth}}
// Configure OAuth2 access token for authorization: {{{name}}}
-OAuth {{{name}}} = defaultClient.getAuthentication("{{{name}}}");
+OAuth {{{name}}} = (OAuth) defaultClient.getAuthentication("{{{name}}}");
{{{name}}}.setAccessToken("YOUR ACCESS TOKEN");{{/isOAuth}}
{{/authMethods}}
{{/hasAuthMethods}}
diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/feign/README.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/feign/README.mustache
new file mode 100644
index 000000000000..50e2cf3fbe99
--- /dev/null
+++ b/modules/swagger-codegen/src/main/resources/Java/libraries/feign/README.mustache
@@ -0,0 +1,43 @@
+# {{artifactId}}
+
+## Requirements
+
+Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
+
+## Installation & Usage
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn install
+```
+
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
+
+```shell
+mvn deploy
+```
+
+Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
+
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+
+```xml
+
+ {{groupId}}
+ {{artifactId}}
+ {{artifactVersion}}
+ compile
+
+
+```
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
+
+## Author
+
+{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
+{{/hasMore}}{{/apis}}{{/apiInfo}}
+
diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/jersey2/README.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/jersey2/README.mustache
new file mode 100644
index 000000000000..50e2cf3fbe99
--- /dev/null
+++ b/modules/swagger-codegen/src/main/resources/Java/libraries/jersey2/README.mustache
@@ -0,0 +1,43 @@
+# {{artifactId}}
+
+## Requirements
+
+Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
+
+## Installation & Usage
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn install
+```
+
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
+
+```shell
+mvn deploy
+```
+
+Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
+
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+
+```xml
+
+ {{groupId}}
+ {{artifactId}}
+ {{artifactVersion}}
+ compile
+
+
+```
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
+
+## Author
+
+{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
+{{/hasMore}}{{/apis}}{{/apiInfo}}
+
diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/README.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/README.mustache
new file mode 100644
index 000000000000..50e2cf3fbe99
--- /dev/null
+++ b/modules/swagger-codegen/src/main/resources/Java/libraries/okhttp-gson/README.mustache
@@ -0,0 +1,43 @@
+# {{artifactId}}
+
+## Requirements
+
+Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
+
+## Installation & Usage
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn install
+```
+
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
+
+```shell
+mvn deploy
+```
+
+Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
+
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+
+```xml
+
+ {{groupId}}
+ {{artifactId}}
+ {{artifactVersion}}
+ compile
+
+
+```
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
+
+## Author
+
+{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
+{{/hasMore}}{{/apis}}{{/apiInfo}}
+
diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit/README.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit/README.mustache
new file mode 100644
index 000000000000..50e2cf3fbe99
--- /dev/null
+++ b/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit/README.mustache
@@ -0,0 +1,43 @@
+# {{artifactId}}
+
+## Requirements
+
+Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
+
+## Installation & Usage
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn install
+```
+
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
+
+```shell
+mvn deploy
+```
+
+Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
+
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+
+```xml
+
+ {{groupId}}
+ {{artifactId}}
+ {{artifactVersion}}
+ compile
+
+
+```
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
+
+## Author
+
+{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
+{{/hasMore}}{{/apis}}{{/apiInfo}}
+
diff --git a/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit2/README.mustache b/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit2/README.mustache
new file mode 100644
index 000000000000..50e2cf3fbe99
--- /dev/null
+++ b/modules/swagger-codegen/src/main/resources/Java/libraries/retrofit2/README.mustache
@@ -0,0 +1,43 @@
+# {{artifactId}}
+
+## Requirements
+
+Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
+
+## Installation & Usage
+
+To install the API client library to your local Maven repository, simply execute:
+
+```shell
+mvn install
+```
+
+To deploy it to a remote Maven repository instead, configure the settings of the repository and execute:
+
+```shell
+mvn deploy
+```
+
+Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
+
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+
+```xml
+
+ {{groupId}}
+ {{artifactId}}
+ {{artifactVersion}}
+ compile
+
+
+```
+
+## Recommendation
+
+It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
+
+## Author
+
+{{#apiInfo}}{{#apis}}{{^hasMore}}{{infoEmail}}
+{{/hasMore}}{{/apis}}{{/apiInfo}}
+
diff --git a/modules/swagger-codegen/src/main/resources/Java/model_doc.mustache b/modules/swagger-codegen/src/main/resources/Java/model_doc.mustache
index 322c40e9db4c..2f330e2eb98d 100644
--- a/modules/swagger-codegen/src/main/resources/Java/model_doc.mustache
+++ b/modules/swagger-codegen/src/main/resources/Java/model_doc.mustache
@@ -3,7 +3,7 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
-{{#vars}}**{{name}}** | {{#isPrimitiveType}}**{{datatype}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{datatype}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}}[optional] {{/required}}{{#readOnly}}[readonly] {{/readOnly}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}}
+{{#vars}}**{{name}}** | {{#isPrimitiveType}}**{{datatype}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{datatype}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}} [optional]{{/required}}{{#readOnly}} [readonly]{{/readOnly}}
{{/vars}}
{{/model}}{{/models}}
diff --git a/samples/client/petstore/java/default/README.md b/samples/client/petstore/java/default/README.md
index cc9672eab41a..83b757e82f41 100644
--- a/samples/client/petstore/java/default/README.md
+++ b/samples/client/petstore/java/default/README.md
@@ -4,7 +4,7 @@
Building the API client library requires [Maven](https://maven.apache.org/) to be installed.
-## Installation & Usage
+## Installation
To install the API client library to your local Maven repository, simply execute:
@@ -29,9 +29,133 @@ After the client library is installed/deployed, you can use it in your Maven pro
1.0.0
compile
+```
+
+## Getting Started
+
+Please follow the [installation](#installation) instruction and execute the following Java code:
+
+```java
+
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.model.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
+try {
+ apiInstance.addPet(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#addPet");
+ e.printStackTrace();
+}
```
+## Documentation for API Endpoints
+
+All URIs are relative to *http://petstore.swagger.io/v2*
+
+Class | Method | HTTP request | Description
+------------ | ------------- | ------------- | -------------
+*.PetApi* | [**addPet**](docs/PetApi.md#addPet) | **POST** /pet | Add a new pet to the store
+*.PetApi* | [**addPetUsingByteArray**](docs/PetApi.md#addPetUsingByteArray) | **POST** /pet?testing_byte_array=true | Fake endpoint to test byte array in body parameter for adding a new pet to the store
+*.PetApi* | [**deletePet**](docs/PetApi.md#deletePet) | **DELETE** /pet/{petId} | Deletes a pet
+*.PetApi* | [**findPetsByStatus**](docs/PetApi.md#findPetsByStatus) | **GET** /pet/findByStatus | Finds Pets by status
+*.PetApi* | [**findPetsByTags**](docs/PetApi.md#findPetsByTags) | **GET** /pet/findByTags | Finds Pets by tags
+*.PetApi* | [**getPetById**](docs/PetApi.md#getPetById) | **GET** /pet/{petId} | Find pet by ID
+*.PetApi* | [**getPetByIdInObject**](docs/PetApi.md#getPetByIdInObject) | **GET** /pet/{petId}?response=inline_arbitrary_object | Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
+*.PetApi* | [**petPetIdtestingByteArraytrueGet**](docs/PetApi.md#petPetIdtestingByteArraytrueGet) | **GET** /pet/{petId}?testing_byte_array=true | Fake endpoint to test byte array return by 'Find pet by ID'
+*.PetApi* | [**updatePet**](docs/PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
+*.PetApi* | [**updatePetWithForm**](docs/PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
+*.PetApi* | [**uploadFile**](docs/PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
+*.StoreApi* | [**deleteOrder**](docs/StoreApi.md#deleteOrder) | **DELETE** /store/order/{orderId} | Delete purchase order by ID
+*.StoreApi* | [**findOrdersByStatus**](docs/StoreApi.md#findOrdersByStatus) | **GET** /store/findByStatus | Finds orders by status
+*.StoreApi* | [**getInventory**](docs/StoreApi.md#getInventory) | **GET** /store/inventory | Returns pet inventories by status
+*.StoreApi* | [**getInventoryInObject**](docs/StoreApi.md#getInventoryInObject) | **GET** /store/inventory?response=arbitrary_object | Fake endpoint to test arbitrary object return by 'Get inventory'
+*.StoreApi* | [**getOrderById**](docs/StoreApi.md#getOrderById) | **GET** /store/order/{orderId} | Find purchase order by ID
+*.StoreApi* | [**placeOrder**](docs/StoreApi.md#placeOrder) | **POST** /store/order | Place an order for a pet
+*.UserApi* | [**createUser**](docs/UserApi.md#createUser) | **POST** /user | Create user
+*.UserApi* | [**createUsersWithArrayInput**](docs/UserApi.md#createUsersWithArrayInput) | **POST** /user/createWithArray | Creates list of users with given input array
+*.UserApi* | [**createUsersWithListInput**](docs/UserApi.md#createUsersWithListInput) | **POST** /user/createWithList | Creates list of users with given input array
+*.UserApi* | [**deleteUser**](docs/UserApi.md#deleteUser) | **DELETE** /user/{username} | Delete user
+*.UserApi* | [**getUserByName**](docs/UserApi.md#getUserByName) | **GET** /user/{username} | Get user by user name
+*.UserApi* | [**loginUser**](docs/UserApi.md#loginUser) | **GET** /user/login | Logs user into the system
+*.UserApi* | [**logoutUser**](docs/UserApi.md#logoutUser) | **GET** /user/logout | Logs out current logged in user session
+*.UserApi* | [**updateUser**](docs/UserApi.md#updateUser) | **PUT** /user/{username} | Updated user
+
+
+## Documentation for Models
+
+ - [Category](docs/Category.md)
+ - [InlineResponse200](docs/InlineResponse200.md)
+ - [Model200Response](docs/Model200Response.md)
+ - [ModelReturn](docs/ModelReturn.md)
+ - [Name](docs/Name.md)
+ - [Order](docs/Order.md)
+ - [Pet](docs/Pet.md)
+ - [SpecialModelName](docs/SpecialModelName.md)
+ - [Tag](docs/Tag.md)
+ - [User](docs/User.md)
+
+
+## Documentation for Authorization
+
+Authentication schemes defined for the API:
+### petstore_auth
+
+- **Type**: OAuth
+- **Flow**: implicit
+- **Authorizatoin URL**: http://petstore.swagger.io/api/oauth/dialog
+- **Scopes**:
+ - write:pets: modify pets in your account
+ - read:pets: read your pets
+
+### test_api_client_id
+
+- **Type**: API key
+- **API key parameter name**: x-test_api_client_id
+- **Location**: HTTP header
+
+### test_api_client_secret
+
+- **Type**: API key
+- **API key parameter name**: x-test_api_client_secret
+- **Location**: HTTP header
+
+### api_key
+
+- **Type**: API key
+- **API key parameter name**: api_key
+- **Location**: HTTP header
+
+### test_http_basic
+
+- **Type**: HTTP basic authentication
+
+### test_api_key_query
+
+- **Type**: API key
+- **API key parameter name**: test_api_key_query
+- **Location**: URL query string
+
+### test_api_key_header
+
+- **Type**: API key
+- **API key parameter name**: test_api_key_header
+- **Location**: HTTP header
+
+
## Recommendation
It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issue.
@@ -40,4 +164,3 @@ It's recommended to create an instance of `ApiClient` per thread in a multithrea
apiteam@swagger.io
-
diff --git a/samples/client/petstore/java/default/docs/Category.md b/samples/client/petstore/java/default/docs/Category.md
new file mode 100644
index 000000000000..3a0290a90bcb
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Category.md
@@ -0,0 +1,9 @@
+# Category
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**id** | **Long** | | [optional]
+**name** | **String** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/InlineResponse200.md b/samples/client/petstore/java/default/docs/InlineResponse200.md
new file mode 100644
index 000000000000..232cb0ed5c11
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/InlineResponse200.md
@@ -0,0 +1,13 @@
+# InlineResponse200
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**photoUrls** | **List<String>** | | [optional]
+**name** | **String** | | [optional]
+**id** | **Long** | |
+**category** | **Object** | | [optional]
+**tags** | [**List<Tag>**](Tag.md) | | [optional]
+**status** | **String** | pet status in the store | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/Model200Response.md b/samples/client/petstore/java/default/docs/Model200Response.md
new file mode 100644
index 000000000000..f4dbac7897ff
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Model200Response.md
@@ -0,0 +1,8 @@
+# Model200Response
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **Integer** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/ModelReturn.md b/samples/client/petstore/java/default/docs/ModelReturn.md
new file mode 100644
index 000000000000..fbeb9eefde6f
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/ModelReturn.md
@@ -0,0 +1,8 @@
+# ModelReturn
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**_return** | **Integer** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/Name.md b/samples/client/petstore/java/default/docs/Name.md
new file mode 100644
index 000000000000..3cecd0c7b74d
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Name.md
@@ -0,0 +1,9 @@
+# Name
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **Integer** | | [optional]
+**snakeCase** | **Integer** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/Order.md b/samples/client/petstore/java/default/docs/Order.md
new file mode 100644
index 000000000000..07703353044a
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Order.md
@@ -0,0 +1,13 @@
+# Order
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**id** | **Long** | | [optional]
+**petId** | **Long** | | [optional]
+**quantity** | **Integer** | | [optional]
+**shipDate** | [**Date**](Date.md) | | [optional]
+**status** | **String** | Order Status | [optional]
+**complete** | **Boolean** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/Pet.md b/samples/client/petstore/java/default/docs/Pet.md
new file mode 100644
index 000000000000..4676687984e9
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Pet.md
@@ -0,0 +1,13 @@
+# Pet
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**id** | **Long** | | [optional]
+**category** | [**Category**](Category.md) | | [optional]
+**name** | **String** | |
+**photoUrls** | **List<String>** | |
+**tags** | [**List<Tag>**](Tag.md) | | [optional]
+**status** | **String** | pet status in the store | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/PetApi.md b/samples/client/petstore/java/default/docs/PetApi.md
new file mode 100644
index 000000000000..1c97c809ca0b
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/PetApi.md
@@ -0,0 +1,624 @@
+# PetApi
+
+All URIs are relative to *http://petstore.swagger.io/v2*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**addPet**](PetApi.md#addPet) | **POST** /pet | Add a new pet to the store
+[**addPetUsingByteArray**](PetApi.md#addPetUsingByteArray) | **POST** /pet?testing_byte_array=true | Fake endpoint to test byte array in body parameter for adding a new pet to the store
+[**deletePet**](PetApi.md#deletePet) | **DELETE** /pet/{petId} | Deletes a pet
+[**findPetsByStatus**](PetApi.md#findPetsByStatus) | **GET** /pet/findByStatus | Finds Pets by status
+[**findPetsByTags**](PetApi.md#findPetsByTags) | **GET** /pet/findByTags | Finds Pets by tags
+[**getPetById**](PetApi.md#getPetById) | **GET** /pet/{petId} | Find pet by ID
+[**getPetByIdInObject**](PetApi.md#getPetByIdInObject) | **GET** /pet/{petId}?response=inline_arbitrary_object | Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
+[**petPetIdtestingByteArraytrueGet**](PetApi.md#petPetIdtestingByteArraytrueGet) | **GET** /pet/{petId}?testing_byte_array=true | Fake endpoint to test byte array return by 'Find pet by ID'
+[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
+[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
+[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
+
+
+
+# **addPet**
+> addPet(body)
+
+Add a new pet to the store
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
+try {
+ apiInstance.addPet(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#addPet");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: application/json, application/xml
+ - **Accept**: application/json, application/xml
+
+
+# **addPetUsingByteArray**
+> addPetUsingByteArray(body)
+
+Fake endpoint to test byte array in body parameter for adding a new pet to the store
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+byte[] body = BINARY_DATA_HERE; // byte[] | Pet object in the form of byte array
+try {
+ apiInstance.addPetUsingByteArray(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#addPetUsingByteArray");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | **byte[]**| Pet object in the form of byte array | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: application/json, application/xml
+ - **Accept**: application/json, application/xml
+
+
+# **deletePet**
+> deletePet(petId, apiKey)
+
+Deletes a pet
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+Long petId = 789L; // Long | Pet id to delete
+String apiKey = "apiKey_example"; // String |
+try {
+ apiInstance.deletePet(petId, apiKey);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#deletePet");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **Long**| Pet id to delete |
+ **apiKey** | **String**| | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **findPetsByStatus**
+> List<Pet> findPetsByStatus(status)
+
+Finds Pets by status
+
+Multiple status values can be provided with comma separated strings
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+List status = Arrays.asList("available"); // List | Status values that need to be considered for query
+try {
+ List result = apiInstance.findPetsByStatus(status);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#findPetsByStatus");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **status** | [**List<String>**](String.md)| Status values that need to be considered for query | [optional] [default to available]
+
+### Return type
+
+[**List<Pet>**](Pet.md)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **findPetsByTags**
+> List<Pet> findPetsByTags(tags)
+
+Finds Pets by tags
+
+Muliple tags can be provided with comma seperated strings. Use tag1, tag2, tag3 for testing.
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+List tags = Arrays.asList("tags_example"); // List | Tags to filter by
+try {
+ List result = apiInstance.findPetsByTags(tags);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#findPetsByTags");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **tags** | [**List<String>**](String.md)| Tags to filter by | [optional]
+
+### Return type
+
+[**List<Pet>**](Pet.md)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getPetById**
+> Pet getPetById(petId)
+
+Find pet by ID
+
+Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+// Configure API key authorization: api_key
+ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
+api_key.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//api_key.setApiKeyPrefix("Token");
+
+PetApi apiInstance = new PetApi();
+Long petId = 789L; // Long | ID of pet that needs to be fetched
+try {
+ Pet result = apiInstance.getPetById(petId);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#getPetById");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **Long**| ID of pet that needs to be fetched |
+
+### Return type
+
+[**Pet**](Pet.md)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth), [api_key](../README.md#api_key)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getPetByIdInObject**
+> InlineResponse200 getPetByIdInObject(petId)
+
+Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
+
+Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+// Configure API key authorization: api_key
+ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
+api_key.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//api_key.setApiKeyPrefix("Token");
+
+PetApi apiInstance = new PetApi();
+Long petId = 789L; // Long | ID of pet that needs to be fetched
+try {
+ InlineResponse200 result = apiInstance.getPetByIdInObject(petId);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#getPetByIdInObject");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **Long**| ID of pet that needs to be fetched |
+
+### Return type
+
+[**InlineResponse200**](InlineResponse200.md)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth), [api_key](../README.md#api_key)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **petPetIdtestingByteArraytrueGet**
+> byte[] petPetIdtestingByteArraytrueGet(petId)
+
+Fake endpoint to test byte array return by 'Find pet by ID'
+
+Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+// Configure API key authorization: api_key
+ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
+api_key.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//api_key.setApiKeyPrefix("Token");
+
+PetApi apiInstance = new PetApi();
+Long petId = 789L; // Long | ID of pet that needs to be fetched
+try {
+ byte[] result = apiInstance.petPetIdtestingByteArraytrueGet(petId);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#petPetIdtestingByteArraytrueGet");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **Long**| ID of pet that needs to be fetched |
+
+### Return type
+
+**byte[]**
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth), [api_key](../README.md#api_key)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **updatePet**
+> updatePet(body)
+
+Update an existing pet
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+Pet body = new Pet(); // Pet | Pet object that needs to be added to the store
+try {
+ apiInstance.updatePet(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#updatePet");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: application/json, application/xml
+ - **Accept**: application/json, application/xml
+
+
+# **updatePetWithForm**
+> updatePetWithForm(petId, name, status)
+
+Updates a pet in the store with form data
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+String petId = "petId_example"; // String | ID of pet that needs to be updated
+String name = "name_example"; // String | Updated name of the pet
+String status = "status_example"; // String | Updated status of the pet
+try {
+ apiInstance.updatePetWithForm(petId, name, status);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#updatePetWithForm");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **String**| ID of pet that needs to be updated |
+ **name** | **String**| Updated name of the pet | [optional]
+ **status** | **String**| Updated status of the pet | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: application/x-www-form-urlencoded
+ - **Accept**: application/json, application/xml
+
+
+# **uploadFile**
+> uploadFile(petId, additionalMetadata, file)
+
+uploads an image
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.PetApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure OAuth2 access token for authorization: petstore_auth
+OAuth petstore_auth = (OAuth) defaultClient.getAuthentication("petstore_auth");
+petstore_auth.setAccessToken("YOUR ACCESS TOKEN");
+
+PetApi apiInstance = new PetApi();
+Long petId = 789L; // Long | ID of pet to update
+String additionalMetadata = "additionalMetadata_example"; // String | Additional data to pass to server
+File file = new File("/path/to/file.txt"); // File | file to upload
+try {
+ apiInstance.uploadFile(petId, additionalMetadata, file);
+} catch (ApiException e) {
+ System.err.println("Exception when calling PetApi#uploadFile");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **petId** | **Long**| ID of pet to update |
+ **additionalMetadata** | **String**| Additional data to pass to server | [optional]
+ **file** | **File**| file to upload | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[petstore_auth](../README.md#petstore_auth)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: application/json, application/xml
+
diff --git a/samples/client/petstore/java/default/docs/SpecialModelName.md b/samples/client/petstore/java/default/docs/SpecialModelName.md
new file mode 100644
index 000000000000..e8ebae01a3ba
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/SpecialModelName.md
@@ -0,0 +1,8 @@
+# SpecialModelName
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**specialPropertyName** | **Long** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/StoreApi.md b/samples/client/petstore/java/default/docs/StoreApi.md
new file mode 100644
index 000000000000..544081e5d681
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/StoreApi.md
@@ -0,0 +1,343 @@
+# StoreApi
+
+All URIs are relative to *http://petstore.swagger.io/v2*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**deleteOrder**](StoreApi.md#deleteOrder) | **DELETE** /store/order/{orderId} | Delete purchase order by ID
+[**findOrdersByStatus**](StoreApi.md#findOrdersByStatus) | **GET** /store/findByStatus | Finds orders by status
+[**getInventory**](StoreApi.md#getInventory) | **GET** /store/inventory | Returns pet inventories by status
+[**getInventoryInObject**](StoreApi.md#getInventoryInObject) | **GET** /store/inventory?response=arbitrary_object | Fake endpoint to test arbitrary object return by 'Get inventory'
+[**getOrderById**](StoreApi.md#getOrderById) | **GET** /store/order/{orderId} | Find purchase order by ID
+[**placeOrder**](StoreApi.md#placeOrder) | **POST** /store/order | Place an order for a pet
+
+
+
+# **deleteOrder**
+> deleteOrder(orderId)
+
+Delete purchase order by ID
+
+For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.StoreApi;
+
+
+StoreApi apiInstance = new StoreApi();
+String orderId = "orderId_example"; // String | ID of the order that needs to be deleted
+try {
+ apiInstance.deleteOrder(orderId);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#deleteOrder");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **orderId** | **String**| ID of the order that needs to be deleted |
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **findOrdersByStatus**
+> List<Order> findOrdersByStatus(status)
+
+Finds orders by status
+
+A single status value can be provided as a string
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.StoreApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: test_api_client_id
+ApiKeyAuth test_api_client_id = (ApiKeyAuth) defaultClient.getAuthentication("test_api_client_id");
+test_api_client_id.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_client_id.setApiKeyPrefix("Token");
+
+// Configure API key authorization: test_api_client_secret
+ApiKeyAuth test_api_client_secret = (ApiKeyAuth) defaultClient.getAuthentication("test_api_client_secret");
+test_api_client_secret.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_client_secret.setApiKeyPrefix("Token");
+
+StoreApi apiInstance = new StoreApi();
+String status = "placed"; // String | Status value that needs to be considered for query
+try {
+ List result = apiInstance.findOrdersByStatus(status);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#findOrdersByStatus");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **status** | **String**| Status value that needs to be considered for query | [optional] [default to placed]
+
+### Return type
+
+[**List<Order>**](Order.md)
+
+### Authorization
+
+[test_api_client_id](../README.md#test_api_client_id), [test_api_client_secret](../README.md#test_api_client_secret)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getInventory**
+> Map<String, Integer> getInventory()
+
+Returns pet inventories by status
+
+Returns a map of status codes to quantities
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.StoreApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: api_key
+ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
+api_key.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//api_key.setApiKeyPrefix("Token");
+
+StoreApi apiInstance = new StoreApi();
+try {
+ Map result = apiInstance.getInventory();
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#getInventory");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+This endpoint does not need any parameter.
+
+### Return type
+
+[**Map<String, Integer>**](Map.md)
+
+### Authorization
+
+[api_key](../README.md#api_key)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getInventoryInObject**
+> Object getInventoryInObject()
+
+Fake endpoint to test arbitrary object return by 'Get inventory'
+
+Returns an arbitrary object which is actually a map of status codes to quantities
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.StoreApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: api_key
+ApiKeyAuth api_key = (ApiKeyAuth) defaultClient.getAuthentication("api_key");
+api_key.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//api_key.setApiKeyPrefix("Token");
+
+StoreApi apiInstance = new StoreApi();
+try {
+ Object result = apiInstance.getInventoryInObject();
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#getInventoryInObject");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+This endpoint does not need any parameter.
+
+### Return type
+
+**Object**
+
+### Authorization
+
+[api_key](../README.md#api_key)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getOrderById**
+> Order getOrderById(orderId)
+
+Find purchase order by ID
+
+For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.StoreApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: test_api_key_query
+ApiKeyAuth test_api_key_query = (ApiKeyAuth) defaultClient.getAuthentication("test_api_key_query");
+test_api_key_query.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_key_query.setApiKeyPrefix("Token");
+
+// Configure API key authorization: test_api_key_header
+ApiKeyAuth test_api_key_header = (ApiKeyAuth) defaultClient.getAuthentication("test_api_key_header");
+test_api_key_header.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_key_header.setApiKeyPrefix("Token");
+
+StoreApi apiInstance = new StoreApi();
+String orderId = "orderId_example"; // String | ID of pet that needs to be fetched
+try {
+ Order result = apiInstance.getOrderById(orderId);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#getOrderById");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **orderId** | **String**| ID of pet that needs to be fetched |
+
+### Return type
+
+[**Order**](Order.md)
+
+### Authorization
+
+[test_api_key_query](../README.md#test_api_key_query), [test_api_key_header](../README.md#test_api_key_header)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **placeOrder**
+> Order placeOrder(body)
+
+Place an order for a pet
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.StoreApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: test_api_client_id
+ApiKeyAuth test_api_client_id = (ApiKeyAuth) defaultClient.getAuthentication("test_api_client_id");
+test_api_client_id.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_client_id.setApiKeyPrefix("Token");
+
+// Configure API key authorization: test_api_client_secret
+ApiKeyAuth test_api_client_secret = (ApiKeyAuth) defaultClient.getAuthentication("test_api_client_secret");
+test_api_client_secret.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//test_api_client_secret.setApiKeyPrefix("Token");
+
+StoreApi apiInstance = new StoreApi();
+Order body = new Order(); // Order | order placed for purchasing the pet
+try {
+ Order result = apiInstance.placeOrder(body);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling StoreApi#placeOrder");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**Order**](Order.md)| order placed for purchasing the pet | [optional]
+
+### Return type
+
+[**Order**](Order.md)
+
+### Authorization
+
+[test_api_client_id](../README.md#test_api_client_id), [test_api_client_secret](../README.md#test_api_client_secret)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
diff --git a/samples/client/petstore/java/default/docs/Tag.md b/samples/client/petstore/java/default/docs/Tag.md
new file mode 100644
index 000000000000..cd4df387983d
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/Tag.md
@@ -0,0 +1,9 @@
+# Tag
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**id** | **Long** | | [optional]
+**name** | **String** | | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/User.md b/samples/client/petstore/java/default/docs/User.md
new file mode 100644
index 000000000000..b948c270267b
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/User.md
@@ -0,0 +1,15 @@
+# User
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**id** | **Long** | | [optional]
+**username** | **String** | | [optional]
+**firstName** | **String** | | [optional]
+**lastName** | **String** | | [optional]
+**email** | **String** | | [optional]
+**password** | **String** | | [optional]
+**phone** | **String** | | [optional]
+**userStatus** | **Integer** | User Status | [optional]
+
+
diff --git a/samples/client/petstore/java/default/docs/UserApi.md b/samples/client/petstore/java/default/docs/UserApi.md
new file mode 100644
index 000000000000..571d547a0796
--- /dev/null
+++ b/samples/client/petstore/java/default/docs/UserApi.md
@@ -0,0 +1,379 @@
+# UserApi
+
+All URIs are relative to *http://petstore.swagger.io/v2*
+
+Method | HTTP request | Description
+------------- | ------------- | -------------
+[**createUser**](UserApi.md#createUser) | **POST** /user | Create user
+[**createUsersWithArrayInput**](UserApi.md#createUsersWithArrayInput) | **POST** /user/createWithArray | Creates list of users with given input array
+[**createUsersWithListInput**](UserApi.md#createUsersWithListInput) | **POST** /user/createWithList | Creates list of users with given input array
+[**deleteUser**](UserApi.md#deleteUser) | **DELETE** /user/{username} | Delete user
+[**getUserByName**](UserApi.md#getUserByName) | **GET** /user/{username} | Get user by user name
+[**loginUser**](UserApi.md#loginUser) | **GET** /user/login | Logs user into the system
+[**logoutUser**](UserApi.md#logoutUser) | **GET** /user/logout | Logs out current logged in user session
+[**updateUser**](UserApi.md#updateUser) | **PUT** /user/{username} | Updated user
+
+
+
+# **createUser**
+> createUser(body)
+
+Create user
+
+This can only be done by the logged in user.
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+User body = new User(); // User | Created user object
+try {
+ apiInstance.createUser(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#createUser");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**User**](User.md)| Created user object | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **createUsersWithArrayInput**
+> createUsersWithArrayInput(body)
+
+Creates list of users with given input array
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+List body = Arrays.asList(new User()); // List | List of user object
+try {
+ apiInstance.createUsersWithArrayInput(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#createUsersWithArrayInput");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**List<User>**](User.md)| List of user object | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **createUsersWithListInput**
+> createUsersWithListInput(body)
+
+Creates list of users with given input array
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+List body = Arrays.asList(new User()); // List | List of user object
+try {
+ apiInstance.createUsersWithListInput(body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#createUsersWithListInput");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **body** | [**List<User>**](User.md)| List of user object | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **deleteUser**
+> deleteUser(username)
+
+Delete user
+
+This can only be done by the logged in user.
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiClient;
+//import io.swagger.client.ApiException;
+//import io.swagger.client.Configuration;
+//import io.swagger.client.auth.*;
+//import io.swagger.client.api.UserApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure HTTP basic authorization: test_http_basic
+HttpBasicAuth test_http_basic = (HttpBasicAuth) defaultClient.getAuthentication("test_http_basic");
+test_http_basic.setUsername("YOUR USERNAME");
+test_http_basic.setPassword("YOUR PASSWORD");
+
+UserApi apiInstance = new UserApi();
+String username = "username_example"; // String | The name that needs to be deleted
+try {
+ apiInstance.deleteUser(username);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#deleteUser");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **username** | **String**| The name that needs to be deleted |
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+[test_http_basic](../README.md#test_http_basic)
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **getUserByName**
+> User getUserByName(username)
+
+Get user by user name
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+String username = "username_example"; // String | The name that needs to be fetched. Use user1 for testing.
+try {
+ User result = apiInstance.getUserByName(username);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#getUserByName");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **username** | **String**| The name that needs to be fetched. Use user1 for testing. |
+
+### Return type
+
+[**User**](User.md)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **loginUser**
+> String loginUser(username, password)
+
+Logs user into the system
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+String username = "username_example"; // String | The user name for login
+String password = "password_example"; // String | The password for login in clear text
+try {
+ String result = apiInstance.loginUser(username, password);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#loginUser");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **username** | **String**| The user name for login | [optional]
+ **password** | **String**| The password for login in clear text | [optional]
+
+### Return type
+
+**String**
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **logoutUser**
+> logoutUser()
+
+Logs out current logged in user session
+
+
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+try {
+ apiInstance.logoutUser();
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#logoutUser");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+This endpoint does not need any parameter.
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
+
+# **updateUser**
+> updateUser(username, body)
+
+Updated user
+
+This can only be done by the logged in user.
+
+### Example
+```java
+// Import classes:
+//import io.swagger.client.ApiException;
+//import io.swagger.client.api.UserApi;
+
+
+UserApi apiInstance = new UserApi();
+String username = "username_example"; // String | name that need to be deleted
+User body = new User(); // User | Updated user object
+try {
+ apiInstance.updateUser(username, body);
+} catch (ApiException e) {
+ System.err.println("Exception when calling UserApi#updateUser");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **username** | **String**| name that need to be deleted |
+ **body** | [**User**](User.md)| Updated user object | [optional]
+
+### Return type
+
+null (empty response body)
+
+### Authorization
+
+No authorization required
+
+### HTTP reuqest headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json, application/xml
+
diff --git a/samples/client/petstore/java/default/pom.xml b/samples/client/petstore/java/default/pom.xml
index e35e30af5833..ae4842838b29 100644
--- a/samples/client/petstore/java/default/pom.xml
+++ b/samples/client/petstore/java/default/pom.xml
@@ -64,6 +64,7 @@
org.codehaus.mojo
build-helper-maven-plugin
+ 1.10
add_sources
@@ -141,7 +142,7 @@
com.fasterxml.jackson.jaxrs
jackson-jaxrs-json-provider
${jackson-version}
-
+
com.fasterxml.jackson.datatype
jackson-datatype-joda
@@ -169,6 +170,7 @@
+ UTF-8
1.5.4
1.18
2.4.2
diff --git a/samples/client/petstore/java/feign/README.md b/samples/client/petstore/java/feign/README.md
index 3ca7abfb5573..d5d447e2865d 100644
--- a/samples/client/petstore/java/feign/README.md
+++ b/samples/client/petstore/java/feign/README.md
@@ -20,7 +20,7 @@ mvn deploy
Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
-After the client libarary is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
```xml
diff --git a/samples/client/petstore/java/jersey2/src/main/java/io/swagger/client/model/Name.java b/samples/client/petstore/java/jersey2/src/main/java/io/swagger/client/model/Name.java
index fc0985915ce0..7bd671af96f1 100644
--- a/samples/client/petstore/java/jersey2/src/main/java/io/swagger/client/model/Name.java
+++ b/samples/client/petstore/java/jersey2/src/main/java/io/swagger/client/model/Name.java
@@ -9,10 +9,11 @@ import io.swagger.annotations.ApiModelProperty;
-@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-17T16:00:50.657+08:00")
+@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-23T19:44:38.177+08:00")
public class Name {
private Integer name = null;
+ private Integer snakeCase = null;
/**
@@ -32,6 +33,23 @@ public class Name {
}
+ /**
+ **/
+ public Name snakeCase(Integer snakeCase) {
+ this.snakeCase = snakeCase;
+ return this;
+ }
+
+ @ApiModelProperty(example = "null", value = "")
+ @JsonProperty("snake_case")
+ public Integer getSnakeCase() {
+ return snakeCase;
+ }
+ public void setSnakeCase(Integer snakeCase) {
+ this.snakeCase = snakeCase;
+ }
+
+
@Override
public boolean equals(java.lang.Object o) {
@@ -42,12 +60,13 @@ public class Name {
return false;
}
Name name = (Name) o;
- return Objects.equals(this.name, name.name);
+ return Objects.equals(this.name, name.name) &&
+ Objects.equals(this.snakeCase, name.snakeCase);
}
@Override
public int hashCode() {
- return Objects.hash(name);
+ return Objects.hash(name, snakeCase);
}
@Override
@@ -56,6 +75,7 @@ public class Name {
sb.append("class Name {\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
+ sb.append(" snakeCase: ").append(toIndentedString(snakeCase)).append("\n");
sb.append("}");
return sb.toString();
}
diff --git a/samples/client/petstore/java/okhttp-gson/pom.xml b/samples/client/petstore/java/okhttp-gson/pom.xml
index 0e9dbe72685f..b76a5fec3837 100644
--- a/samples/client/petstore/java/okhttp-gson/pom.xml
+++ b/samples/client/petstore/java/okhttp-gson/pom.xml
@@ -104,6 +104,7 @@
1.6
+
org.codehaus.mojo
exec-maven-plugin
@@ -124,6 +125,7 @@
+
diff --git a/samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/model/Name.java b/samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/model/Name.java
index a65b8fda6148..c0d5e9474026 100644
--- a/samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/model/Name.java
+++ b/samples/client/petstore/java/okhttp-gson/src/main/java/io/swagger/client/model/Name.java
@@ -15,6 +15,9 @@ public class Name {
@SerializedName("name")
private Integer name = null;
+ @SerializedName("snake_case")
+ private Integer snakeCase = null;
+
/**
@@ -28,6 +31,17 @@ public class Name {
}
+ /**
+ **/
+ @ApiModelProperty(value = "")
+ public Integer getSnakeCase() {
+ return snakeCase;
+ }
+ public void setSnakeCase(Integer snakeCase) {
+ this.snakeCase = snakeCase;
+ }
+
+
@Override
public boolean equals(Object o) {
@@ -38,12 +52,13 @@ public class Name {
return false;
}
Name name = (Name) o;
- return Objects.equals(this.name, name.name);
+ return Objects.equals(this.name, name.name) &&
+ Objects.equals(this.snakeCase, name.snakeCase);
}
@Override
public int hashCode() {
- return Objects.hash(name);
+ return Objects.hash(name, snakeCase);
}
@Override
@@ -52,6 +67,7 @@ public class Name {
sb.append("class Name {\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
+ sb.append(" snakeCase: ").append(toIndentedString(snakeCase)).append("\n");
sb.append("}");
return sb.toString();
}
diff --git a/samples/client/petstore/java/retrofit/README.md b/samples/client/petstore/java/retrofit/README.md
index b687b09ab262..93488cf4e5cf 100644
--- a/samples/client/petstore/java/retrofit/README.md
+++ b/samples/client/petstore/java/retrofit/README.md
@@ -20,7 +20,7 @@ mvn deploy
Refer to the [official documentation](https://maven.apache.org/plugins/maven-deploy-plugin/usage.html) for more information.
-After the client libarary is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
+After the client library is installed/deployed, you can use it in your Maven project by adding the following to your *pom.xml*:
```xml
diff --git a/samples/client/petstore/java/retrofit/build.gradle b/samples/client/petstore/java/retrofit/build.gradle
index 255a76e0403c..44fc45446c84 100644
--- a/samples/client/petstore/java/retrofit/build.gradle
+++ b/samples/client/petstore/java/retrofit/build.gradle
@@ -1,3 +1,6 @@
+apply plugin: 'idea'
+apply plugin: 'eclipse'
+
group = 'io.swagger'
version = '1.0.0'
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/ApiClient.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/ApiClient.java
index ed1ff85acabc..f1ce26ed0922 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/ApiClient.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/ApiClient.java
@@ -47,10 +47,20 @@ public class ApiClient {
this();
for(String authName : authNames) {
Interceptor auth;
- if (authName == "api_key") {
- auth = new ApiKeyAuth("header", "api_key");
- } else if (authName == "petstore_auth") {
+ if (authName == "petstore_auth") {
auth = new OAuth(OAuthFlow.implicit, "http://petstore.swagger.io/api/oauth/dialog", "", "write:pets, read:pets");
+ } else if (authName == "test_api_client_id") {
+ auth = new ApiKeyAuth("header", "x-test_api_client_id");
+ } else if (authName == "test_api_client_secret") {
+ auth = new ApiKeyAuth("header", "x-test_api_client_secret");
+ } else if (authName == "api_key") {
+ auth = new ApiKeyAuth("header", "api_key");
+ } else if (authName == "test_http_basic") {
+ auth = new HttpBasicAuth();
+ } else if (authName == "test_api_key_query") {
+ auth = new ApiKeyAuth("query", "test_api_key_query");
+ } else if (authName == "test_api_key_header") {
+ auth = new ApiKeyAuth("header", "test_api_key_header");
} else {
throw new RuntimeException("auth name \"" + authName + "\" not found in available auth names");
}
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/StringUtil.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/StringUtil.java
index 0eec085e2a49..b02959b4f8d5 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/StringUtil.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/StringUtil.java
@@ -1,6 +1,6 @@
package io.swagger.client;
-@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-14T22:17:53.252+08:00")
+@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-23T19:51:05.606+08:00")
public class StringUtil {
/**
* Check if the given array contains the given value (with case-insensitive comparison).
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/PetApi.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/PetApi.java
index 92147932bace..e1d21e334d6d 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/PetApi.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/PetApi.java
@@ -10,15 +10,11 @@ import io.swagger.client.model.Pet;
import io.swagger.client.model.InlineResponse200;
import java.io.File;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface PetApi {
/**
@@ -322,4 +318,3 @@ public interface PetApi {
);
}
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/StoreApi.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/StoreApi.java
index 815d067c9674..77d4c610214e 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/StoreApi.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/StoreApi.java
@@ -8,15 +8,11 @@ import retrofit.mime.*;
import io.swagger.client.model.Order;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface StoreApi {
/**
@@ -170,4 +166,3 @@ public interface StoreApi {
);
}
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/UserApi.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/UserApi.java
index a0d913e071f9..1d49e69b3612 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/UserApi.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/api/UserApi.java
@@ -8,15 +8,11 @@ import retrofit.mime.*;
import io.swagger.client.model.User;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface UserApi {
/**
@@ -229,4 +225,3 @@ public interface UserApi {
);
}
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Category.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Category.java
index 67de63eb1792..a11289078d48 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Category.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Category.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Category {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Category {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/InlineResponse200.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/InlineResponse200.java
index 165f069a05b9..9f28d0298338 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/InlineResponse200.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/InlineResponse200.java
@@ -7,14 +7,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class InlineResponse200 {
@SerializedName("photoUrls")
@@ -176,5 +174,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Model200Response.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Model200Response.java
index 80b0aed92a8a..b6cefee347fe 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Model200Response.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Model200Response.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Model200Response {
@SerializedName("name")
@@ -69,5 +67,3 @@ public class Model200Response {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/ModelReturn.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/ModelReturn.java
index ce8c1238fdb5..8146433d0c37 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/ModelReturn.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/ModelReturn.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class ModelReturn {
@SerializedName("return")
@@ -69,5 +67,3 @@ public class ModelReturn {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Name.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Name.java
index 370214bd21c6..c8b00ba1f736 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Name.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Name.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Name {
@SerializedName("name")
@@ -85,5 +83,3 @@ public class Name {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Order.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Order.java
index e601bd7a15a0..fdb19fd179e7 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Order.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Order.java
@@ -5,14 +5,12 @@ import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
-
import com.google.gson.annotations.SerializedName;
-
public class Order {
@SerializedName("id")
@@ -171,5 +169,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Pet.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Pet.java
index 5d1210dc55b5..63e95cf1ac08 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Pet.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Pet.java
@@ -8,14 +8,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class Pet {
@SerializedName("id")
@@ -177,5 +175,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/SpecialModelName.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/SpecialModelName.java
index b5a96d5fc398..e3c40dfc3176 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/SpecialModelName.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/SpecialModelName.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class SpecialModelName {
@SerializedName("$special[property.name]")
@@ -69,5 +67,3 @@ public class SpecialModelName {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Tag.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Tag.java
index 6ee49ee21660..ec01203c6cf8 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Tag.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/Tag.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Tag {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Tag {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/User.java b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/User.java
index 98196393ef11..7060e22b095d 100644
--- a/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/User.java
+++ b/samples/client/petstore/java/retrofit/src/main/java/io/swagger/client/model/User.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class User {
@SerializedName("id")
@@ -182,5 +180,3 @@ public class User {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/ApiClient.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/ApiClient.java
index ffff8c26d4fc..4f7a6d82e76e 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/ApiClient.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/ApiClient.java
@@ -55,6 +55,8 @@ public class ApiClient {
auth = new ApiKeyAuth("header", "x-test_api_client_secret");
} else if (authName == "api_key") {
auth = new ApiKeyAuth("header", "api_key");
+ } else if (authName == "test_http_basic") {
+ auth = new HttpBasicAuth();
} else if (authName == "test_api_key_query") {
auth = new ApiKeyAuth("query", "test_api_key_query");
} else if (authName == "test_api_key_header") {
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/StringUtil.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/StringUtil.java
index d7254df29fc2..f305321f65bf 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/StringUtil.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/StringUtil.java
@@ -1,6 +1,6 @@
package io.swagger.client;
-@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-14T22:17:54.660+08:00")
+@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-23T19:52:35.278+08:00")
public class StringUtil {
/**
* Check if the given array contains the given value (with case-insensitive comparison).
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/PetApi.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/PetApi.java
index 2cc69238a6b2..b697487f33a4 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/PetApi.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/PetApi.java
@@ -12,15 +12,11 @@ import io.swagger.client.model.Pet;
import io.swagger.client.model.InlineResponse200;
import java.io.File;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface PetApi {
/**
@@ -174,4 +170,3 @@ public interface PetApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/StoreApi.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/StoreApi.java
index d023308c32e9..0efbdcb2b38d 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/StoreApi.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/StoreApi.java
@@ -10,15 +10,11 @@ import okhttp3.RequestBody;
import io.swagger.client.model.Order;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface StoreApi {
/**
@@ -96,4 +92,3 @@ public interface StoreApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/UserApi.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/UserApi.java
index 08aeb90a5839..ba50738eca14 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/UserApi.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/api/UserApi.java
@@ -10,15 +10,11 @@ import okhttp3.RequestBody;
import io.swagger.client.model.User;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface UserApi {
/**
@@ -126,4 +122,3 @@ public interface UserApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Category.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Category.java
index 67de63eb1792..a11289078d48 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Category.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Category.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Category {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Category {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/InlineResponse200.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/InlineResponse200.java
index 165f069a05b9..9f28d0298338 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/InlineResponse200.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/InlineResponse200.java
@@ -7,14 +7,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class InlineResponse200 {
@SerializedName("photoUrls")
@@ -176,5 +174,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Model200Response.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Model200Response.java
index 80b0aed92a8a..b6cefee347fe 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Model200Response.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Model200Response.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Model200Response {
@SerializedName("name")
@@ -69,5 +67,3 @@ public class Model200Response {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ModelReturn.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ModelReturn.java
index ce8c1238fdb5..8146433d0c37 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ModelReturn.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ModelReturn.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class ModelReturn {
@SerializedName("return")
@@ -69,5 +67,3 @@ public class ModelReturn {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Name.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Name.java
index 370214bd21c6..c8b00ba1f736 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Name.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Name.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Name {
@SerializedName("name")
@@ -85,5 +83,3 @@ public class Name {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ObjectReturn.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ObjectReturn.java
deleted file mode 100644
index 920640ad2cb2..000000000000
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/ObjectReturn.java
+++ /dev/null
@@ -1,69 +0,0 @@
-package io.swagger.client.model;
-
-import java.util.Objects;
-import io.swagger.annotations.ApiModel;
-import io.swagger.annotations.ApiModelProperty;
-
-import com.google.gson.annotations.SerializedName;
-
-
-
-
-@ApiModel(description = "")
-public class ObjectReturn {
-
- @SerializedName("return")
- private Integer _return = null;
-
-
-
- /**
- **/
- @ApiModelProperty(value = "")
- public Integer getReturn() {
- return _return;
- }
- public void setReturn(Integer _return) {
- this._return = _return;
- }
-
-
-
- @Override
- public boolean equals(Object o) {
- if (this == o) {
- return true;
- }
- if (o == null || getClass() != o.getClass()) {
- return false;
- }
- ObjectReturn _return = (ObjectReturn) o;
- return Objects.equals(_return, _return._return);
- }
-
- @Override
- public int hashCode() {
- return Objects.hash(_return);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder();
- sb.append("class ObjectReturn {\n");
-
- sb.append(" _return: ").append(toIndentedString(_return)).append("\n");
- sb.append("}");
- return sb.toString();
- }
-
- /**
- * Convert the given object to string with each line indented by 4 spaces
- * (except the first line).
- */
- private String toIndentedString(Object o) {
- if (o == null) {
- return "null";
- }
- return o.toString().replace("\n", "\n ");
- }
-}
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Order.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Order.java
index e601bd7a15a0..fdb19fd179e7 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Order.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Order.java
@@ -5,14 +5,12 @@ import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
-
import com.google.gson.annotations.SerializedName;
-
public class Order {
@SerializedName("id")
@@ -171,5 +169,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Pet.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Pet.java
index 5d1210dc55b5..63e95cf1ac08 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Pet.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Pet.java
@@ -8,14 +8,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class Pet {
@SerializedName("id")
@@ -177,5 +175,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/SpecialModelName.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/SpecialModelName.java
index b5a96d5fc398..e3c40dfc3176 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/SpecialModelName.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/SpecialModelName.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class SpecialModelName {
@SerializedName("$special[property.name]")
@@ -69,5 +67,3 @@ public class SpecialModelName {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Tag.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Tag.java
index 6ee49ee21660..ec01203c6cf8 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Tag.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/Tag.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Tag {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Tag {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/User.java b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/User.java
index 98196393ef11..7060e22b095d 100644
--- a/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/User.java
+++ b/samples/client/petstore/java/retrofit2/src/main/java/io/swagger/client/model/User.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class User {
@SerializedName("id")
@@ -182,5 +180,3 @@ public class User {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/ApiClient.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/ApiClient.java
index 5582509be76b..a46bc77be92a 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/ApiClient.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/ApiClient.java
@@ -55,6 +55,8 @@ public class ApiClient {
auth = new ApiKeyAuth("header", "x-test_api_client_secret");
} else if (authName == "api_key") {
auth = new ApiKeyAuth("header", "api_key");
+ } else if (authName == "test_http_basic") {
+ auth = new HttpBasicAuth();
} else if (authName == "test_api_key_query") {
auth = new ApiKeyAuth("query", "test_api_key_query");
} else if (authName == "test_api_key_header") {
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/StringUtil.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/StringUtil.java
index e8c0dc4d0620..18ff89e00c26 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/StringUtil.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/StringUtil.java
@@ -1,6 +1,6 @@
package io.swagger.client;
-@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-07T09:11:59.834Z")
+@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-03-23T20:03:43.107+08:00")
public class StringUtil {
/**
* Check if the given array contains the given value (with case-insensitive comparison).
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/PetApi.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/PetApi.java
index 33d4760a6058..280b6d8f5af7 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/PetApi.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/PetApi.java
@@ -12,15 +12,11 @@ import io.swagger.client.model.Pet;
import io.swagger.client.model.InlineResponse200;
import java.io.File;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface PetApi {
/**
@@ -174,4 +170,3 @@ public interface PetApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/StoreApi.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/StoreApi.java
index b4effc010dff..e84e8aba5d84 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/StoreApi.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/StoreApi.java
@@ -10,15 +10,11 @@ import okhttp3.RequestBody;
import io.swagger.client.model.Order;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface StoreApi {
/**
@@ -96,4 +92,3 @@ public interface StoreApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/UserApi.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/UserApi.java
index 6019e10711d7..dac0ee7e1a5e 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/UserApi.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/api/UserApi.java
@@ -10,15 +10,11 @@ import okhttp3.RequestBody;
import io.swagger.client.model.User;
-
-
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-
-
public interface UserApi {
/**
@@ -126,4 +122,3 @@ public interface UserApi {
}
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Category.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Category.java
index 67de63eb1792..a11289078d48 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Category.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Category.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Category {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Category {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/InlineResponse200.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/InlineResponse200.java
index 165f069a05b9..9f28d0298338 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/InlineResponse200.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/InlineResponse200.java
@@ -7,14 +7,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class InlineResponse200 {
@SerializedName("photoUrls")
@@ -176,5 +174,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Model200Response.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Model200Response.java
index 80b0aed92a8a..b6cefee347fe 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Model200Response.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Model200Response.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Model200Response {
@SerializedName("name")
@@ -69,5 +67,3 @@ public class Model200Response {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ModelReturn.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ModelReturn.java
index ce8c1238fdb5..8146433d0c37 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ModelReturn.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ModelReturn.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class ModelReturn {
@SerializedName("return")
@@ -69,5 +67,3 @@ public class ModelReturn {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Name.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Name.java
index 370214bd21c6..c8b00ba1f736 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Name.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Name.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Name {
@SerializedName("name")
@@ -85,5 +83,3 @@ public class Name {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ObjectReturn.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ObjectReturn.java
deleted file mode 100644
index 920640ad2cb2..000000000000
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/ObjectReturn.java
+++ /dev/null
@@ -1,69 +0,0 @@
-package io.swagger.client.model;
-
-import java.util.Objects;
-import io.swagger.annotations.ApiModel;
-import io.swagger.annotations.ApiModelProperty;
-
-import com.google.gson.annotations.SerializedName;
-
-
-
-
-@ApiModel(description = "")
-public class ObjectReturn {
-
- @SerializedName("return")
- private Integer _return = null;
-
-
-
- /**
- **/
- @ApiModelProperty(value = "")
- public Integer getReturn() {
- return _return;
- }
- public void setReturn(Integer _return) {
- this._return = _return;
- }
-
-
-
- @Override
- public boolean equals(Object o) {
- if (this == o) {
- return true;
- }
- if (o == null || getClass() != o.getClass()) {
- return false;
- }
- ObjectReturn _return = (ObjectReturn) o;
- return Objects.equals(_return, _return._return);
- }
-
- @Override
- public int hashCode() {
- return Objects.hash(_return);
- }
-
- @Override
- public String toString() {
- StringBuilder sb = new StringBuilder();
- sb.append("class ObjectReturn {\n");
-
- sb.append(" _return: ").append(toIndentedString(_return)).append("\n");
- sb.append("}");
- return sb.toString();
- }
-
- /**
- * Convert the given object to string with each line indented by 4 spaces
- * (except the first line).
- */
- private String toIndentedString(Object o) {
- if (o == null) {
- return "null";
- }
- return o.toString().replace("\n", "\n ");
- }
-}
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Order.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Order.java
index e601bd7a15a0..fdb19fd179e7 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Order.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Order.java
@@ -5,14 +5,12 @@ import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.Date;
-
import com.google.gson.annotations.SerializedName;
-
public class Order {
@SerializedName("id")
@@ -171,5 +169,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Pet.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Pet.java
index 5d1210dc55b5..63e95cf1ac08 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Pet.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Pet.java
@@ -8,14 +8,12 @@ import io.swagger.client.model.Tag;
import java.util.ArrayList;
import java.util.List;
-
import com.google.gson.annotations.SerializedName;
-
public class Pet {
@SerializedName("id")
@@ -177,5 +175,3 @@ public enum StatusEnum {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/SpecialModelName.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/SpecialModelName.java
index b5a96d5fc398..e3c40dfc3176 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/SpecialModelName.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/SpecialModelName.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class SpecialModelName {
@SerializedName("$special[property.name]")
@@ -69,5 +67,3 @@ public class SpecialModelName {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Tag.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Tag.java
index 6ee49ee21660..ec01203c6cf8 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Tag.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/Tag.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class Tag {
@SerializedName("id")
@@ -85,5 +83,3 @@ public class Tag {
return o.toString().replace("\n", "\n ");
}
}
-
-
diff --git a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/User.java b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/User.java
index 98196393ef11..7060e22b095d 100644
--- a/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/User.java
+++ b/samples/client/petstore/java/retrofit2rx/src/main/java/io/swagger/client/model/User.java
@@ -4,14 +4,12 @@ import java.util.Objects;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
-
import com.google.gson.annotations.SerializedName;
-
public class User {
@SerializedName("id")
@@ -182,5 +180,3 @@ public class User {
return o.toString().replace("\n", "\n ");
}
}
-
-