mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-08 06:36:10 +00:00
[Spring] fix deprecated generation (#12832)
This commit is contained in:
@@ -134,6 +134,9 @@ public interface {{classname}} {
|
||||
* @see <a href="{{url}}">{{summary}} Documentation</a>
|
||||
{{/externalDocs}}
|
||||
*/
|
||||
{{#isDeprecated}}
|
||||
@Deprecated
|
||||
{{/isDeprecated}}
|
||||
{{#virtualService}}
|
||||
@ApiVirtual
|
||||
{{/virtualService}}
|
||||
|
||||
@@ -115,6 +115,9 @@ public class {{classname}}Controller implements {{classname}} {
|
||||
{{/externalDocs}}
|
||||
* @see {{classname}}#{{operationId}}
|
||||
*/
|
||||
{{#isDeprecated}}
|
||||
@Deprecated
|
||||
{{/isDeprecated}}
|
||||
public {{#responseWrapper}}{{.}}<{{/responseWrapper}}ResponseEntity<{{>returnTypes}}>{{#responseWrapper}}>{{/responseWrapper}} {{operationId}}(
|
||||
{{#allParams}}{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>bodyParams}}{{>formParams}}{{>cookieParams}}{{^-last}},
|
||||
{{/-last}}{{/allParams}}{{#vendorExtensions.x-spring-paginated}}{{#hasParams}},
|
||||
|
||||
@@ -62,6 +62,9 @@ public interface {{classname}}Delegate {
|
||||
{{/externalDocs}}
|
||||
* @see {{classname}}#{{operationId}}
|
||||
*/
|
||||
{{#isDeprecated}}
|
||||
@Deprecated
|
||||
{{/isDeprecated}}
|
||||
{{#jdk8-default-interface}}default {{/jdk8-default-interface}}{{#responseWrapper}}{{.}}<{{/responseWrapper}}ResponseEntity<{{>returnTypes}}>{{#responseWrapper}}>{{/responseWrapper}} {{operationId}}({{#allParams}}{{^isFile}}{{^isBodyParam}}{{>optionalDataType}}{{/isBodyParam}}{{#isBodyParam}}{{^reactive}}{{{dataType}}}{{/reactive}}{{#reactive}}{{^isArray}}Mono<{{{dataType}}}>{{/isArray}}{{#isArray}}Flux<{{{baseType}}}>{{/isArray}}{{/reactive}}{{/isBodyParam}}{{/isFile}}{{#isFile}}{{#isArray}}List<{{/isArray}}{{#reactive}}Flux<Part>{{/reactive}}{{^reactive}}MultipartFile{{/reactive}}{{#isArray}}>{{/isArray}}{{/isFile}} {{paramName}}{{^-last}},
|
||||
{{/-last}}{{/allParams}}{{#reactive}}{{#hasParams}},
|
||||
{{/hasParams}}ServerWebExchange exchange{{/reactive}}{{#vendorExtensions.x-spring-paginated}}, final Pageable pageable{{/vendorExtensions.x-spring-paginated}}){{#unhandledException}} throws Exception{{/unhandledException}}{{^jdk8-default-interface}};{{/jdk8-default-interface}}{{#jdk8-default-interface}} {
|
||||
|
||||
@@ -137,6 +137,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -141,6 +141,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -139,6 +139,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -141,6 +141,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -163,6 +163,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -140,6 +140,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -133,6 +133,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -137,6 +137,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -135,6 +135,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -140,6 +140,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -132,6 +132,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -159,6 +159,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -181,6 +181,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -181,6 +181,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -164,6 +164,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -143,6 +143,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -91,6 +91,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default ResponseEntity<Set<Pet>> findPetsByTags(Set<String> tags) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -165,6 +165,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -150,6 +150,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -102,6 +102,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default Mono<ResponseEntity<Flux<Pet>>> findPetsByTags(Set<String> tags,
|
||||
ServerWebExchange exchange) {
|
||||
Mono<Void> result = Mono.empty();
|
||||
|
||||
@@ -131,6 +131,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/pet/findByTags",
|
||||
|
||||
@@ -164,6 +164,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -181,6 +181,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -137,6 +137,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
|
||||
@@ -168,6 +168,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -168,6 +168,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -147,6 +147,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -91,6 +91,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default ResponseEntity<Set<Pet>> findPetsByTags(Set<String> tags) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -147,6 +147,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -91,6 +91,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default ResponseEntity<Set<Pet>> findPetsByTags(Set<String> tags) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -169,6 +169,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -155,6 +155,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -103,6 +103,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default Mono<ResponseEntity<Flux<Pet>>> findPetsByTags(Set<String> tags,
|
||||
ServerWebExchange exchange) {
|
||||
Mono<Void> result = Mono.empty();
|
||||
|
||||
@@ -149,6 +149,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -92,6 +92,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default ResponseEntity<List<Pet>> findPetsByTags(List<String> tags, final Pageable pageable) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -149,6 +149,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -92,6 +92,7 @@ public interface PetApiDelegate {
|
||||
* @deprecated
|
||||
* @see PetApi#findPetsByTags
|
||||
*/
|
||||
@Deprecated
|
||||
default ResponseEntity<List<Pet>> findPetsByTags(List<String> tags, final Pageable pageable) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -170,6 +170,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -170,6 +170,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -168,6 +168,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
@@ -170,6 +170,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiVirtual
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
|
||||
@@ -168,6 +168,7 @@ public interface PetApi {
|
||||
* or Invalid tag value (status code 400)
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
@ApiOperation(
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
|
||||
Reference in New Issue
Block a user