forked from loafle/openapi-generator-original
Java API invocation flexibility (#18078)
* add direct invocation methods for java (httpclient) * add direct invocation methods for java (resttemplate) * handle methods only if endpoints exist for api client * preserve previous newline to minimize changes * update httpclient/resttemplate samples * add common methods in base class * regenerate samples with base class
This commit is contained in:
@@ -33,6 +33,7 @@ settings.gradle
|
||||
src/main/AndroidManifest.xml
|
||||
src/main/java/org/openapitools/client/ApiClient.java
|
||||
src/main/java/org/openapitools/client/ApiException.java
|
||||
src/main/java/org/openapitools/client/BaseApi.java
|
||||
src/main/java/org/openapitools/client/Configuration.java
|
||||
src/main/java/org/openapitools/client/JavaTimeFormatter.java
|
||||
src/main/java/org/openapitools/client/Pair.java
|
||||
|
||||
@@ -834,15 +834,11 @@ public class ApiClient extends JavaTimeFormatter {
|
||||
}
|
||||
|
||||
/**
|
||||
* Build full URL by concatenating base path, the given sub path and query parameters.
|
||||
* Returns the URL of the client as defined by the server (if exists) or the base path.
|
||||
*
|
||||
* @param path The sub path
|
||||
* @param queryParams The query parameters
|
||||
* @param collectionQueryParams The collection query parameters
|
||||
* @param urlQueryDeepObject URL query string of the deep object parameters
|
||||
* @return The full URL
|
||||
* @return The URL for the client.
|
||||
*/
|
||||
private String buildUrl(String path, List<Pair> queryParams, List<Pair> collectionQueryParams, String urlQueryDeepObject) {
|
||||
public String getBaseURL() {
|
||||
String baseURL;
|
||||
if (serverIndex != null) {
|
||||
if (serverIndex < 0 || serverIndex >= servers.size()) {
|
||||
@@ -854,6 +850,20 @@ public class ApiClient extends JavaTimeFormatter {
|
||||
} else {
|
||||
baseURL = basePath;
|
||||
}
|
||||
return baseURL;
|
||||
}
|
||||
|
||||
/**
|
||||
* Build full URL by concatenating base URL, the given sub path and query parameters.
|
||||
*
|
||||
* @param path The sub path
|
||||
* @param queryParams The query parameters
|
||||
* @param collectionQueryParams The collection query parameters
|
||||
* @param urlQueryDeepObject URL query string of the deep object parameters
|
||||
* @return The full URL
|
||||
*/
|
||||
private String buildUrl(String path, List<Pair> queryParams, List<Pair> collectionQueryParams, String urlQueryDeepObject) {
|
||||
String baseURL = getBaseURL();
|
||||
|
||||
final StringBuilder url = new StringBuilder();
|
||||
url.append(baseURL).append(path);
|
||||
|
||||
@@ -0,0 +1,121 @@
|
||||
/*
|
||||
* Echo Server API
|
||||
* Echo Server API
|
||||
*
|
||||
* The version of the OpenAPI document: 0.1.0
|
||||
* Contact: team@openapitools.org
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
package org.openapitools.client;
|
||||
|
||||
import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public abstract class BaseApi {
|
||||
|
||||
protected ApiClient apiClient;
|
||||
|
||||
public BaseApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public BaseApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public void invokeAPI(String url, String method) throws ApiException {
|
||||
invokeAPI(url, method, null, null, Collections.emptyMap());
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param additionalHeaders Additional headers for the request.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public void invokeAPI(String url, String method, Map<String, String> additionalHeaders) throws ApiException {
|
||||
invokeAPI(url, method, null, null, additionalHeaders);
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public void invokeAPI(String url, String method, Object request) throws ApiException {
|
||||
invokeAPI(url, method, request, null, Collections.emptyMap());
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @param additionalHeaders Additional headers for the request.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public void invokeAPI(String url, String method, Object request, Map<String, String> additionalHeaders) throws ApiException {
|
||||
invokeAPI(url, method, request, null, additionalHeaders);
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param returnType The return type.
|
||||
* @return The API response in the specified type.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public <T> T invokeAPI(String url, String method, TypeReference<T> returnType) throws ApiException {
|
||||
return invokeAPI(url, method, null, returnType, Collections.emptyMap());
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @param returnType The return type.
|
||||
* @return The API response in the specified type.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType) throws ApiException {
|
||||
return invokeAPI(url, method, request, returnType, Collections.emptyMap());
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @param returnType The return type.
|
||||
* @param additionalHeaders Additional headers for the request.
|
||||
* @return The API response in the specified type.
|
||||
* @throws ApiException if fails to make API call.
|
||||
*/
|
||||
public abstract <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException;
|
||||
}
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -29,25 +30,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class AuthApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class AuthApi extends BaseApi {
|
||||
|
||||
public AuthApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public AuthApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -184,4 +174,44 @@ public class AuthApi {
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { "http_bearer_auth" };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -33,25 +34,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class BodyApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class BodyApi extends BaseApi {
|
||||
|
||||
public BodyApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public BodyApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -751,4 +741,44 @@ public class BodyApi {
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -29,25 +30,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class FormApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class FormApi extends BaseApi {
|
||||
|
||||
public FormApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public FormApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -220,4 +210,44 @@ if (name != null)
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -30,25 +31,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class HeaderApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class HeaderApi extends BaseApi {
|
||||
|
||||
public HeaderApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public HeaderApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -138,4 +128,44 @@ if (enumRefStringHeader != null)
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -30,25 +31,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class PathApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class PathApi extends BaseApi {
|
||||
|
||||
public PathApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public PathApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -150,4 +140,44 @@ public class PathApi {
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.fasterxml.jackson.core.type.TypeReference;
|
||||
|
||||
import org.openapitools.client.ApiException;
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
import org.openapitools.client.Configuration;
|
||||
import org.openapitools.client.Pair;
|
||||
|
||||
@@ -36,25 +37,14 @@ import java.util.Map;
|
||||
import java.util.StringJoiner;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class QueryApi {
|
||||
|
||||
|
||||
private ApiClient apiClient;
|
||||
public class QueryApi extends BaseApi {
|
||||
|
||||
public QueryApi() {
|
||||
this(Configuration.getDefaultApiClient());
|
||||
super(Configuration.getDefaultApiClient());
|
||||
}
|
||||
|
||||
public QueryApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -779,4 +769,44 @@ public class QueryApi {
|
||||
);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> T invokeAPI(String url, String method, Object request, TypeReference<T> returnType, Map<String, String> additionalHeaders) throws ApiException {
|
||||
String localVarPath = url.replace(apiClient.getBaseURL(), "");
|
||||
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
|
||||
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
|
||||
Map<String, String> localVarCookieParams = new HashMap<String, String>();
|
||||
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
|
||||
|
||||
localVarHeaderParams.putAll(additionalHeaders);
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
|
||||
final String[] localVarContentTypes = {
|
||||
|
||||
};
|
||||
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
localVarPath,
|
||||
method,
|
||||
localVarQueryParams,
|
||||
localVarCollectionQueryParams,
|
||||
localVarQueryStringJoiner.toString(),
|
||||
request,
|
||||
localVarHeaderParams,
|
||||
localVarCookieParams,
|
||||
localVarFormParams,
|
||||
localVarAccept,
|
||||
localVarContentType,
|
||||
localVarAuthNames,
|
||||
returnType
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,6 +32,7 @@ pom.xml
|
||||
settings.gradle
|
||||
src/main/AndroidManifest.xml
|
||||
src/main/java/org/openapitools/client/ApiClient.java
|
||||
src/main/java/org/openapitools/client/BaseApi.java
|
||||
src/main/java/org/openapitools/client/JavaTimeFormatter.java
|
||||
src/main/java/org/openapitools/client/RFC3339DateFormat.java
|
||||
src/main/java/org/openapitools/client/ServerConfiguration.java
|
||||
|
||||
@@ -0,0 +1,74 @@
|
||||
package org.openapitools.client;
|
||||
|
||||
import org.springframework.web.client.RestClientException;
|
||||
import org.springframework.core.ParameterizedTypeReference;
|
||||
import org.springframework.http.HttpMethod;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public abstract class BaseApi {
|
||||
|
||||
protected ApiClient apiClient;
|
||||
|
||||
public BaseApi() {
|
||||
this(new ApiClient());
|
||||
}
|
||||
|
||||
public BaseApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @return ResponseEntity<Void>
|
||||
* @throws RestClientException if an error occurs while attempting to invoke the API
|
||||
*/
|
||||
public ResponseEntity<Void> invokeAPI(String url, HttpMethod method) throws RestClientException {
|
||||
return invokeAPI(url, method, null, new ParameterizedTypeReference<Void>() {});
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @return ResponseEntity<Void>
|
||||
* @throws RestClientException if an error occurs while attempting to invoke the API
|
||||
*/
|
||||
public ResponseEntity<Void> invokeAPI(String url, HttpMethod method, Object request) throws RestClientException {
|
||||
return invokeAPI(url, method, request, new ParameterizedTypeReference<Void>() {});
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param returnType The return type.
|
||||
* @return ResponseEntity in the specified type.
|
||||
* @throws RestClientException if an error occurs while attempting to invoke the API
|
||||
*/
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
return invokeAPI(url, method, null, returnType);
|
||||
}
|
||||
|
||||
/**
|
||||
* Directly invoke the API for the given URL. Useful if the API returns direct links/URLs for subsequent requests.
|
||||
* @param url The URL for the request, either full URL or only the path.
|
||||
* @param method The HTTP method for the request.
|
||||
* @param request The request object.
|
||||
* @param returnType The return type.
|
||||
* @return ResponseEntity in the specified type.
|
||||
* @throws RestClientException if an error occurs while attempting to invoke the API
|
||||
*/
|
||||
public abstract <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException;
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
|
||||
import java.util.Collections;
|
||||
@@ -25,23 +26,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class AuthApi {
|
||||
private ApiClient apiClient;
|
||||
public class AuthApi extends BaseApi {
|
||||
|
||||
public AuthApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public AuthApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -122,4 +114,27 @@ public class AuthApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/auth/http/bearer", HttpMethod.POST, Collections.<String, Object>emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { "http_bearer_auth" };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
import java.io.File;
|
||||
import org.openapitools.client.model.Pet;
|
||||
@@ -29,23 +30,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class BodyApi {
|
||||
private ApiClient apiClient;
|
||||
public class BodyApi extends BaseApi {
|
||||
|
||||
public BodyApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public BodyApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -485,4 +477,29 @@ public class BodyApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/echo/body/Tag/response_string", HttpMethod.POST, Collections.<String, Object>emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
|
||||
import java.util.Collections;
|
||||
@@ -25,23 +26,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class FormApi {
|
||||
private ApiClient apiClient;
|
||||
public class FormApi extends BaseApi {
|
||||
|
||||
public FormApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public FormApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -164,4 +156,29 @@ public class FormApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/form/oneof", HttpMethod.POST, Collections.<String, Object>emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
import org.openapitools.client.model.StringEnumRef;
|
||||
|
||||
@@ -26,23 +27,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class HeaderApi {
|
||||
private ApiClient apiClient;
|
||||
public class HeaderApi extends BaseApi {
|
||||
|
||||
public HeaderApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public HeaderApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -105,4 +97,27 @@ public class HeaderApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/header/integer/boolean/string/enums", HttpMethod.GET, Collections.<String, Object>emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
import org.openapitools.client.model.StringEnumRef;
|
||||
|
||||
@@ -26,23 +27,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class PathApi {
|
||||
private ApiClient apiClient;
|
||||
public class PathApi extends BaseApi {
|
||||
|
||||
public PathApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public PathApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -118,4 +110,27 @@ public class PathApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path}", HttpMethod.GET, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package org.openapitools.client.api;
|
||||
|
||||
import org.openapitools.client.ApiClient;
|
||||
import org.openapitools.client.BaseApi;
|
||||
|
||||
import org.openapitools.client.model.DataQuery;
|
||||
import java.time.LocalDate;
|
||||
@@ -32,23 +33,14 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
|
||||
public class QueryApi {
|
||||
private ApiClient apiClient;
|
||||
public class QueryApi extends BaseApi {
|
||||
|
||||
public QueryApi() {
|
||||
this(new ApiClient());
|
||||
super(new ApiClient());
|
||||
}
|
||||
|
||||
public QueryApi(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
}
|
||||
|
||||
public ApiClient getApiClient() {
|
||||
return apiClient;
|
||||
}
|
||||
|
||||
public void setApiClient(ApiClient apiClient) {
|
||||
this.apiClient = apiClient;
|
||||
super(apiClient);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -522,4 +514,27 @@ public class QueryApi {
|
||||
ParameterizedTypeReference<String> localReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/query/style_form/explode_true/object/allOf", HttpMethod.GET, Collections.<String, Object>emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
|
||||
}
|
||||
|
||||
@Override
|
||||
public <T> ResponseEntity<T> invokeAPI(String url, HttpMethod method, Object request, ParameterizedTypeReference<T> returnType) throws RestClientException {
|
||||
String localVarPath = url.replace(apiClient.getBasePath(), "");
|
||||
Object localVarPostBody = request;
|
||||
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
final MultiValueMap<String, String> localVarQueryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders localVarHeaderParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> localVarCookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> localVarFormParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] localVarAccepts = {
|
||||
"text/plain"
|
||||
};
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
return apiClient.invokeAPI(localVarPath, method, uriVariables, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, returnType);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user