Fix #6166 by adding @Deprecated annotations in Java jersey2, okhttp-gson, resteasy libraries (#6801)

This commit is contained in:
Brian Kim
2017-10-24 20:10:03 -07:00
committed by wing328
parent ab338f8cb9
commit 044bfdac39
76 changed files with 1577 additions and 465 deletions

View File

@@ -11,6 +11,7 @@ Method | HTTP request | Description
[**testClientModel**](FakeApi.md#testClientModel) | **PATCH** /fake | To test \"client\" model
[**testEndpointParameters**](FakeApi.md#testEndpointParameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
[**testEnumParameters**](FakeApi.md#testEnumParameters) | **GET** /fake | To test enum parameters
[**testInlineAdditionalProperties**](FakeApi.md#testInlineAdditionalProperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties
[**testJsonFormData**](FakeApi.md#testJsonFormData) | **GET** /fake/jsonFormData | test json serialization of form data
@@ -376,6 +377,50 @@ No authorization required
- **Content-Type**: */*
- **Accept**: */*
<a name="testInlineAdditionalProperties"></a>
# **testInlineAdditionalProperties**
> testInlineAdditionalProperties(param)
test inline additionalProperties
### Example
```java
// Import classes:
//import io.swagger.client.ApiException;
//import io.swagger.client.api.FakeApi;
FakeApi apiInstance = new FakeApi();
Object param = null; // Object | request body
try {
apiInstance.testInlineAdditionalProperties(param);
} catch (ApiException e) {
System.err.println("Exception when calling FakeApi#testInlineAdditionalProperties");
e.printStackTrace();
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**param** | **Object**| request body |
### Return type
null (empty response body)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: Not defined
<a name="testJsonFormData"></a>
# **testJsonFormData**
> testJsonFormData(param, param2)

View File

@@ -64,7 +64,7 @@ public class AnotherFakeApi {
*/
public com.squareup.okhttp.Call testSpecialTagsCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/another-fake/dummy";
@@ -102,7 +102,7 @@ public class AnotherFakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testSpecialTagsValidateBeforeCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -111,14 +111,10 @@ public class AnotherFakeApi {
throw new ApiException("Missing the required parameter 'body' when calling testSpecialTags(Async)");
}
com.squareup.okhttp.Call call = testSpecialTagsCall(body, progressListener, progressRequestListener);
return call;
}
/**

View File

@@ -68,7 +68,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call fakeOuterBooleanSerializeCall(Boolean body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake/outer/boolean";
@@ -106,18 +106,14 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call fakeOuterBooleanSerializeValidateBeforeCall(Boolean body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = fakeOuterBooleanSerializeCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -189,7 +185,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call fakeOuterCompositeSerializeCall(OuterComposite body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake/outer/composite";
@@ -227,18 +223,14 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call fakeOuterCompositeSerializeValidateBeforeCall(OuterComposite body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = fakeOuterCompositeSerializeCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -310,7 +302,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call fakeOuterNumberSerializeCall(BigDecimal body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake/outer/number";
@@ -348,18 +340,14 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call fakeOuterNumberSerializeValidateBeforeCall(BigDecimal body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = fakeOuterNumberSerializeCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -431,7 +419,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call fakeOuterStringSerializeCall(String body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake/outer/string";
@@ -469,18 +457,14 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call fakeOuterStringSerializeValidateBeforeCall(String body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = fakeOuterStringSerializeCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -552,7 +536,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call testClientModelCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake";
@@ -590,7 +574,7 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testClientModelValidateBeforeCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -599,14 +583,10 @@ public class FakeApi {
throw new ApiException("Missing the required parameter 'body' when calling testClientModel(Async)");
}
com.squareup.okhttp.Call call = testClientModelCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -691,7 +671,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call testEndpointParametersCall(BigDecimal number, Double _double, String patternWithoutDelimiter, byte[] _byte, Integer integer, Integer int32, Long int64, Float _float, String string, byte[] binary, LocalDate date, OffsetDateTime dateTime, String password, String paramCallback, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/fake";
@@ -757,7 +737,7 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { "http_basic_test" };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testEndpointParametersValidateBeforeCall(BigDecimal number, Double _double, String patternWithoutDelimiter, byte[] _byte, Integer integer, Integer int32, Long int64, Float _float, String string, byte[] binary, LocalDate date, OffsetDateTime dateTime, String password, String paramCallback, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -781,14 +761,10 @@ public class FakeApi {
throw new ApiException("Missing the required parameter '_byte' when calling testEndpointParameters(Async)");
}
com.squareup.okhttp.Call call = testEndpointParametersCall(number, _double, patternWithoutDelimiter, _byte, integer, int32, int64, _float, string, binary, date, dateTime, password, paramCallback, progressListener, progressRequestListener);
return call;
}
/**
@@ -902,7 +878,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call testEnumParametersCall(List<String> enumFormStringArray, String enumFormString, List<String> enumHeaderStringArray, String enumHeaderString, List<String> enumQueryStringArray, String enumQueryString, Integer enumQueryInteger, Double enumQueryDouble, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/fake";
@@ -956,18 +932,14 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testEnumParametersValidateBeforeCall(List<String> enumFormStringArray, String enumFormString, List<String> enumHeaderStringArray, String enumHeaderString, List<String> enumQueryStringArray, String enumQueryString, Integer enumQueryInteger, Double enumQueryDouble, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = testEnumParametersCall(enumFormStringArray, enumFormString, enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, progressListener, progressRequestListener);
return call;
}
/**
@@ -1046,6 +1018,124 @@ public class FakeApi {
apiClient.executeAsync(call, callback);
return call;
}
/**
* Build call for testInlineAdditionalProperties
* @param param request body (required)
* @param progressListener Progress listener
* @param progressRequestListener Progress request listener
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
*/
public com.squareup.okhttp.Call testInlineAdditionalPropertiesCall(Object param, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = param;
// create path and map variables
String localVarPath = "/fake/inline-additionalProperties";
List<Pair> localVarQueryParams = new ArrayList<Pair>();
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
final String[] localVarAccepts = {
};
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
final String[] localVarContentTypes = {
"application/json"
};
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
localVarHeaderParams.put("Content-Type", localVarContentType);
if(progressListener != null) {
apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
@Override
public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
return originalResponse.newBuilder()
.body(new ProgressResponseBody(originalResponse.body(), progressListener))
.build();
}
});
}
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testInlineAdditionalPropertiesValidateBeforeCall(Object param, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
// verify the required parameter 'param' is set
if (param == null) {
throw new ApiException("Missing the required parameter 'param' when calling testInlineAdditionalProperties(Async)");
}
com.squareup.okhttp.Call call = testInlineAdditionalPropertiesCall(param, progressListener, progressRequestListener);
return call;
}
/**
* test inline additionalProperties
*
* @param param request body (required)
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
*/
public void testInlineAdditionalProperties(Object param) throws ApiException {
testInlineAdditionalPropertiesWithHttpInfo(param);
}
/**
* test inline additionalProperties
*
* @param param request body (required)
* @return ApiResponse&lt;Void&gt;
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
*/
public ApiResponse<Void> testInlineAdditionalPropertiesWithHttpInfo(Object param) throws ApiException {
com.squareup.okhttp.Call call = testInlineAdditionalPropertiesValidateBeforeCall(param, null, null);
return apiClient.execute(call);
}
/**
* test inline additionalProperties (asynchronously)
*
* @param param request body (required)
* @param callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
*/
public com.squareup.okhttp.Call testInlineAdditionalPropertiesAsync(Object param, final ApiCallback<Void> callback) throws ApiException {
ProgressResponseBody.ProgressListener progressListener = null;
ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
if (callback != null) {
progressListener = new ProgressResponseBody.ProgressListener() {
@Override
public void update(long bytesRead, long contentLength, boolean done) {
callback.onDownloadProgress(bytesRead, contentLength, done);
}
};
progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
@Override
public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
callback.onUploadProgress(bytesWritten, contentLength, done);
}
};
}
com.squareup.okhttp.Call call = testInlineAdditionalPropertiesValidateBeforeCall(param, progressListener, progressRequestListener);
apiClient.executeAsync(call, callback);
return call;
}
/**
* Build call for testJsonFormData
* @param param field1 (required)
@@ -1057,7 +1147,7 @@ public class FakeApi {
*/
public com.squareup.okhttp.Call testJsonFormDataCall(String param, String param2, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/fake/jsonFormData";
@@ -1099,7 +1189,7 @@ public class FakeApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testJsonFormDataValidateBeforeCall(String param, String param2, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -1113,14 +1203,10 @@ public class FakeApi {
throw new ApiException("Missing the required parameter 'param2' when calling testJsonFormData(Async)");
}
com.squareup.okhttp.Call call = testJsonFormDataCall(param, param2, progressListener, progressRequestListener);
return call;
}
/**

View File

@@ -64,7 +64,7 @@ public class FakeClassnameTags123Api {
*/
public com.squareup.okhttp.Call testClassnameCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/fake_classname_test";
@@ -102,7 +102,7 @@ public class FakeClassnameTags123Api {
String[] localVarAuthNames = new String[] { "api_key_query" };
return apiClient.buildCall(localVarPath, "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call testClassnameValidateBeforeCall(Client body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -111,14 +111,10 @@ public class FakeClassnameTags123Api {
throw new ApiException("Missing the required parameter 'body' when calling testClassname(Async)");
}
com.squareup.okhttp.Call call = testClassnameCall(body, progressListener, progressRequestListener);
return call;
}
/**

View File

@@ -66,7 +66,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call addPetCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/pet";
@@ -104,7 +104,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call addPetValidateBeforeCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -113,14 +113,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'body' when calling addPet(Async)");
}
com.squareup.okhttp.Call call = addPetCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -189,7 +185,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call deletePetCall(Long petId, String apiKey, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/{petId}"
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
@@ -230,7 +226,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call deletePetValidateBeforeCall(Long petId, String apiKey, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -239,14 +235,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'petId' when calling deletePet(Async)");
}
com.squareup.okhttp.Call call = deletePetCall(petId, apiKey, progressListener, progressRequestListener);
return call;
}
/**
@@ -317,7 +309,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call findPetsByStatusCall(List<String> status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/findByStatus";
@@ -357,7 +349,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call findPetsByStatusValidateBeforeCall(List<String> status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -366,14 +358,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'status' when calling findPetsByStatus(Async)");
}
com.squareup.okhttp.Call call = findPetsByStatusCall(status, progressListener, progressRequestListener);
return call;
}
/**
@@ -442,10 +430,12 @@ public class PetApi {
* @param progressRequestListener Progress request listener
* @return Call to execute
* @throws ApiException If fail to serialize the request body object
* @deprecated
*/
@Deprecated
public com.squareup.okhttp.Call findPetsByTagsCall(List<String> tags, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/findByTags";
@@ -485,7 +475,8 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@Deprecated
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call findPetsByTagsValidateBeforeCall(List<String> tags, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -494,14 +485,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'tags' when calling findPetsByTags(Async)");
}
com.squareup.okhttp.Call call = findPetsByTagsCall(tags, progressListener, progressRequestListener);
return call;
}
/**
@@ -510,7 +497,9 @@ public class PetApi {
* @param tags Tags to filter by (required)
* @return List&lt;Pet&gt;
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @deprecated
*/
@Deprecated
public List<Pet> findPetsByTags(List<String> tags) throws ApiException {
ApiResponse<List<Pet>> resp = findPetsByTagsWithHttpInfo(tags);
return resp.getData();
@@ -522,7 +511,9 @@ public class PetApi {
* @param tags Tags to filter by (required)
* @return ApiResponse&lt;List&lt;Pet&gt;&gt;
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
* @deprecated
*/
@Deprecated
public ApiResponse<List<Pet>> findPetsByTagsWithHttpInfo(List<String> tags) throws ApiException {
com.squareup.okhttp.Call call = findPetsByTagsValidateBeforeCall(tags, null, null);
Type localVarReturnType = new TypeToken<List<Pet>>(){}.getType();
@@ -536,7 +527,9 @@ public class PetApi {
* @param callback The callback to be executed when the API call finishes
* @return The request call
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
* @deprecated
*/
@Deprecated
public com.squareup.okhttp.Call findPetsByTagsAsync(List<String> tags, final ApiCallback<List<Pet>> callback) throws ApiException {
ProgressResponseBody.ProgressListener progressListener = null;
@@ -573,7 +566,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call getPetByIdCall(Long petId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/{petId}"
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
@@ -612,7 +605,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "api_key" };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call getPetByIdValidateBeforeCall(Long petId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -621,14 +614,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'petId' when calling getPetById(Async)");
}
com.squareup.okhttp.Call call = getPetByIdCall(petId, progressListener, progressRequestListener);
return call;
}
/**
@@ -700,7 +689,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call updatePetCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/pet";
@@ -738,7 +727,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call updatePetValidateBeforeCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -747,14 +736,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'body' when calling updatePet(Async)");
}
com.squareup.okhttp.Call call = updatePetCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -824,7 +809,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call updatePetWithFormCall(Long petId, String name, String status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/{petId}"
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
@@ -867,7 +852,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call updatePetWithFormValidateBeforeCall(Long petId, String name, String status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -876,14 +861,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'petId' when calling updatePetWithForm(Async)");
}
com.squareup.okhttp.Call call = updatePetWithFormCall(petId, name, status, progressListener, progressRequestListener);
return call;
}
/**
@@ -959,7 +940,7 @@ public class PetApi {
*/
public com.squareup.okhttp.Call uploadFileCall(Long petId, String additionalMetadata, File file, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/pet/{petId}/uploadImage"
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
@@ -1002,7 +983,7 @@ public class PetApi {
String[] localVarAuthNames = new String[] { "petstore_auth" };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call uploadFileValidateBeforeCall(Long petId, String additionalMetadata, File file, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -1011,14 +992,10 @@ public class PetApi {
throw new ApiException("Missing the required parameter 'petId' when calling uploadFile(Async)");
}
com.squareup.okhttp.Call call = uploadFileCall(petId, additionalMetadata, file, progressListener, progressRequestListener);
return call;
}
/**

View File

@@ -64,7 +64,7 @@ public class StoreApi {
*/
public com.squareup.okhttp.Call deleteOrderCall(String orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/store/order/{order_id}"
.replaceAll("\\{" + "order_id" + "\\}", apiClient.escapeString(orderId.toString()));
@@ -103,7 +103,7 @@ public class StoreApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call deleteOrderValidateBeforeCall(String orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -112,14 +112,10 @@ public class StoreApi {
throw new ApiException("Missing the required parameter 'orderId' when calling deleteOrder(Async)");
}
com.squareup.okhttp.Call call = deleteOrderCall(orderId, progressListener, progressRequestListener);
return call;
}
/**
@@ -186,7 +182,7 @@ public class StoreApi {
*/
public com.squareup.okhttp.Call getInventoryCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/store/inventory";
@@ -224,18 +220,14 @@ public class StoreApi {
String[] localVarAuthNames = new String[] { "api_key" };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call getInventoryValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = getInventoryCall(progressListener, progressRequestListener);
return call;
}
/**
@@ -304,7 +296,7 @@ public class StoreApi {
*/
public com.squareup.okhttp.Call getOrderByIdCall(Long orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/store/order/{order_id}"
.replaceAll("\\{" + "order_id" + "\\}", apiClient.escapeString(orderId.toString()));
@@ -343,7 +335,7 @@ public class StoreApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call getOrderByIdValidateBeforeCall(Long orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -352,14 +344,10 @@ public class StoreApi {
throw new ApiException("Missing the required parameter 'orderId' when calling getOrderById(Async)");
}
com.squareup.okhttp.Call call = getOrderByIdCall(orderId, progressListener, progressRequestListener);
return call;
}
/**
@@ -431,7 +419,7 @@ public class StoreApi {
*/
public com.squareup.okhttp.Call placeOrderCall(Order body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/store/order";
@@ -469,7 +457,7 @@ public class StoreApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call placeOrderValidateBeforeCall(Order body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -478,14 +466,10 @@ public class StoreApi {
throw new ApiException("Missing the required parameter 'body' when calling placeOrder(Async)");
}
com.squareup.okhttp.Call call = placeOrderCall(body, progressListener, progressRequestListener);
return call;
}
/**

View File

@@ -64,7 +64,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call createUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/user";
@@ -102,7 +102,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call createUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -111,14 +111,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'body' when calling createUser(Async)");
}
com.squareup.okhttp.Call call = createUserCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -186,7 +182,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call createUsersWithArrayInputCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/user/createWithArray";
@@ -224,7 +220,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call createUsersWithArrayInputValidateBeforeCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -233,14 +229,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithArrayInput(Async)");
}
com.squareup.okhttp.Call call = createUsersWithArrayInputCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -308,7 +300,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call createUsersWithListInputCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/user/createWithList";
@@ -346,7 +338,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call createUsersWithListInputValidateBeforeCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -355,14 +347,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithListInput(Async)");
}
com.squareup.okhttp.Call call = createUsersWithListInputCall(body, progressListener, progressRequestListener);
return call;
}
/**
@@ -430,7 +418,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call deleteUserCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/user/{username}"
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
@@ -469,7 +457,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call deleteUserValidateBeforeCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -478,14 +466,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'username' when calling deleteUser(Async)");
}
com.squareup.okhttp.Call call = deleteUserCall(username, progressListener, progressRequestListener);
return call;
}
/**
@@ -553,7 +537,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call getUserByNameCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/user/{username}"
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
@@ -592,7 +576,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call getUserByNameValidateBeforeCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -601,14 +585,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'username' when calling getUserByName(Async)");
}
com.squareup.okhttp.Call call = getUserByNameCall(username, progressListener, progressRequestListener);
return call;
}
/**
@@ -681,7 +661,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call loginUserCall(String username, String password, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/user/login";
@@ -723,7 +703,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call loginUserValidateBeforeCall(String username, String password, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -737,14 +717,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'password' when calling loginUser(Async)");
}
com.squareup.okhttp.Call call = loginUserCall(username, password, progressListener, progressRequestListener);
return call;
}
/**
@@ -818,7 +794,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call logoutUserCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = null;
// create path and map variables
String localVarPath = "/user/logout";
@@ -856,18 +832,14 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call logoutUserValidateBeforeCall(final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
com.squareup.okhttp.Call call = logoutUserCall(progressListener, progressRequestListener);
return call;
}
/**
@@ -933,7 +905,7 @@ public class UserApi {
*/
public com.squareup.okhttp.Call updateUserCall(String username, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
Object localVarPostBody = body;
// create path and map variables
String localVarPath = "/user/{username}"
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
@@ -972,7 +944,7 @@ public class UserApi {
String[] localVarAuthNames = new String[] { };
return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
}
@SuppressWarnings("rawtypes")
private com.squareup.okhttp.Call updateUserValidateBeforeCall(String username, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
@@ -986,14 +958,10 @@ public class UserApi {
throw new ApiException("Missing the required parameter 'body' when calling updateUser(Async)");
}
com.squareup.okhttp.Call call = updateUserCall(username, body, progressListener, progressRequestListener);
return call;
}
/**