forked from loafle/openapi-generator-original
[Java][WebClient] better code format (#5433)
* better code format for java webclient * prefix local varaible with localVar
This commit is contained in:
@@ -555,7 +555,7 @@ public class ApiClient {
|
||||
updateParamsForAuth(authNames, queryParams, headerParams, cookieParams);
|
||||
|
||||
final UriComponentsBuilder builder = UriComponentsBuilder.fromHttpUrl(basePath).path(path);
|
||||
if (queryParams != null) {
|
||||
if (queryParams != null) {
|
||||
builder.queryParams(queryParams);
|
||||
}
|
||||
|
||||
|
||||
@@ -4,11 +4,13 @@ import {{invokerPackage}}.ApiClient;
|
||||
|
||||
{{#imports}}import {{import}};
|
||||
{{/imports}}
|
||||
{{^fullJavaUtil}}
|
||||
|
||||
{{^fullJavaUtil}}import java.util.HashMap;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;{{/fullJavaUtil}}
|
||||
import java.util.Map;
|
||||
{{/fullJavaUtil}}
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.util.LinkedMultiValueMap;
|
||||
@@ -62,49 +64,68 @@ public class {{classname}} {
|
||||
*/
|
||||
public {{#returnType}}{{#isListContainer}}Flux<{{{returnBaseType}}}>{{/isListContainer}}{{^isListContainer}}Mono<{{{returnType}}}>{{/isListContainer}} {{/returnType}}{{^returnType}}Mono<Void> {{/returnType}}{{operationId}}({{#allParams}}{{{dataType}}} {{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}) throws RestClientException {
|
||||
Object postBody = {{#bodyParam}}{{paramName}}{{/bodyParam}}{{^bodyParam}}null{{/bodyParam}};
|
||||
{{#allParams}}{{#required}}
|
||||
{{#allParams}}
|
||||
{{#required}}
|
||||
// verify the required parameter '{{paramName}}' is set
|
||||
if ({{paramName}} == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter '{{paramName}}' when calling {{operationId}}");
|
||||
}
|
||||
{{/required}}{{/allParams}}
|
||||
{{/required}}
|
||||
{{/allParams}}
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();{{#hasPathParams}}{{#pathParams}}
|
||||
pathParams.put("{{baseName}}", {{#collectionFormat}}apiClient.collectionPathParameterToString(ApiClient.CollectionFormat.valueOf("csv".toUpperCase()), {{/collectionFormat}}{{{paramName}}}{{#collectionFormat}}){{/collectionFormat}});{{/pathParams}}{{/hasPathParams}}
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
{{#hasPathParams}}
|
||||
|
||||
{{#pathParams}}
|
||||
pathParams.put("{{baseName}}", {{#collectionFormat}}apiClient.collectionPathParameterToString(ApiClient.CollectionFormat.valueOf("csv".toUpperCase()), {{/collectionFormat}}{{{paramName}}}{{#collectionFormat}}){{/collectionFormat}});
|
||||
{{/pathParams}}
|
||||
{{/hasPathParams}}
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();{{#hasQueryParams}}
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
{{#hasQueryParams}}
|
||||
|
||||
{{#queryParams}}queryParams.putAll(apiClient.parameterToMultiValueMap({{#collectionFormat}}ApiClient.CollectionFormat.valueOf("{{{collectionFormat}}}".toUpperCase(Locale.ROOT)){{/collectionFormat}}{{^collectionFormat}}null{{/collectionFormat}}, "{{baseName}}", {{paramName}}));{{#hasMore}}
|
||||
{{/hasMore}}{{/queryParams}}{{/hasQueryParams}}{{#hasHeaderParams}}
|
||||
{{#queryParams}}
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap({{#collectionFormat}}ApiClient.CollectionFormat.valueOf("{{{collectionFormat}}}".toUpperCase(Locale.ROOT)){{/collectionFormat}}{{^collectionFormat}}null{{/collectionFormat}}, "{{baseName}}", {{paramName}}));
|
||||
{{/queryParams}}
|
||||
{{/hasQueryParams}}
|
||||
{{#hasHeaderParams}}
|
||||
|
||||
{{#headerParams}}if ({{paramName}} != null)
|
||||
{{#headerParams}}
|
||||
if ({{paramName}} != null)
|
||||
headerParams.add("{{baseName}}", apiClient.parameterToString({{paramName}}));{{#hasMore}}
|
||||
{{/hasMore}}{{/headerParams}}{{/hasHeaderParams}}{{#hasCookieParams}}
|
||||
{{/hasMore}}
|
||||
{{/headerParams}}
|
||||
{{/hasHeaderParams}}
|
||||
{{#hasCookieParams}}
|
||||
|
||||
{{#cookieParams}}cookieParams.putAll(apiClient.parameterToMultiValueMap({{#collectionFormat}}ApiClient.CollectionFormat.valueOf("{{{collectionFormat}}}".toUpperCase(Locale.ROOT)){{/collectionFormat}}{{^collectionFormat}}null{{/collectionFormat}}, "{{baseName}}", {{paramName}}));{{#hasMore}}
|
||||
{{/hasMore}}{{/cookieParams}}{{/hasCookieParams}}{{#hasFormParams}}
|
||||
{{#cookieParams}}
|
||||
cookieParams.putAll(apiClient.parameterToMultiValueMap({{#collectionFormat}}ApiClient.CollectionFormat.valueOf("{{{collectionFormat}}}".toUpperCase(Locale.ROOT)){{/collectionFormat}}{{^collectionFormat}}null{{/collectionFormat}}, "{{baseName}}", {{paramName}}));
|
||||
{{/cookieParams}}
|
||||
{{/hasCookieParams}}
|
||||
{{#hasFormParams}}
|
||||
|
||||
{{#formParams}}if ({{paramName}} != null)
|
||||
formParams.add{{#collectionFormat}}All{{/collectionFormat}}("{{baseName}}", {{#isFile}}new FileSystemResource({{paramName}}){{/isFile}}{{^isFile}}{{paramName}}{{/isFile}});{{#hasMore}}
|
||||
{{/hasMore}}{{/formParams}}{{/hasFormParams}}
|
||||
{{#formParams}}
|
||||
if ({{paramName}} != null)
|
||||
formParams.add{{#collectionFormat}}All{{/collectionFormat}}("{{baseName}}", {{#isFile}}new FileSystemResource({{paramName}}){{/isFile}}{{^isFile}}{{paramName}}{{/isFile}});
|
||||
{{/formParams}}
|
||||
{{/hasFormParams}}
|
||||
|
||||
final String[] accepts = { {{#hasProduces}}
|
||||
final String[] localVarAccepts = { {{#hasProduces}}
|
||||
{{#produces}}"{{{mediaType}}}"{{#hasMore}}, {{/hasMore}}{{/produces}}
|
||||
{{/hasProduces}}};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { {{#hasConsumes}}
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { {{#hasConsumes}}
|
||||
{{#consumes}}"{{{mediaType}}}"{{#hasMore}}, {{/hasMore}}{{/consumes}}
|
||||
{{/hasConsumes}}};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { {{#authMethods}}"{{name}}"{{#hasMore}}, {{/hasMore}}{{/authMethods}} };
|
||||
String[] localVarAuthNames = new String[] { {{#authMethods}}"{{name}}"{{#hasMore}}, {{/hasMore}}{{/authMethods}} };
|
||||
|
||||
{{#returnType}}ParameterizedTypeReference<{{#isListContainer}}{{{returnBaseType}}}{{/isListContainer}}{{^isListContainer}}{{{returnType}}}{{/isListContainer}}> returnType = new ParameterizedTypeReference<{{#isListContainer}}{{{returnBaseType}}}{{/isListContainer}}{{^isListContainer}}{{{returnType}}}{{/isListContainer}}>() {};{{/returnType}}{{^returnType}}ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};{{/returnType}}
|
||||
return apiClient.{{#isListContainer}}invokeFluxAPI{{/isListContainer}}{{^isListContainer}}invokeAPI{{/isListContainer}}("{{{path}}}", HttpMethod.{{httpMethod}}, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
{{#returnType}}ParameterizedTypeReference<{{#isListContainer}}{{{returnBaseType}}}{{/isListContainer}}{{^isListContainer}}{{{returnType}}}{{/isListContainer}}> localVarReturnType = new ParameterizedTypeReference<{{#isListContainer}}{{{returnBaseType}}}{{/isListContainer}}{{^isListContainer}}{{{returnType}}}{{/isListContainer}}>() {};{{/returnType}}{{^returnType}}ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};{{/returnType}}
|
||||
return apiClient.{{#isListContainer}}invokeFluxAPI{{/isListContainer}}{{^isListContainer}}invokeAPI{{/isListContainer}}("{{{path}}}", HttpMethod.{{httpMethod}}, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
{{/operation}}
|
||||
}
|
||||
|
||||
@@ -551,7 +551,7 @@ public class ApiClient {
|
||||
updateParamsForAuth(authNames, queryParams, headerParams, cookieParams);
|
||||
|
||||
final UriComponentsBuilder builder = UriComponentsBuilder.fromHttpUrl(basePath).path(path);
|
||||
if (queryParams != null) {
|
||||
if (queryParams != null) {
|
||||
builder.queryParams(queryParams);
|
||||
}
|
||||
|
||||
|
||||
@@ -55,33 +55,30 @@ public class AnotherFakeApi {
|
||||
*/
|
||||
public Mono<Client> call123testSpecialTags(Client body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling call123testSpecialTags");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Client> returnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/another-fake/dummy", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Client> localVarReturnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/another-fake/dummy", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,32 +62,29 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> createXmlItem(XmlItem xmlItem) throws RestClientException {
|
||||
Object postBody = xmlItem;
|
||||
|
||||
// verify the required parameter 'xmlItem' is set
|
||||
if (xmlItem == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'xmlItem' when calling createXmlItem");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/xml", "application/xml; charset=utf-8", "application/xml; charset=utf-16", "text/xml", "text/xml; charset=utf-8", "text/xml; charset=utf-16"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/create_xml_item", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/create_xml_item", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -99,27 +96,25 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Boolean> fakeOuterBooleanSerialize(Boolean body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"*/*"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Boolean> returnType = new ParameterizedTypeReference<Boolean>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/boolean", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Boolean> localVarReturnType = new ParameterizedTypeReference<Boolean>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/boolean", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -131,27 +126,25 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<OuterComposite> fakeOuterCompositeSerialize(OuterComposite body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"*/*"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<OuterComposite> returnType = new ParameterizedTypeReference<OuterComposite>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/composite", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<OuterComposite> localVarReturnType = new ParameterizedTypeReference<OuterComposite>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/composite", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -163,27 +156,25 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<BigDecimal> fakeOuterNumberSerialize(BigDecimal body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"*/*"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<BigDecimal> returnType = new ParameterizedTypeReference<BigDecimal>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/number", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<BigDecimal> localVarReturnType = new ParameterizedTypeReference<BigDecimal>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/number", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -195,27 +186,25 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<String> fakeOuterStringSerialize(String body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"*/*"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<String> returnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/string", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<String> localVarReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/fake/outer/string", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -226,32 +215,29 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testBodyWithFileSchema(FileSchemaTestClass body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling testBodyWithFileSchema");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/body-with-file-schema", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/body-with-file-schema", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -263,21 +249,17 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testBodyWithQueryParams(String query, User body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'query' is set
|
||||
if (query == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'query' when calling testBodyWithQueryParams");
|
||||
}
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling testBodyWithQueryParams");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -285,17 +267,17 @@ public class FakeApi {
|
||||
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(null, "query", query));
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/body-with-query-params", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/body-with-query-params", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* To test \"client\" model
|
||||
@@ -307,34 +289,31 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Client> testClientModel(Client body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling testClientModel");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Client> returnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Client> localVarReturnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
@@ -359,31 +338,25 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testEndpointParameters(BigDecimal number, Double _double, String patternWithoutDelimiter, byte[] _byte, Integer integer, Integer int32, Long int64, Float _float, String string, File binary, LocalDate date, OffsetDateTime dateTime, String password, String paramCallback) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'number' is set
|
||||
if (number == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'number' when calling testEndpointParameters");
|
||||
}
|
||||
|
||||
// verify the required parameter '_double' is set
|
||||
if (_double == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter '_double' when calling testEndpointParameters");
|
||||
}
|
||||
|
||||
// verify the required parameter 'patternWithoutDelimiter' is set
|
||||
if (patternWithoutDelimiter == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'patternWithoutDelimiter' when calling testEndpointParameters");
|
||||
}
|
||||
|
||||
// verify the required parameter '_byte' is set
|
||||
if (_byte == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter '_byte' when calling testEndpointParameters");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -418,17 +391,17 @@ public class FakeApi {
|
||||
if (paramCallback != null)
|
||||
formParams.add("callback", paramCallback);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "http_basic_test" };
|
||||
String[] localVarAuthNames = new String[] { "http_basic_test" };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* To test enum parameters
|
||||
@@ -447,11 +420,9 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testEnumParameters(List<String> enumHeaderStringArray, String enumHeaderString, List<String> enumQueryStringArray, String enumQueryString, Integer enumQueryInteger, Double enumQueryDouble, List<String> enumFormStringArray, String enumFormString) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -466,23 +437,22 @@ public class FakeApi {
|
||||
headerParams.add("enum_header_string_array", apiClient.parameterToString(enumHeaderStringArray));
|
||||
if (enumHeaderString != null)
|
||||
headerParams.add("enum_header_string", apiClient.parameterToString(enumHeaderString));
|
||||
|
||||
if (enumFormStringArray != null)
|
||||
formParams.addAll("enum_form_string_array", enumFormStringArray);
|
||||
if (enumFormString != null)
|
||||
formParams.add("enum_form_string", enumFormString);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Fake endpoint to test group parameters (optional)
|
||||
@@ -498,26 +468,21 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testGroupParameters(Integer requiredStringGroup, Boolean requiredBooleanGroup, Long requiredInt64Group, Integer stringGroup, Boolean booleanGroup, Long int64Group) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'requiredStringGroup' is set
|
||||
if (requiredStringGroup == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'requiredStringGroup' when calling testGroupParameters");
|
||||
}
|
||||
|
||||
// verify the required parameter 'requiredBooleanGroup' is set
|
||||
if (requiredBooleanGroup == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'requiredBooleanGroup' when calling testGroupParameters");
|
||||
}
|
||||
|
||||
// verify the required parameter 'requiredInt64Group' is set
|
||||
if (requiredInt64Group == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'requiredInt64Group' when calling testGroupParameters");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -532,16 +497,15 @@ public class FakeApi {
|
||||
headerParams.add("required_boolean_group", apiClient.parameterToString(requiredBooleanGroup));
|
||||
if (booleanGroup != null)
|
||||
headerParams.add("boolean_group", apiClient.parameterToString(booleanGroup));
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* test inline additionalProperties
|
||||
@@ -552,32 +516,29 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testInlineAdditionalProperties(Map<String, String> param) throws RestClientException {
|
||||
Object postBody = param;
|
||||
|
||||
// verify the required parameter 'param' is set
|
||||
if (param == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'param' when calling testInlineAdditionalProperties");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/inline-additionalProperties", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/inline-additionalProperties", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* test json serialization of form data
|
||||
@@ -589,21 +550,17 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testJsonFormData(String param, String param2) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'param' is set
|
||||
if (param == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'param' when calling testJsonFormData");
|
||||
}
|
||||
|
||||
// verify the required parameter 'param2' is set
|
||||
if (param2 == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'param2' when calling testJsonFormData");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -614,17 +571,17 @@ public class FakeApi {
|
||||
if (param2 != null)
|
||||
formParams.add("param2", param2);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/jsonFormData", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/jsonFormData", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
*
|
||||
@@ -639,36 +596,29 @@ public class FakeApi {
|
||||
*/
|
||||
public Mono<Void> testQueryParameterCollectionFormat(List<String> pipe, List<String> ioutil, List<String> http, List<String> url, List<String> context) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'pipe' is set
|
||||
if (pipe == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'pipe' when calling testQueryParameterCollectionFormat");
|
||||
}
|
||||
|
||||
// verify the required parameter 'ioutil' is set
|
||||
if (ioutil == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'ioutil' when calling testQueryParameterCollectionFormat");
|
||||
}
|
||||
|
||||
// verify the required parameter 'http' is set
|
||||
if (http == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'http' when calling testQueryParameterCollectionFormat");
|
||||
}
|
||||
|
||||
// verify the required parameter 'url' is set
|
||||
if (url == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'url' when calling testQueryParameterCollectionFormat");
|
||||
}
|
||||
|
||||
// verify the required parameter 'context' is set
|
||||
if (context == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'context' when calling testQueryParameterCollectionFormat");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -680,14 +630,14 @@ public class FakeApi {
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(ApiClient.CollectionFormat.valueOf("csv".toUpperCase(Locale.ROOT)), "url", url));
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(ApiClient.CollectionFormat.valueOf("multi".toUpperCase(Locale.ROOT)), "context", context));
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/test-query-paramters", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/fake/test-query-paramters", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,33 +55,30 @@ public class FakeClassnameTags123Api {
|
||||
*/
|
||||
public Mono<Client> testClassname(Client body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling testClassname");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "api_key_query" };
|
||||
String[] localVarAuthNames = new String[] { "api_key_query" };
|
||||
|
||||
ParameterizedTypeReference<Client> returnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/fake_classname_test", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Client> localVarReturnType = new ParameterizedTypeReference<Client>() {};
|
||||
return apiClient.invokeAPI("/fake_classname_test", HttpMethod.PATCH, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,32 +57,29 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<Void> addPet(Pet body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling addPet");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json", "application/xml"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Deletes a pet
|
||||
@@ -95,16 +92,14 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<Void> deletePet(Long petId, String apiKey) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'petId' when calling deletePet");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
@@ -113,16 +108,15 @@ public class PetApi {
|
||||
|
||||
if (apiKey != null)
|
||||
headerParams.add("api_key", apiClient.parameterToString(apiKey));
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Finds Pets by status
|
||||
@@ -135,16 +129,13 @@ public class PetApi {
|
||||
*/
|
||||
public Flux<Pet> findPetsByStatus(List<String> status) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'status' is set
|
||||
if (status == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'status' when calling findPetsByStatus");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -152,17 +143,17 @@ public class PetApi {
|
||||
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(ApiClient.CollectionFormat.valueOf("csv".toUpperCase(Locale.ROOT)), "status", status));
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Pet> returnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeFluxAPI("/pet/findByStatus", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Pet> localVarReturnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeFluxAPI("/pet/findByStatus", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Finds Pets by tags
|
||||
@@ -175,16 +166,13 @@ public class PetApi {
|
||||
*/
|
||||
public Flux<Pet> findPetsByTags(List<String> tags) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'tags' is set
|
||||
if (tags == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'tags' when calling findPetsByTags");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -192,17 +180,17 @@ public class PetApi {
|
||||
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(ApiClient.CollectionFormat.valueOf("csv".toUpperCase(Locale.ROOT)), "tags", tags));
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Pet> returnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeFluxAPI("/pet/findByTags", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Pet> localVarReturnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeFluxAPI("/pet/findByTags", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Find pet by ID
|
||||
@@ -216,33 +204,31 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<Pet> getPetById(Long petId) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'petId' when calling getPetById");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "api_key" };
|
||||
String[] localVarAuthNames = new String[] { "api_key" };
|
||||
|
||||
ParameterizedTypeReference<Pet> returnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Pet> localVarReturnType = new ParameterizedTypeReference<Pet>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Update an existing pet
|
||||
@@ -256,32 +242,29 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<Void> updatePet(Pet body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling updatePet");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/json", "application/xml"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Updates a pet in the store with form data
|
||||
@@ -294,16 +277,14 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<Void> updatePetWithForm(Long petId, String name, String status) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'petId' when calling updatePetWithForm");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
@@ -315,17 +296,17 @@ public class PetApi {
|
||||
if (status != null)
|
||||
formParams.add("status", status);
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"application/x-www-form-urlencoded"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
@@ -339,16 +320,14 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<ModelApiResponse> uploadFile(Long petId, String additionalMetadata, File file) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'petId' when calling uploadFile");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
@@ -360,19 +339,19 @@ public class PetApi {
|
||||
if (file != null)
|
||||
formParams.add("file", new FileSystemResource(file));
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"multipart/form-data"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<ModelApiResponse> returnType = new ParameterizedTypeReference<ModelApiResponse>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}/uploadImage", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<ModelApiResponse> localVarReturnType = new ParameterizedTypeReference<ModelApiResponse>() {};
|
||||
return apiClient.invokeAPI("/pet/{petId}/uploadImage", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image (required)
|
||||
@@ -386,21 +365,18 @@ public class PetApi {
|
||||
*/
|
||||
public Mono<ModelApiResponse> uploadFileWithRequiredFile(Long petId, File requiredFile, String additionalMetadata) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'petId' is set
|
||||
if (petId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'petId' when calling uploadFileWithRequiredFile");
|
||||
}
|
||||
|
||||
// verify the required parameter 'requiredFile' is set
|
||||
if (requiredFile == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'requiredFile' when calling uploadFileWithRequiredFile");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
pathParams.put("petId", petId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
@@ -412,18 +388,18 @@ public class PetApi {
|
||||
if (requiredFile != null)
|
||||
formParams.add("requiredFile", new FileSystemResource(requiredFile));
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = {
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = {
|
||||
"multipart/form-data"
|
||||
};
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "petstore_auth" };
|
||||
String[] localVarAuthNames = new String[] { "petstore_auth" };
|
||||
|
||||
ParameterizedTypeReference<ModelApiResponse> returnType = new ParameterizedTypeReference<ModelApiResponse>() {};
|
||||
return apiClient.invokeAPI("/fake/{petId}/uploadImageWithRequiredFile", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<ModelApiResponse> localVarReturnType = new ParameterizedTypeReference<ModelApiResponse>() {};
|
||||
return apiClient.invokeAPI("/fake/{petId}/uploadImageWithRequiredFile", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,31 +55,29 @@ public class StoreApi {
|
||||
*/
|
||||
public Mono<Void> deleteOrder(String orderId) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'orderId' when calling deleteOrder");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("order_id", orderId);
|
||||
|
||||
pathParams.put("order_id", orderId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/store/order/{order_id}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/store/order/{order_id}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Returns pet inventories by status
|
||||
@@ -90,27 +88,25 @@ public class StoreApi {
|
||||
*/
|
||||
public Mono<Map<String, Integer>> getInventory() throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { "api_key" };
|
||||
String[] localVarAuthNames = new String[] { "api_key" };
|
||||
|
||||
ParameterizedTypeReference<Map<String, Integer>> returnType = new ParameterizedTypeReference<Map<String, Integer>>() {};
|
||||
return apiClient.invokeAPI("/store/inventory", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Map<String, Integer>> localVarReturnType = new ParameterizedTypeReference<Map<String, Integer>>() {};
|
||||
return apiClient.invokeAPI("/store/inventory", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Find purchase order by ID
|
||||
@@ -124,33 +120,31 @@ public class StoreApi {
|
||||
*/
|
||||
public Mono<Order> getOrderById(Long orderId) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'orderId' is set
|
||||
if (orderId == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'orderId' when calling getOrderById");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("order_id", orderId);
|
||||
|
||||
pathParams.put("order_id", orderId);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Order> returnType = new ParameterizedTypeReference<Order>() {};
|
||||
return apiClient.invokeAPI("/store/order/{order_id}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Order> localVarReturnType = new ParameterizedTypeReference<Order>() {};
|
||||
return apiClient.invokeAPI("/store/order/{order_id}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Place an order for a pet
|
||||
@@ -163,31 +157,28 @@ public class StoreApi {
|
||||
*/
|
||||
public Mono<Order> placeOrder(Order body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling placeOrder");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Order> returnType = new ParameterizedTypeReference<Order>() {};
|
||||
return apiClient.invokeAPI("/store/order", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Order> localVarReturnType = new ParameterizedTypeReference<Order>() {};
|
||||
return apiClient.invokeAPI("/store/order", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,30 +54,27 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> createUser(User body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling createUser");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Creates list of users with given input array
|
||||
@@ -88,30 +85,27 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> createUsersWithArrayInput(List<User> body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling createUsersWithArrayInput");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/createWithArray", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/createWithArray", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Creates list of users with given input array
|
||||
@@ -122,30 +116,27 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> createUsersWithListInput(List<User> body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling createUsersWithListInput");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/createWithList", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/createWithList", HttpMethod.POST, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Delete user
|
||||
@@ -157,31 +148,29 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> deleteUser(String username) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'username' when calling deleteUser");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("username", username);
|
||||
|
||||
pathParams.put("username", username);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.DELETE, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Get user by user name
|
||||
@@ -195,33 +184,31 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<User> getUserByName(String username) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'username' when calling getUserByName");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("username", username);
|
||||
|
||||
pathParams.put("username", username);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<User> returnType = new ParameterizedTypeReference<User>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<User> localVarReturnType = new ParameterizedTypeReference<User>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Logs user into the system
|
||||
@@ -235,21 +222,17 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<String> loginUser(String username, String password) throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'username' when calling loginUser");
|
||||
}
|
||||
|
||||
// verify the required parameter 'password' is set
|
||||
if (password == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'password' when calling loginUser");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
@@ -258,17 +241,17 @@ public class UserApi {
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(null, "username", username));
|
||||
queryParams.putAll(apiClient.parameterToMultiValueMap(null, "password", password));
|
||||
|
||||
final String[] accepts = {
|
||||
final String[] localVarAccepts = {
|
||||
"application/xml", "application/json"
|
||||
};
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<String> returnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/user/login", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<String> localVarReturnType = new ParameterizedTypeReference<String>() {};
|
||||
return apiClient.invokeAPI("/user/login", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Logs out current logged in user session
|
||||
@@ -278,25 +261,23 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> logoutUser() throws RestClientException {
|
||||
Object postBody = null;
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/logout", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/logout", HttpMethod.GET, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* Updated user
|
||||
@@ -309,35 +290,32 @@ public class UserApi {
|
||||
*/
|
||||
public Mono<Void> updateUser(String username, User body) throws RestClientException {
|
||||
Object postBody = body;
|
||||
|
||||
// verify the required parameter 'username' is set
|
||||
if (username == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'username' when calling updateUser");
|
||||
}
|
||||
|
||||
// verify the required parameter 'body' is set
|
||||
if (body == null) {
|
||||
throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'body' when calling updateUser");
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
final Map<String, Object> pathParams = new HashMap<String, Object>();
|
||||
pathParams.put("username", username);
|
||||
|
||||
pathParams.put("username", username);
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
final MultiValueMap<String, String> cookieParams = new LinkedMultiValueMap<String, String>();
|
||||
final MultiValueMap<String, Object> formParams = new LinkedMultiValueMap<String, Object>();
|
||||
|
||||
final String[] accepts = { };
|
||||
final List<MediaType> accept = apiClient.selectHeaderAccept(accepts);
|
||||
final String[] contentTypes = { };
|
||||
final MediaType contentType = apiClient.selectHeaderContentType(contentTypes);
|
||||
final String[] localVarAccepts = { };
|
||||
final List<MediaType> localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
|
||||
final String[] localVarContentTypes = { };
|
||||
final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
|
||||
|
||||
String[] authNames = new String[] { };
|
||||
String[] localVarAuthNames = new String[] { };
|
||||
|
||||
ParameterizedTypeReference<Void> returnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, accept, contentType, authNames, returnType);
|
||||
ParameterizedTypeReference<Void> localVarReturnType = new ParameterizedTypeReference<Void>() {};
|
||||
return apiClient.invokeAPI("/user/{username}", HttpMethod.PUT, pathParams, queryParams, postBody, headerParams, cookieParams, formParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user