[kotlin] better oneOf, anyOf support (#18382)

* add validteJsonElement

* add oneOf support

* various fixes, add tests

* minor fixes

* minor fixes

* update data class

* remove comments

* array support, add test

* update api client constructor

* add anyOf support

* add new files

* fix merge

* update

* update

* update

* update
This commit is contained in:
William Cheng
2024-05-31 12:22:27 +08:00
committed by GitHub
parent 1c7e5c4726
commit 353320cb04
648 changed files with 8996 additions and 6249 deletions

View File

@@ -2,16 +2,16 @@
All URIs are relative to *http://petstore.swagger.io/v2*
Method | HTTP request | Description
------------- | ------------- | -------------
[**createUser**](UserApi.md#createUser) | **POST** user | Create user
[**createUsersWithArrayInput**](UserApi.md#createUsersWithArrayInput) | **POST** user/createWithArray | Creates list of users with given input array
[**createUsersWithListInput**](UserApi.md#createUsersWithListInput) | **POST** user/createWithList | Creates list of users with given input array
[**deleteUser**](UserApi.md#deleteUser) | **DELETE** user/{username} | Delete user
[**getUserByName**](UserApi.md#getUserByName) | **GET** user/{username} | Get user by user name
[**loginUser**](UserApi.md#loginUser) | **GET** user/login | Logs user into the system
[**logoutUser**](UserApi.md#logoutUser) | **GET** user/logout | Logs out current logged in user session
[**updateUser**](UserApi.md#updateUser) | **PUT** user/{username} | Updated user
| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**createUser**](UserApi.md#createUser) | **POST** user | Create user |
| [**createUsersWithArrayInput**](UserApi.md#createUsersWithArrayInput) | **POST** user/createWithArray | Creates list of users with given input array |
| [**createUsersWithListInput**](UserApi.md#createUsersWithListInput) | **POST** user/createWithList | Creates list of users with given input array |
| [**deleteUser**](UserApi.md#deleteUser) | **DELETE** user/{username} | Delete user |
| [**getUserByName**](UserApi.md#getUserByName) | **GET** user/{username} | Get user by user name |
| [**loginUser**](UserApi.md#loginUser) | **GET** user/login | Logs user into the system |
| [**logoutUser**](UserApi.md#logoutUser) | **GET** user/logout | Logs out current logged in user session |
| [**updateUser**](UserApi.md#updateUser) | **PUT** user/{username} | Updated user |
@@ -34,10 +34,9 @@ webService.createUser(user)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**User**](User.md)| Created user object |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **user** | [**User**](User.md)| Created user object | |
### Return type
@@ -72,10 +71,9 @@ webService.createUsersWithArrayInput(user)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**kotlin.collections.List<User>**](User.md)| List of user object |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **user** | [**kotlin.collections.List<User>**](User.md)| List of user object | |
### Return type
@@ -110,10 +108,9 @@ webService.createUsersWithListInput(user)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**kotlin.collections.List<User>**](User.md)| List of user object |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **user** | [**kotlin.collections.List<User>**](User.md)| List of user object | |
### Return type
@@ -148,10 +145,9 @@ webService.deleteUser(username)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **kotlin.String**| The name that needs to be deleted |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **username** | **kotlin.String**| The name that needs to be deleted | |
### Return type
@@ -186,10 +182,9 @@ val result : User = webService.getUserByName(username)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **kotlin.String**| The name that needs to be fetched. Use user1 for testing. |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **username** | **kotlin.String**| The name that needs to be fetched. Use user1 for testing. | |
### Return type
@@ -225,11 +220,10 @@ val result : kotlin.String = webService.loginUser(username, password)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **kotlin.String**| The user name for login |
**password** | **kotlin.String**| The password for login in clear text |
| **username** | **kotlin.String**| The user name for login | |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **password** | **kotlin.String**| The password for login in clear text | |
### Return type
@@ -299,11 +293,10 @@ webService.updateUser(username, user)
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **kotlin.String**| name that need to be deleted |
**user** | [**User**](User.md)| Updated user object |
| **username** | **kotlin.String**| name that need to be deleted | |
| Name | Type | Description | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **user** | [**User**](User.md)| Updated user object | |
### Return type