mirror of
https://github.com/jlengrand/openapi-generator.git
synced 2026-03-10 08:31:23 +00:00
* [Java] Fixed bug in native client generation when API accepts array of files (#16055) * Adding test for java native client * Updated samples
This commit is contained in:
@@ -427,6 +427,27 @@ paths:
|
||||
tags:
|
||||
- body
|
||||
x-accepts: image/gif
|
||||
/body/application/octetstream/array_of_binary:
|
||||
post:
|
||||
description: Test array of binary in multipart mime
|
||||
operationId: test/body/multipart/formdata/array_of_binary
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
$ref: '#/components/schemas/test_body_multipart_formdata_array_of_binary_request'
|
||||
responses:
|
||||
"200":
|
||||
content:
|
||||
text/plain:
|
||||
schema:
|
||||
type: string
|
||||
description: Successful operation
|
||||
summary: Test array of binary in multipart mime
|
||||
tags:
|
||||
- body
|
||||
x-content-type: multipart/form-data
|
||||
x-accepts: text/plain
|
||||
components:
|
||||
requestBodies:
|
||||
Pet:
|
||||
@@ -657,4 +678,14 @@ components:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/Bird'
|
||||
- $ref: '#/components/schemas/Category'
|
||||
test_body_multipart_formdata_array_of_binary_request:
|
||||
properties:
|
||||
files:
|
||||
items:
|
||||
format: binary
|
||||
type: string
|
||||
type: array
|
||||
required:
|
||||
- files
|
||||
type: object
|
||||
|
||||
|
||||
@@ -72,6 +72,35 @@ public interface BodyApi extends ApiClient.Api {
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Test array of binary in multipart mime
|
||||
* Test array of binary in multipart mime
|
||||
* @param files (required)
|
||||
* @return String
|
||||
*/
|
||||
@RequestLine("POST /body/application/octetstream/array_of_binary")
|
||||
@Headers({
|
||||
"Content-Type: multipart/form-data",
|
||||
"Accept: text/plain",
|
||||
})
|
||||
String testBodyMultipartFormdataArrayOfBinary(@Param("files") List<File> files);
|
||||
|
||||
/**
|
||||
* Test array of binary in multipart mime
|
||||
* Similar to <code>testBodyMultipartFormdataArrayOfBinary</code> but it also returns the http response headers .
|
||||
* Test array of binary in multipart mime
|
||||
* @param files (required)
|
||||
* @return A ApiResponse that wraps the response boyd and the http headers.
|
||||
*/
|
||||
@RequestLine("POST /body/application/octetstream/array_of_binary")
|
||||
@Headers({
|
||||
"Content-Type: multipart/form-data",
|
||||
"Accept: text/plain",
|
||||
})
|
||||
ApiResponse<String> testBodyMultipartFormdataArrayOfBinaryWithHttpInfo(@Param("files") List<File> files);
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Test free form object
|
||||
* Test free form object
|
||||
|
||||
Reference in New Issue
Block a user