forked from loafle/openapi-generator-original
Merge remote-tracking branch 'origin/master' into 3.4.x
This commit is contained in:
@@ -13,6 +13,7 @@ Method | HTTP request | Description
|
||||
[**testClientModel**](FakeApi.md#testClientModel) | **PATCH** /fake | To test \"client\" model
|
||||
[**testEndpointParameters**](FakeApi.md#testEndpointParameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
[**testEnumParameters**](FakeApi.md#testEnumParameters) | **GET** /fake | To test enum parameters
|
||||
[**testGroupParameters**](FakeApi.md#testGroupParameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional)
|
||||
[**testInlineAdditionalProperties**](FakeApi.md#testInlineAdditionalProperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties
|
||||
[**testJsonFormData**](FakeApi.md#testJsonFormData) | **GET** /fake/jsonFormData | test json serialization of form data
|
||||
|
||||
@@ -467,6 +468,54 @@ No authorization required
|
||||
- **Content-Type**: application/x-www-form-urlencoded
|
||||
- **Accept**: Not defined
|
||||
|
||||
<a name="testGroupParameters"></a>
|
||||
# **testGroupParameters**
|
||||
> testGroupParameters(stringGroup, booleanGroup, int64Group)
|
||||
|
||||
Fake endpoint to test group parameters (optional)
|
||||
|
||||
Fake endpoint to test group parameters (optional)
|
||||
|
||||
### Example
|
||||
```java
|
||||
// Import classes:
|
||||
//import org.openapitools.client.ApiException;
|
||||
//import org.openapitools.client.api.FakeApi;
|
||||
|
||||
|
||||
FakeApi apiInstance = new FakeApi();
|
||||
Integer stringGroup = 56; // Integer | String in group parameters
|
||||
Boolean booleanGroup = true; // Boolean | Boolean in group parameters
|
||||
Long int64Group = 56L; // Long | Integer in group parameters
|
||||
try {
|
||||
apiInstance.testGroupParameters(stringGroup, booleanGroup, int64Group);
|
||||
} catch (ApiException e) {
|
||||
System.err.println("Exception when calling FakeApi#testGroupParameters");
|
||||
e.printStackTrace();
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**stringGroup** | **Integer**| String in group parameters | [optional]
|
||||
**booleanGroup** | **Boolean**| Boolean in group parameters | [optional]
|
||||
**int64Group** | **Long**| Integer in group parameters | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
null (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
<a name="testInlineAdditionalProperties"></a>
|
||||
# **testInlineAdditionalProperties**
|
||||
> testInlineAdditionalProperties(requestBody)
|
||||
|
||||
@@ -879,6 +879,92 @@ public class FakeApi {
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Fake endpoint to test group parameters (optional)
|
||||
* Fake endpoint to test group parameters (optional)
|
||||
* <p><b>400</b> - Someting wrong
|
||||
* @param stringGroup String in group parameters
|
||||
* @param booleanGroup Boolean in group parameters
|
||||
* @param int64Group Integer in group parameters
|
||||
* @throws IOException if an error occurs while attempting to invoke the API
|
||||
**/
|
||||
public void testGroupParameters(Integer stringGroup, Boolean booleanGroup, Long int64Group) throws IOException {
|
||||
testGroupParametersForHttpResponse(stringGroup, booleanGroup, int64Group);
|
||||
}
|
||||
|
||||
/**
|
||||
* Fake endpoint to test group parameters (optional)
|
||||
* Fake endpoint to test group parameters (optional)
|
||||
* <p><b>400</b> - Someting wrong
|
||||
* @param params Map of query params. A collection will be interpreted as passing in multiple instances of the same query param.
|
||||
* @throws IOException if an error occurs while attempting to invoke the API
|
||||
**/
|
||||
public void testGroupParameters(Map<String, Object> params) throws IOException {
|
||||
testGroupParametersForHttpResponse(params);
|
||||
}
|
||||
|
||||
public HttpResponse testGroupParametersForHttpResponse(Integer stringGroup, Boolean booleanGroup, Long int64Group) throws IOException {
|
||||
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/fake");
|
||||
if (stringGroup != null) {
|
||||
String key = "string_group";
|
||||
Object value = stringGroup;
|
||||
if (value instanceof Collection) {
|
||||
uriBuilder = uriBuilder.queryParam(key, ((Collection) value).toArray());
|
||||
} else if (value instanceof Object[]) {
|
||||
uriBuilder = uriBuilder.queryParam(key, (Object[]) value);
|
||||
} else {
|
||||
uriBuilder = uriBuilder.queryParam(key, value);
|
||||
}
|
||||
} if (int64Group != null) {
|
||||
String key = "int64_group";
|
||||
Object value = int64Group;
|
||||
if (value instanceof Collection) {
|
||||
uriBuilder = uriBuilder.queryParam(key, ((Collection) value).toArray());
|
||||
} else if (value instanceof Object[]) {
|
||||
uriBuilder = uriBuilder.queryParam(key, (Object[]) value);
|
||||
} else {
|
||||
uriBuilder = uriBuilder.queryParam(key, value);
|
||||
}
|
||||
}
|
||||
|
||||
String url = uriBuilder.build().toString();
|
||||
GenericUrl genericUrl = new GenericUrl(url);
|
||||
|
||||
HttpContent content = null;
|
||||
return apiClient.getHttpRequestFactory().buildRequest(HttpMethods.DELETE, genericUrl, content).execute();
|
||||
}
|
||||
|
||||
public HttpResponse testGroupParametersForHttpResponse(Map<String, Object> params) throws IOException {
|
||||
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/fake");
|
||||
|
||||
// Copy the params argument if present, to allow passing in immutable maps
|
||||
Map<String, Object> allParams = params == null ? new HashMap<String, Object>() : new HashMap<String, Object>(params);
|
||||
|
||||
for (Map.Entry<String, Object> entry: allParams.entrySet()) {
|
||||
String key = entry.getKey();
|
||||
Object value = entry.getValue();
|
||||
|
||||
if (key != null && value != null) {
|
||||
if (value instanceof Collection) {
|
||||
uriBuilder = uriBuilder.queryParam(key, ((Collection) value).toArray());
|
||||
} else if (value instanceof Object[]) {
|
||||
uriBuilder = uriBuilder.queryParam(key, (Object[]) value);
|
||||
} else {
|
||||
uriBuilder = uriBuilder.queryParam(key, value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
String url = uriBuilder.build().toString();
|
||||
GenericUrl genericUrl = new GenericUrl(url);
|
||||
|
||||
HttpContent content = null;
|
||||
return apiClient.getHttpRequestFactory().buildRequest(HttpMethods.DELETE, genericUrl, content).execute();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* test inline additionalProperties
|
||||
* <p><b>200</b> - successful operation
|
||||
|
||||
Reference in New Issue
Block a user