mirror of
https://github.com/valitydev/openapi-generator.git
synced 2024-11-07 19:08:52 +00:00
update generated petstore for ok-http-gson #2549
This commit is contained in:
parent
1d305b1faf
commit
9d8c419698
@ -8,17 +8,17 @@ git_repo_id=$2
|
||||
release_note=$3
|
||||
|
||||
if [ "$git_user_id" = "" ]; then
|
||||
git_user_id="GIT_USER_ID"
|
||||
git_user_id=""
|
||||
echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
|
||||
fi
|
||||
|
||||
if [ "$git_repo_id" = "" ]; then
|
||||
git_repo_id="GIT_REPO_ID"
|
||||
git_repo_id=""
|
||||
echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
|
||||
fi
|
||||
|
||||
if [ "$release_note" = "" ]; then
|
||||
release_note="Minor update"
|
||||
release_note=""
|
||||
echo "[INFO] No command line input provided. Set \$release_note to $release_note"
|
||||
fi
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -28,7 +28,7 @@ package io.swagger.client;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class ApiException extends Exception {
|
||||
private int code = 0;
|
||||
private Map<String, List<String>> responseHeaders = null;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -31,7 +31,7 @@ import java.util.Map;
|
||||
/**
|
||||
* API response returned by API call.
|
||||
*
|
||||
* @param T The type of data that is deserialized from response body
|
||||
* @param <T> The type of data that is deserialized from response body
|
||||
*/
|
||||
public class ApiResponse<T> {
|
||||
final private int statusCode;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -25,7 +25,7 @@
|
||||
|
||||
package io.swagger.client;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Configuration {
|
||||
private static ApiClient defaultApiClient = new ApiClient();
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -100,7 +100,7 @@ public class JSON {
|
||||
*
|
||||
* @param <T> Type
|
||||
* @param body The JSON string
|
||||
* @param returnType The type to deserialize inot
|
||||
* @param returnType The type to deserialize into
|
||||
* @return The deserialized Java object
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
@ -162,10 +162,9 @@ class DateAdapter implements JsonSerializer<Date>, JsonDeserializer<Date> {
|
||||
*
|
||||
* @param json Json element
|
||||
* @param date Type
|
||||
* @param typeOfSrc Type
|
||||
* @param context Json Serialization Context
|
||||
* @return Date
|
||||
* @throw JsonParseException if fail to parse
|
||||
* @throws JsonParseException if fail to parse
|
||||
*/
|
||||
@Override
|
||||
public Date deserialize(JsonElement json, Type date, JsonDeserializationContext context) throws JsonParseException {
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -25,7 +25,7 @@
|
||||
|
||||
package io.swagger.client;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Pair {
|
||||
private String name = "";
|
||||
private String value = "";
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -25,7 +25,7 @@
|
||||
|
||||
package io.swagger.client;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class StringUtil {
|
||||
/**
|
||||
* Check if the given array contains the given value (with case-insensitive comparison).
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -33,14 +33,16 @@ import io.swagger.client.Configuration;
|
||||
import io.swagger.client.Pair;
|
||||
import io.swagger.client.ProgressRequestBody;
|
||||
import io.swagger.client.ProgressResponseBody;
|
||||
import io.swagger.client.BeanValidationException;
|
||||
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
|
||||
import io.swagger.client.model.Pet;
|
||||
import java.io.File;
|
||||
import io.swagger.client.model.ModelApiResponse;
|
||||
import java.io.File;
|
||||
|
||||
import java.lang.reflect.Type;
|
||||
import java.util.ArrayList;
|
||||
@ -71,12 +73,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call addPetCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling addPet(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -112,6 +108,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call addPetValidateBeforeCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling addPet(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = addPetCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -132,7 +145,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> addPetWithHttpInfo(Pet body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = addPetCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = addPetValidateBeforeCall(body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -165,7 +178,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = addPetCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = addPetValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -173,12 +186,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call deletePetCall(Long petId, String apiKey, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling deletePet(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
@ -217,6 +224,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call deletePetValidateBeforeCall(Long petId, String apiKey, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling deletePet(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = deletePetCall(petId, apiKey, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -239,7 +263,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> deletePetWithHttpInfo(Long petId, String apiKey) throws ApiException {
|
||||
com.squareup.okhttp.Call call = deletePetCall(petId, apiKey, null, null);
|
||||
com.squareup.okhttp.Call call = deletePetValidateBeforeCall(petId, apiKey, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -273,7 +297,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = deletePetCall(petId, apiKey, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = deletePetValidateBeforeCall(petId, apiKey, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -281,12 +305,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call findPetsByStatusCall(List<String> status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'status' is set
|
||||
if (status == null) {
|
||||
throw new ApiException("Missing the required parameter 'status' when calling findPetsByStatus(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/findByStatus".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -324,6 +342,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call findPetsByStatusValidateBeforeCall(List<String> status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'status' is set
|
||||
if (status == null) {
|
||||
throw new ApiException("Missing the required parameter 'status' when calling findPetsByStatus(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = findPetsByStatusCall(status, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -346,7 +381,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<List<Pet>> findPetsByStatusWithHttpInfo(List<String> status) throws ApiException {
|
||||
com.squareup.okhttp.Call call = findPetsByStatusCall(status, null, null);
|
||||
com.squareup.okhttp.Call call = findPetsByStatusValidateBeforeCall(status, null, null);
|
||||
Type localVarReturnType = new TypeToken<List<Pet>>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -380,7 +415,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = findPetsByStatusCall(status, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = findPetsByStatusValidateBeforeCall(status, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<List<Pet>>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -389,12 +424,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call findPetsByTagsCall(List<String> tags, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'tags' is set
|
||||
if (tags == null) {
|
||||
throw new ApiException("Missing the required parameter 'tags' when calling findPetsByTags(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/findByTags".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -432,6 +461,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call findPetsByTagsValidateBeforeCall(List<String> tags, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'tags' is set
|
||||
if (tags == null) {
|
||||
throw new ApiException("Missing the required parameter 'tags' when calling findPetsByTags(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = findPetsByTagsCall(tags, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -454,7 +500,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<List<Pet>> findPetsByTagsWithHttpInfo(List<String> tags) throws ApiException {
|
||||
com.squareup.okhttp.Call call = findPetsByTagsCall(tags, null, null);
|
||||
com.squareup.okhttp.Call call = findPetsByTagsValidateBeforeCall(tags, null, null);
|
||||
Type localVarReturnType = new TypeToken<List<Pet>>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -488,7 +534,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = findPetsByTagsCall(tags, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = findPetsByTagsValidateBeforeCall(tags, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<List<Pet>>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -497,12 +543,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call getPetByIdCall(Long petId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling getPetById(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
@ -539,6 +579,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "api_key" };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call getPetByIdValidateBeforeCall(Long petId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling getPetById(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = getPetByIdCall(petId, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -561,7 +618,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Pet> getPetByIdWithHttpInfo(Long petId) throws ApiException {
|
||||
com.squareup.okhttp.Call call = getPetByIdCall(petId, null, null);
|
||||
com.squareup.okhttp.Call call = getPetByIdValidateBeforeCall(petId, null, null);
|
||||
Type localVarReturnType = new TypeToken<Pet>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -595,7 +652,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = getPetByIdCall(petId, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = getPetByIdValidateBeforeCall(petId, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<Pet>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -604,12 +661,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call updatePetCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling updatePet(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -645,6 +696,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call updatePetValidateBeforeCall(Pet body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling updatePet(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = updatePetCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -665,7 +733,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> updatePetWithHttpInfo(Pet body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = updatePetCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = updatePetValidateBeforeCall(body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -698,7 +766,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = updatePetCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = updatePetValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -706,12 +774,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call updatePetWithFormCall(Long petId, String name, String status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling updatePetWithForm(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
@ -752,6 +814,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call updatePetWithFormValidateBeforeCall(Long petId, String name, String status, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
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;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -776,7 +855,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> updatePetWithFormWithHttpInfo(Long petId, String name, String status) throws ApiException {
|
||||
com.squareup.okhttp.Call call = updatePetWithFormCall(petId, name, status, null, null);
|
||||
com.squareup.okhttp.Call call = updatePetWithFormValidateBeforeCall(petId, name, status, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -811,7 +890,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = updatePetWithFormCall(petId, name, status, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = updatePetWithFormValidateBeforeCall(petId, name, status, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -819,12 +898,6 @@ public class PetApi {
|
||||
private com.squareup.okhttp.Call uploadFileCall(Long petId, String additionalMetadata, File file, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new ApiException("Missing the required parameter 'petId' when calling uploadFile(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImage".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
@ -865,6 +938,23 @@ public class PetApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call uploadFileValidateBeforeCall(Long petId, String additionalMetadata, File file, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
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;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -891,7 +981,7 @@ public class PetApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<ModelApiResponse> uploadFileWithHttpInfo(Long petId, String additionalMetadata, File file) throws ApiException {
|
||||
com.squareup.okhttp.Call call = uploadFileCall(petId, additionalMetadata, file, null, null);
|
||||
com.squareup.okhttp.Call call = uploadFileValidateBeforeCall(petId, additionalMetadata, file, null, null);
|
||||
Type localVarReturnType = new TypeToken<ModelApiResponse>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -927,7 +1017,7 @@ public class PetApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = uploadFileCall(petId, additionalMetadata, file, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = uploadFileValidateBeforeCall(petId, additionalMetadata, file, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<ModelApiResponse>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -33,11 +33,13 @@ import io.swagger.client.Configuration;
|
||||
import io.swagger.client.Pair;
|
||||
import io.swagger.client.ProgressRequestBody;
|
||||
import io.swagger.client.ProgressResponseBody;
|
||||
import io.swagger.client.BeanValidationException;
|
||||
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
|
||||
import io.swagger.client.model.Order;
|
||||
|
||||
import java.lang.reflect.Type;
|
||||
@ -69,12 +71,6 @@ public class StoreApi {
|
||||
private com.squareup.okhttp.Call deleteOrderCall(String orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new ApiException("Missing the required parameter 'orderId' when calling deleteOrder(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/store/order/{orderId}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "orderId" + "\\}", apiClient.escapeString(orderId.toString()));
|
||||
@ -111,6 +107,23 @@ public class StoreApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call deleteOrderValidateBeforeCall(String orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new ApiException("Missing the required parameter 'orderId' when calling deleteOrder(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = deleteOrderCall(orderId, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -131,7 +144,7 @@ public class StoreApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> deleteOrderWithHttpInfo(String orderId) throws ApiException {
|
||||
com.squareup.okhttp.Call call = deleteOrderCall(orderId, null, null);
|
||||
com.squareup.okhttp.Call call = deleteOrderValidateBeforeCall(orderId, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -164,7 +177,7 @@ public class StoreApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = deleteOrderCall(orderId, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = deleteOrderValidateBeforeCall(orderId, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -172,7 +185,6 @@ public class StoreApi {
|
||||
private 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".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -208,6 +220,18 @@ public class StoreApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { "api_key" };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
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;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -228,7 +252,7 @@ public class StoreApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Map<String, Integer>> getInventoryWithHttpInfo() throws ApiException {
|
||||
com.squareup.okhttp.Call call = getInventoryCall(null, null);
|
||||
com.squareup.okhttp.Call call = getInventoryValidateBeforeCall(null, null);
|
||||
Type localVarReturnType = new TypeToken<Map<String, Integer>>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -261,7 +285,7 @@ public class StoreApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = getInventoryCall(progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = getInventoryValidateBeforeCall(progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<Map<String, Integer>>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -270,12 +294,6 @@ public class StoreApi {
|
||||
private com.squareup.okhttp.Call getOrderByIdCall(Long orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new ApiException("Missing the required parameter 'orderId' when calling getOrderById(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/store/order/{orderId}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "orderId" + "\\}", apiClient.escapeString(orderId.toString()));
|
||||
@ -312,6 +330,23 @@ public class StoreApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call getOrderByIdValidateBeforeCall(Long orderId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new ApiException("Missing the required parameter 'orderId' when calling getOrderById(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = getOrderByIdCall(orderId, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -334,7 +369,7 @@ public class StoreApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Order> getOrderByIdWithHttpInfo(Long orderId) throws ApiException {
|
||||
com.squareup.okhttp.Call call = getOrderByIdCall(orderId, null, null);
|
||||
com.squareup.okhttp.Call call = getOrderByIdValidateBeforeCall(orderId, null, null);
|
||||
Type localVarReturnType = new TypeToken<Order>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -368,7 +403,7 @@ public class StoreApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = getOrderByIdCall(orderId, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = getOrderByIdValidateBeforeCall(orderId, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<Order>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -377,12 +412,6 @@ public class StoreApi {
|
||||
private com.squareup.okhttp.Call placeOrderCall(Order body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling placeOrder(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/store/order".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -418,6 +447,23 @@ public class StoreApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call placeOrderValidateBeforeCall(Order body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling placeOrder(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = placeOrderCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -440,7 +486,7 @@ public class StoreApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Order> placeOrderWithHttpInfo(Order body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = placeOrderCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = placeOrderValidateBeforeCall(body, null, null);
|
||||
Type localVarReturnType = new TypeToken<Order>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -474,7 +520,7 @@ public class StoreApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = placeOrderCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = placeOrderValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<Order>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -33,11 +33,13 @@ import io.swagger.client.Configuration;
|
||||
import io.swagger.client.Pair;
|
||||
import io.swagger.client.ProgressRequestBody;
|
||||
import io.swagger.client.ProgressResponseBody;
|
||||
import io.swagger.client.BeanValidationException;
|
||||
|
||||
import com.google.gson.reflect.TypeToken;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
|
||||
import io.swagger.client.model.User;
|
||||
|
||||
import java.lang.reflect.Type;
|
||||
@ -69,12 +71,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call createUserCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -110,6 +106,23 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call createUserValidateBeforeCall(User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = createUserCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -130,7 +143,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> createUserWithHttpInfo(User body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = createUserCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = createUserValidateBeforeCall(body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -163,7 +176,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = createUserCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = createUserValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -171,12 +184,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call createUsersWithArrayInputCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithArrayInput(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/createWithArray".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -212,6 +219,23 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call createUsersWithArrayInputValidateBeforeCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithArrayInput(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = createUsersWithArrayInputCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -232,7 +256,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> createUsersWithArrayInputWithHttpInfo(List<User> body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = createUsersWithArrayInputCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = createUsersWithArrayInputValidateBeforeCall(body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -265,7 +289,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = createUsersWithArrayInputCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = createUsersWithArrayInputValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -273,12 +297,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call createUsersWithListInputCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithListInput(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/createWithList".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -314,6 +332,23 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call createUsersWithListInputValidateBeforeCall(List<User> body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling createUsersWithListInput(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = createUsersWithListInputCall(body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -334,7 +369,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> createUsersWithListInputWithHttpInfo(List<User> body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = createUsersWithListInputCall(body, null, null);
|
||||
com.squareup.okhttp.Call call = createUsersWithListInputValidateBeforeCall(body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -367,7 +402,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = createUsersWithListInputCall(body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = createUsersWithListInputValidateBeforeCall(body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -375,12 +410,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call deleteUserCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling deleteUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/{username}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
|
||||
@ -417,6 +446,23 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call deleteUserValidateBeforeCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling deleteUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = deleteUserCall(username, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -437,7 +483,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> deleteUserWithHttpInfo(String username) throws ApiException {
|
||||
com.squareup.okhttp.Call call = deleteUserCall(username, null, null);
|
||||
com.squareup.okhttp.Call call = deleteUserValidateBeforeCall(username, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -470,7 +516,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = deleteUserCall(username, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = deleteUserValidateBeforeCall(username, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -478,12 +524,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call getUserByNameCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling getUserByName(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/{username}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
|
||||
@ -520,6 +560,23 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call getUserByNameValidateBeforeCall(String username, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling getUserByName(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = getUserByNameCall(username, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -542,7 +599,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<User> getUserByNameWithHttpInfo(String username) throws ApiException {
|
||||
com.squareup.okhttp.Call call = getUserByNameCall(username, null, null);
|
||||
com.squareup.okhttp.Call call = getUserByNameValidateBeforeCall(username, null, null);
|
||||
Type localVarReturnType = new TypeToken<User>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -576,7 +633,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = getUserByNameCall(username, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = getUserByNameValidateBeforeCall(username, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<User>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -585,17 +642,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call loginUserCall(String username, String password, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling loginUser(Async)");
|
||||
}
|
||||
|
||||
// verify the required parameter 'password' is set
|
||||
if (password == null) {
|
||||
throw new ApiException("Missing the required parameter 'password' when calling loginUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/login".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -635,6 +681,28 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call loginUserValidateBeforeCall(String username, String password, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling loginUser(Async)");
|
||||
}
|
||||
|
||||
// verify the required parameter 'password' is set
|
||||
if (password == null) {
|
||||
throw new ApiException("Missing the required parameter 'password' when calling loginUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = loginUserCall(username, password, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -659,7 +727,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<String> loginUserWithHttpInfo(String username, String password) throws ApiException {
|
||||
com.squareup.okhttp.Call call = loginUserCall(username, password, null, null);
|
||||
com.squareup.okhttp.Call call = loginUserValidateBeforeCall(username, password, null, null);
|
||||
Type localVarReturnType = new TypeToken<String>(){}.getType();
|
||||
return apiClient.execute(call, localVarReturnType);
|
||||
}
|
||||
@ -694,7 +762,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = loginUserCall(username, password, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = loginUserValidateBeforeCall(username, password, progressListener, progressRequestListener);
|
||||
Type localVarReturnType = new TypeToken<String>(){}.getType();
|
||||
apiClient.executeAsync(call, localVarReturnType, callback);
|
||||
return call;
|
||||
@ -703,7 +771,6 @@ public class UserApi {
|
||||
private 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".replaceAll("\\{format\\}","json");
|
||||
|
||||
@ -739,6 +806,18 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
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;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -757,7 +836,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> logoutUserWithHttpInfo() throws ApiException {
|
||||
com.squareup.okhttp.Call call = logoutUserCall(null, null);
|
||||
com.squareup.okhttp.Call call = logoutUserValidateBeforeCall(null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -789,7 +868,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = logoutUserCall(progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = logoutUserValidateBeforeCall(progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
@ -797,17 +876,6 @@ public class UserApi {
|
||||
private com.squareup.okhttp.Call updateUserCall(String username, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
Object localVarPostBody = body;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling updateUser(Async)");
|
||||
}
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling updateUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/user/{username}".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "username" + "\\}", apiClient.escapeString(username.toString()));
|
||||
@ -844,6 +912,28 @@ public class UserApi {
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
return apiClient.buildCall(localVarPath, "PUT", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
|
||||
}
|
||||
|
||||
private com.squareup.okhttp.Call updateUserValidateBeforeCall(String username, User body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new ApiException("Missing the required parameter 'username' when calling updateUser(Async)");
|
||||
}
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new ApiException("Missing the required parameter 'body' when calling updateUser(Async)");
|
||||
}
|
||||
|
||||
|
||||
com.squareup.okhttp.Call call = updateUserCall(username, body, progressListener, progressRequestListener);
|
||||
return call;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -866,7 +956,7 @@ public class UserApi {
|
||||
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
|
||||
*/
|
||||
public ApiResponse<Void> updateUserWithHttpInfo(String username, User body) throws ApiException {
|
||||
com.squareup.okhttp.Call call = updateUserCall(username, body, null, null);
|
||||
com.squareup.okhttp.Call call = updateUserValidateBeforeCall(username, body, null, null);
|
||||
return apiClient.execute(call);
|
||||
}
|
||||
|
||||
@ -900,7 +990,7 @@ public class UserApi {
|
||||
};
|
||||
}
|
||||
|
||||
com.squareup.okhttp.Call call = updateUserCall(username, body, progressListener, progressRequestListener);
|
||||
com.squareup.okhttp.Call call = updateUserValidateBeforeCall(username, body, progressListener, progressRequestListener);
|
||||
apiClient.executeAsync(call, callback);
|
||||
return call;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -30,7 +30,7 @@ import io.swagger.client.Pair;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class ApiKeyAuth implements Authentication {
|
||||
private final String location;
|
||||
private final String paramName;
|
||||
@ -78,9 +78,9 @@ public class ApiKeyAuth implements Authentication {
|
||||
} else {
|
||||
value = apiKey;
|
||||
}
|
||||
if (location == "query") {
|
||||
if ("query".equals(location)) {
|
||||
queryParams.add(new Pair(paramName, value));
|
||||
} else if (location == "header") {
|
||||
} else if ("header".equals(location)) {
|
||||
headerParams.put(paramName, value);
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -30,7 +30,7 @@ import io.swagger.client.Pair;
|
||||
import java.util.Map;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class OAuth implements Authentication {
|
||||
private String accessToken;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -31,9 +31,10 @@ import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
/**
|
||||
* Category
|
||||
* A category for a pet
|
||||
*/
|
||||
|
||||
@ApiModel(description = "A category for a pet")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Category {
|
||||
@SerializedName("id")
|
||||
private Long id = null;
|
||||
@ -96,6 +97,7 @@ public class Category {
|
||||
return Objects.hash(id, name);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -31,9 +31,10 @@ import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
/**
|
||||
* ModelApiResponse
|
||||
* Describes the result of uploading an image resource
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Describes the result of uploading an image resource")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class ModelApiResponse {
|
||||
@SerializedName("code")
|
||||
private Integer code = null;
|
||||
@ -118,6 +119,7 @@ public class ModelApiResponse {
|
||||
return Objects.hash(code, type, message);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -32,9 +32,10 @@ import io.swagger.annotations.ApiModelProperty;
|
||||
import org.joda.time.DateTime;
|
||||
|
||||
/**
|
||||
* Order
|
||||
* An order for a pets from the pet store
|
||||
*/
|
||||
|
||||
@ApiModel(description = "An order for a pets from the pet store")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Order {
|
||||
@SerializedName("id")
|
||||
private Long id = null;
|
||||
@ -210,6 +211,7 @@ public class Order {
|
||||
return Objects.hash(id, petId, quantity, shipDate, status, complete);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -35,9 +35,10 @@ import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Pet
|
||||
* A pet for sale in the pet store
|
||||
*/
|
||||
|
||||
@ApiModel(description = "A pet for sale in the pet store")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Pet {
|
||||
@SerializedName("id")
|
||||
private Long id = null;
|
||||
@ -141,6 +142,11 @@ public class Pet {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Pet addPhotoUrlsItem(String photoUrlsItem) {
|
||||
this.photoUrls.add(photoUrlsItem);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get photoUrls
|
||||
* @return photoUrls
|
||||
@ -159,6 +165,11 @@ public class Pet {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Pet addTagsItem(Tag tagsItem) {
|
||||
this.tags.add(tagsItem);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get tags
|
||||
* @return tags
|
||||
@ -213,6 +224,7 @@ public class Pet {
|
||||
return Objects.hash(id, category, name, photoUrls, tags, status);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -31,9 +31,10 @@ import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
/**
|
||||
* Tag
|
||||
* A tag for a pet
|
||||
*/
|
||||
|
||||
@ApiModel(description = "A tag for a pet")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class Tag {
|
||||
@SerializedName("id")
|
||||
private Long id = null;
|
||||
@ -96,6 +97,7 @@ public class Tag {
|
||||
return Objects.hash(id, name);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
/*
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
* This is a sample server Petstore server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
@ -31,9 +31,10 @@ import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
/**
|
||||
* User
|
||||
* A User who is purchasing from the pet store
|
||||
*/
|
||||
|
||||
@ApiModel(description = "A User who is purchasing from the pet store")
|
||||
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-11-12T23:18:03.999+01:00")
|
||||
public class User {
|
||||
@SerializedName("id")
|
||||
private Long id = null;
|
||||
@ -228,6 +229,7 @@ public class User {
|
||||
return Objects.hash(id, username, firstName, lastName, email, password, phone, userStatus);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
|
Loading…
Reference in New Issue
Block a user