forked from loafle/openapi-generator-original
[JavaSpring] Generate deprecated property, annotation and javadoc. (#16493)
* [JavaSpring] Generate deprecated annotation and doc properties * [JavaSpring] Generate deprecated for @Schema * [JavaSpring] Add sample folder to workflow --------- Co-authored-by: Diego Urban <d.urban@carepay.com>
This commit is contained in:
@@ -150,6 +150,7 @@ public interface PetApi {
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.",
|
||||
deprecated = true,
|
||||
tags = { "pet" },
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
|
||||
@@ -79,6 +79,7 @@ public class Pet {
|
||||
}
|
||||
}
|
||||
|
||||
@Deprecated
|
||||
private StatusEnum status;
|
||||
|
||||
public Pet() {
|
||||
@@ -218,14 +219,20 @@ public class Pet {
|
||||
/**
|
||||
* pet status in the store
|
||||
* @return status
|
||||
* @deprecated
|
||||
*/
|
||||
|
||||
@Schema(name = "status", description = "pet status in the store", requiredMode = Schema.RequiredMode.NOT_REQUIRED)
|
||||
@Schema(name = "status", description = "pet status in the store", deprecated = true, requiredMode = Schema.RequiredMode.NOT_REQUIRED)
|
||||
@JsonProperty("status")
|
||||
@Deprecated
|
||||
public StatusEnum getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
@Deprecated
|
||||
public void setStatus(StatusEnum status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user