forked from loafle/openapi-generator-original
Upgrade virtualan-plugin to 2.5.1 (#12429)
* Upgrade virtualan-plugin to 2.5.1 * Generate samples * Upgrade virtualan sample to springdoc * Generate Samples * Add samples/server/petstore/springboot-virtualan to ci run * Upgrade virtualan-plugin to 2.5.2 * Generate samples * Add virtualan.version to spring-boot-3 pom.xml, upgrade to 2.5.2
This commit is contained in:
1
.github/workflows/samples-spring.yaml
vendored
1
.github/workflows/samples-spring.yaml
vendored
@@ -41,6 +41,7 @@ jobs:
|
||||
- samples/server/petstore/spring-boot-nullable-set
|
||||
- samples/server/petstore/spring-boot-defaultInterface-unhandledException
|
||||
- samples/openapi3/server/petstore/spring-boot-oneof
|
||||
- samples/server/petstore/springboot-virtualan
|
||||
- samples/openapi3/server/petstore/springboot-3
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
@@ -4,7 +4,7 @@ library: spring-boot
|
||||
inputSpec: modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml
|
||||
templateDir: modules/openapi-generator/src/main/resources/JavaSpring
|
||||
additionalProperties:
|
||||
documentationProvider: springfox
|
||||
documentationProvider: springdoc
|
||||
apiPackage: org.openapitools.virtualan.api
|
||||
modelPackage: org.openapitools.virtualan.model
|
||||
virtualService: true
|
||||
|
||||
@@ -21,6 +21,9 @@
|
||||
{{#useSwaggerUI}}
|
||||
<swagger-ui.version>4.8.1</swagger-ui.version>
|
||||
{{/useSwaggerUI}}
|
||||
{{#virtualService}}
|
||||
<virtualan.version>2.5.2</virtualan.version>
|
||||
{{/virtualService}}
|
||||
</properties>
|
||||
{{#parentOverridden}}
|
||||
<parent>
|
||||
@@ -198,13 +201,12 @@
|
||||
<dependency>
|
||||
<groupId>io.virtualan</groupId>
|
||||
<artifactId>virtualan-plugin</artifactId>
|
||||
<version>2.2.1</version>
|
||||
<version>${virtualan.version}</version>
|
||||
</dependency>
|
||||
<!-- HyperSQL DB -->
|
||||
<dependency>
|
||||
<groupId>org.hsqldb</groupId>
|
||||
<artifactId>hsqldb</artifactId>
|
||||
<version>2.5.0</version>
|
||||
</dependency>
|
||||
<!-- END Virtual Service API support -->
|
||||
{{/virtualService}}
|
||||
|
||||
@@ -26,6 +26,9 @@
|
||||
{{/swagger2AnnotationLibrary}}
|
||||
{{/springDocDocumentationProvider}}
|
||||
{{/springFoxDocumentationProvider}}
|
||||
{{#virtualService}}
|
||||
<virtualan.version>2.5.2</virtualan.version>
|
||||
{{/virtualService}}
|
||||
{{#useSwaggerUI}}
|
||||
<swagger-ui.version>4.10.3</swagger-ui.version>
|
||||
{{/useSwaggerUI}}
|
||||
@@ -208,13 +211,12 @@
|
||||
<dependency>
|
||||
<groupId>io.virtualan</groupId>
|
||||
<artifactId>virtualan-plugin</artifactId>
|
||||
<version>2.2.1</version>
|
||||
<version>${virtualan.version}</version>
|
||||
</dependency>
|
||||
<!-- HyperSQL DB -->
|
||||
<dependency>
|
||||
<groupId>org.hsqldb</groupId>
|
||||
<artifactId>hsqldb</artifactId>
|
||||
<version>2.5.0</version>
|
||||
</dependency>
|
||||
<!-- END Virtual Service API support -->
|
||||
{{/virtualService}}
|
||||
|
||||
@@ -3,7 +3,7 @@ pom.xml
|
||||
src/main/java/org/openapitools/OpenApiGeneratorApplication.java
|
||||
src/main/java/org/openapitools/RFC3339DateFormat.java
|
||||
src/main/java/org/openapitools/configuration/HomeController.java
|
||||
src/main/java/org/openapitools/configuration/SpringFoxConfiguration.java
|
||||
src/main/java/org/openapitools/configuration/SpringDocConfiguration.java
|
||||
src/main/java/org/openapitools/virtualan/api/AnotherFakeApi.java
|
||||
src/main/java/org/openapitools/virtualan/api/AnotherFakeApiController.java
|
||||
src/main/java/org/openapitools/virtualan/api/ApiUtil.java
|
||||
@@ -67,5 +67,4 @@ src/main/java/org/openapitools/virtualan/model/User.java
|
||||
src/main/java/org/openapitools/virtualan/model/XmlItem.java
|
||||
src/main/resources/application.properties
|
||||
src/main/resources/openapi.yaml
|
||||
src/main/resources/static/swagger-ui.html
|
||||
src/test/java/org/openapitools/OpenApiGeneratorApplicationTests.java
|
||||
|
||||
@@ -7,17 +7,11 @@ This server was generated by the [OpenAPI Generator](https://openapi-generator.t
|
||||
By using the [OpenAPI-Spec](https://openapis.org), you can easily generate a server stub.
|
||||
This is an example of building a OpenAPI-enabled server in Java using the SpringBoot framework.
|
||||
|
||||
The underlying library integrating OpenAPI to Spring Boot is [springfox](https://github.com/springfox/springfox).
|
||||
Springfox will generate an OpenAPI v2 (fka Swagger RESTful API Documentation Specification) specification based on the
|
||||
generated Controller and Model classes. The specification is available to download using the following url:
|
||||
http://localhost:80/v2/api-docs/
|
||||
|
||||
**HEADS-UP**: Springfox is deprecated for removal in version 6.0.0 of openapi-generator. The project seems to be no longer
|
||||
maintained (last commit is of Oct 14, 2020). It works with Spring Boot 2.5.x but not with 2.6. Spring Boot 2.5 is
|
||||
supported until 2022-05-19. Users of openapi-generator should migrate to the springdoc documentation provider which is,
|
||||
as an added bonus, OpenAPI v3 compatible.
|
||||
|
||||
|
||||
The underlying library integrating OpenAPI to Spring Boot is [springdoc](https://springdoc.org).
|
||||
Springdoc will generate an OpenAPI v3 specification based on the generated Controller and Model classes.
|
||||
The specification is available to download using the following url:
|
||||
http://localhost:80/v3/api-docs/
|
||||
|
||||
Start your server as a simple java application
|
||||
|
||||
|
||||
@@ -10,13 +10,14 @@
|
||||
<maven.compiler.source>${java.version}</maven.compiler.source>
|
||||
<maven.compiler.target>${java.version}</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<springfox.version>2.9.2</springfox.version>
|
||||
<springdoc.version>1.6.8</springdoc.version>
|
||||
<virtualan.version>2.5.2</virtualan.version>
|
||||
<swagger-ui.version>4.10.3</swagger-ui.version>
|
||||
</properties>
|
||||
<parent>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-parent</artifactId>
|
||||
<version>2.5.14</version>
|
||||
<version>2.7.0</version>
|
||||
<relativePath/> <!-- lookup parent from repository -->
|
||||
</parent>
|
||||
<build>
|
||||
@@ -37,20 +38,11 @@
|
||||
<groupId>org.springframework.data</groupId>
|
||||
<artifactId>spring-data-commons</artifactId>
|
||||
</dependency>
|
||||
<!--SpringFox dependencies -->
|
||||
<!--SpringDoc dependencies -->
|
||||
<dependency>
|
||||
<groupId>io.springfox</groupId>
|
||||
<artifactId>springfox-swagger2</artifactId>
|
||||
<version>${springfox.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.webjars</groupId>
|
||||
<artifactId>swagger-ui</artifactId>
|
||||
<version>${swagger-ui.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.webjars</groupId>
|
||||
<artifactId>webjars-locator-core</artifactId>
|
||||
<groupId>org.springdoc</groupId>
|
||||
<artifactId>springdoc-openapi-ui</artifactId>
|
||||
<version>${springdoc.version}</version>
|
||||
</dependency>
|
||||
<!-- @Nullable annotation -->
|
||||
<dependency>
|
||||
@@ -80,13 +72,12 @@
|
||||
<dependency>
|
||||
<groupId>io.virtualan</groupId>
|
||||
<artifactId>virtualan-plugin</artifactId>
|
||||
<version>2.2.1</version>
|
||||
<version>${virtualan.version}</version>
|
||||
</dependency>
|
||||
<!-- HyperSQL DB -->
|
||||
<dependency>
|
||||
<groupId>org.hsqldb</groupId>
|
||||
<artifactId>hsqldb</artifactId>
|
||||
<version>2.5.0</version>
|
||||
</dependency>
|
||||
<!-- END Virtual Service API support -->
|
||||
<dependency>
|
||||
|
||||
@@ -12,14 +12,6 @@ import org.springframework.web.bind.annotation.GetMapping;
|
||||
@Controller
|
||||
public class HomeController {
|
||||
|
||||
static final String API_DOCS_PATH = "/v2/api-docs";
|
||||
|
||||
@GetMapping(value = "/swagger-config.yaml", produces = "text/plain")
|
||||
@ResponseBody
|
||||
public String swaggerConfig() {
|
||||
return "url: " + API_DOCS_PATH + "\n";
|
||||
}
|
||||
|
||||
@RequestMapping("/")
|
||||
public String index() {
|
||||
return "redirect:swagger-ui.html";
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
package org.openapitools.configuration;
|
||||
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import io.swagger.v3.oas.models.OpenAPI;
|
||||
import io.swagger.v3.oas.models.info.Info;
|
||||
import io.swagger.v3.oas.models.info.Contact;
|
||||
import io.swagger.v3.oas.models.info.License;
|
||||
import io.swagger.v3.oas.models.Components;
|
||||
import io.swagger.v3.oas.models.security.SecurityScheme;
|
||||
|
||||
@Configuration
|
||||
public class SpringDocConfiguration {
|
||||
|
||||
@Bean
|
||||
OpenAPI apiInfo() {
|
||||
return new OpenAPI()
|
||||
.info(
|
||||
new Info()
|
||||
.title("OpenAPI Petstore")
|
||||
.description("This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\")
|
||||
.license(
|
||||
new License()
|
||||
.name("Apache-2.0")
|
||||
.url("https://www.apache.org/licenses/LICENSE-2.0.html")
|
||||
)
|
||||
.version("1.0.0")
|
||||
)
|
||||
.components(
|
||||
new Components()
|
||||
.addSecuritySchemes("api_key", new SecurityScheme()
|
||||
.type(SecurityScheme.Type.APIKEY)
|
||||
.in(SecurityScheme.In.HEADER)
|
||||
.name("api_key")
|
||||
)
|
||||
.addSecuritySchemes("api_key_query", new SecurityScheme()
|
||||
.type(SecurityScheme.Type.APIKEY)
|
||||
.in(SecurityScheme.In.QUERY)
|
||||
.name("api_key_query")
|
||||
)
|
||||
.addSecuritySchemes("http_basic_test", new SecurityScheme()
|
||||
.type(SecurityScheme.Type.HTTP)
|
||||
.scheme("basic")
|
||||
)
|
||||
.addSecuritySchemes("petstore_auth", new SecurityScheme()
|
||||
.type(SecurityScheme.Type.OAUTH2)
|
||||
)
|
||||
)
|
||||
;
|
||||
}
|
||||
}
|
||||
@@ -1,71 +0,0 @@
|
||||
package org.openapitools.configuration;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import org.springframework.web.util.UriComponentsBuilder;
|
||||
import springfox.documentation.builders.ApiInfoBuilder;
|
||||
import springfox.documentation.builders.RequestHandlerSelectors;
|
||||
import springfox.documentation.service.ApiInfo;
|
||||
import springfox.documentation.service.Contact;
|
||||
import springfox.documentation.spi.DocumentationType;
|
||||
import springfox.documentation.spring.web.paths.Paths;
|
||||
import springfox.documentation.spring.web.paths.RelativePathProvider;
|
||||
import springfox.documentation.spring.web.plugins.Docket;
|
||||
import springfox.documentation.swagger2.annotations.EnableSwagger2;
|
||||
|
||||
import javax.annotation.Generated;
|
||||
import javax.servlet.ServletContext;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Configuration
|
||||
@EnableSwagger2
|
||||
public class SpringFoxConfiguration {
|
||||
|
||||
ApiInfo apiInfo() {
|
||||
return new ApiInfoBuilder()
|
||||
.title("OpenAPI Petstore")
|
||||
.description("This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\")
|
||||
.license("Apache-2.0")
|
||||
.licenseUrl("https://www.apache.org/licenses/LICENSE-2.0.html")
|
||||
.termsOfServiceUrl("")
|
||||
.version("1.0.0")
|
||||
.contact(new Contact("","", ""))
|
||||
.build();
|
||||
}
|
||||
|
||||
@Bean
|
||||
public Docket customImplementation(ServletContext servletContext, @Value("${openapi.openAPIPetstore.base-path:/v2}") String basePath) {
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.select()
|
||||
.apis(RequestHandlerSelectors.basePackage("org.openapitools.virtualan.api"))
|
||||
.build()
|
||||
.pathProvider(new BasePathAwareRelativePathProvider(servletContext, basePath))
|
||||
.directModelSubstitute(java.time.LocalDate.class, java.sql.Date.class)
|
||||
.directModelSubstitute(java.time.OffsetDateTime.class, java.util.Date.class)
|
||||
.apiInfo(apiInfo());
|
||||
}
|
||||
|
||||
class BasePathAwareRelativePathProvider extends RelativePathProvider {
|
||||
private String basePath;
|
||||
|
||||
public BasePathAwareRelativePathProvider(ServletContext servletContext, String basePath) {
|
||||
super(servletContext);
|
||||
this.basePath = basePath;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String applicationPath() {
|
||||
return Paths.removeAdjacentForwardSlashes(UriComponentsBuilder.fromPath(super.applicationPath()).path(basePath).build().toString());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getOperationPath(String operationPath) {
|
||||
UriComponentsBuilder uriComponentsBuilder = UriComponentsBuilder.fromPath("/");
|
||||
return Paths.removeAdjacentForwardSlashes(
|
||||
uriComponentsBuilder.path(operationPath.replaceFirst("^" + basePath, "")).build().toString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -6,7 +6,14 @@
|
||||
package org.openapitools.virtualan.api;
|
||||
|
||||
import org.openapitools.virtualan.model.Client;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -26,7 +33,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "another-fake", description = "the another-fake API")
|
||||
@Tag(name = "another-fake", description = "the another-fake API")
|
||||
@VirtualService
|
||||
public interface AnotherFakeApi {
|
||||
|
||||
@@ -42,16 +49,16 @@ public interface AnotherFakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "call123testSpecialTags",
|
||||
summary = "To test special tags",
|
||||
tags = { "$another-fake?" },
|
||||
value = "To test special tags",
|
||||
nickname = "call123testSpecialTags",
|
||||
notes = "To test special tags and operation ID starting with number",
|
||||
response = Client.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Client.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Client.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PATCH,
|
||||
value = "/another-fake/dummy",
|
||||
@@ -59,7 +66,7 @@ public interface AnotherFakeApi {
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Client> call123testSpecialTags(
|
||||
@ApiParam(value = "client model", required = true) @Valid @RequestBody Client body
|
||||
@Parameter(name = "body", description = "client model", required = true) @Valid @RequestBody Client body
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -16,7 +16,14 @@ import java.time.OffsetDateTime;
|
||||
import org.openapitools.virtualan.model.OuterComposite;
|
||||
import org.openapitools.virtualan.model.User;
|
||||
import org.openapitools.virtualan.model.XmlItem;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -36,7 +43,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "fake", description = "the fake API")
|
||||
@Tag(name = "fake", description = "the fake API")
|
||||
@VirtualService
|
||||
public interface FakeApi {
|
||||
|
||||
@@ -52,22 +59,21 @@ public interface FakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "createXmlItem",
|
||||
summary = "creates an XmlItem",
|
||||
tags = { "fake" },
|
||||
value = "creates an XmlItem",
|
||||
nickname = "createXmlItem",
|
||||
notes = "this route creates an XmlItem"
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/create_xml_item",
|
||||
consumes = { "application/xml", "application/xml; charset=utf-8", "application/xml; charset=utf-16", "text/xml", "text/xml; charset=utf-8", "text/xml; charset=utf-16" }
|
||||
)
|
||||
default ResponseEntity<Void> createXmlItem(
|
||||
@ApiParam(value = "XmlItem Body", required = true) @Valid @RequestBody XmlItem xmlItem
|
||||
@Parameter(name = "XmlItem", description = "XmlItem Body", required = true) @Valid @RequestBody XmlItem xmlItem
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -82,23 +88,22 @@ public interface FakeApi {
|
||||
* @return Output boolean (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "fakeOuterBooleanSerialize",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "fakeOuterBooleanSerialize",
|
||||
notes = "Test serialization of outer boolean types",
|
||||
response = Boolean.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Output boolean", content = {
|
||||
@Content(mediaType = "*/*", schema = @Schema(implementation = Boolean.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Output boolean", response = Boolean.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/outer/boolean",
|
||||
produces = { "*/*" }
|
||||
)
|
||||
default ResponseEntity<Boolean> fakeOuterBooleanSerialize(
|
||||
@ApiParam(value = "Input boolean as post body") @Valid @RequestBody(required = false) Boolean body
|
||||
@Parameter(name = "body", description = "Input boolean as post body") @Valid @RequestBody(required = false) Boolean body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -113,23 +118,22 @@ public interface FakeApi {
|
||||
* @return Output composite (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "fakeOuterCompositeSerialize",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "fakeOuterCompositeSerialize",
|
||||
notes = "Test serialization of object with outer number type",
|
||||
response = OuterComposite.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Output composite", content = {
|
||||
@Content(mediaType = "*/*", schema = @Schema(implementation = OuterComposite.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Output composite", response = OuterComposite.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/outer/composite",
|
||||
produces = { "*/*" }
|
||||
)
|
||||
default ResponseEntity<OuterComposite> fakeOuterCompositeSerialize(
|
||||
@ApiParam(value = "Input composite as post body") @Valid @RequestBody(required = false) OuterComposite body
|
||||
@Parameter(name = "body", description = "Input composite as post body") @Valid @RequestBody(required = false) OuterComposite body
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -153,23 +157,22 @@ public interface FakeApi {
|
||||
* @return Output number (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "fakeOuterNumberSerialize",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "fakeOuterNumberSerialize",
|
||||
notes = "Test serialization of outer number types",
|
||||
response = BigDecimal.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Output number", content = {
|
||||
@Content(mediaType = "*/*", schema = @Schema(implementation = BigDecimal.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Output number", response = BigDecimal.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/outer/number",
|
||||
produces = { "*/*" }
|
||||
)
|
||||
default ResponseEntity<BigDecimal> fakeOuterNumberSerialize(
|
||||
@ApiParam(value = "Input number as post body") @Valid @RequestBody(required = false) BigDecimal body
|
||||
@Parameter(name = "body", description = "Input number as post body") @Valid @RequestBody(required = false) BigDecimal body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -184,23 +187,22 @@ public interface FakeApi {
|
||||
* @return Output string (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "fakeOuterStringSerialize",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "fakeOuterStringSerialize",
|
||||
notes = "Test serialization of outer string types",
|
||||
response = String.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Output string", content = {
|
||||
@Content(mediaType = "*/*", schema = @Schema(implementation = String.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Output string", response = String.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/outer/string",
|
||||
produces = { "*/*" }
|
||||
)
|
||||
default ResponseEntity<String> fakeOuterStringSerialize(
|
||||
@ApiParam(value = "Input string as post body") @Valid @RequestBody(required = false) String body
|
||||
@Parameter(name = "body", description = "Input string as post body") @Valid @RequestBody(required = false) String body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -215,22 +217,20 @@ public interface FakeApi {
|
||||
* @return Success (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testBodyWithFileSchema",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "testBodyWithFileSchema",
|
||||
notes = "For this test, the body for this request much reference a schema named `File`."
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Success")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Success")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PUT,
|
||||
value = "/fake/body-with-file-schema",
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Void> testBodyWithFileSchema(
|
||||
@ApiParam(value = "", required = true) @Valid @RequestBody FileSchemaTestClass body
|
||||
@Parameter(name = "body", description = "", required = true) @Valid @RequestBody FileSchemaTestClass body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -245,23 +245,21 @@ public interface FakeApi {
|
||||
* @return Success (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testBodyWithQueryParams",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "testBodyWithQueryParams",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Success")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Success")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PUT,
|
||||
value = "/fake/body-with-query-params",
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Void> testBodyWithQueryParams(
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "query", required = true) String query,
|
||||
@ApiParam(value = "", required = true) @Valid @RequestBody User body
|
||||
@NotNull @Parameter(name = "query", description = "", required = true) @Valid @RequestParam(value = "query", required = true) String query,
|
||||
@Parameter(name = "body", description = "", required = true) @Valid @RequestBody User body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -276,16 +274,16 @@ public interface FakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testClientModel",
|
||||
summary = "To test \"client\" model",
|
||||
tags = { "fake" },
|
||||
value = "To test \"client\" model",
|
||||
nickname = "testClientModel",
|
||||
notes = "To test \"client\" model",
|
||||
response = Client.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Client.class))
|
||||
})
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Client.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PATCH,
|
||||
value = "/fake",
|
||||
@@ -293,7 +291,7 @@ public interface FakeApi {
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Client> testClientModel(
|
||||
@ApiParam(value = "client model", required = true) @Valid @RequestBody Client body
|
||||
@Parameter(name = "body", description = "client model", required = true) @Valid @RequestBody Client body
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -331,39 +329,38 @@ public interface FakeApi {
|
||||
* or User not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testEndpointParameters",
|
||||
summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트",
|
||||
tags = { "fake" },
|
||||
value = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트",
|
||||
nickname = "testEndpointParameters",
|
||||
notes = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트",
|
||||
authorizations = {
|
||||
@Authorization(value = "http_basic_test")
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Invalid username supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "User not found")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "http_basic_test")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Invalid username supplied"),
|
||||
@ApiResponse(code = 404, message = "User not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake",
|
||||
consumes = { "application/x-www-form-urlencoded" }
|
||||
)
|
||||
default ResponseEntity<Void> testEndpointParameters(
|
||||
@ApiParam(value = "None", required = true) @Valid @RequestParam(value = "number", required = true) BigDecimal number,
|
||||
@ApiParam(value = "None", required = true) @Valid @RequestParam(value = "double", required = true) Double _double,
|
||||
@ApiParam(value = "None", required = true) @Valid @RequestParam(value = "pattern_without_delimiter", required = true) String patternWithoutDelimiter,
|
||||
@ApiParam(value = "None", required = true) @Valid @RequestParam(value = "byte", required = true) byte[] _byte,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "integer", required = false) Integer integer,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "int32", required = false) Integer int32,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "int64", required = false) Long int64,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "float", required = false) Float _float,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "string", required = false) String string,
|
||||
@ApiParam(value = "None") @RequestPart(value = "binary", required = false) MultipartFile binary,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "date", required = false) @DateTimeFormat(iso = DateTimeFormat.ISO.DATE) LocalDate date,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "dateTime", required = false) @DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME) OffsetDateTime dateTime,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "password", required = false) String password,
|
||||
@ApiParam(value = "None") @Valid @RequestParam(value = "callback", required = false) String paramCallback
|
||||
@Parameter(name = "number", description = "None", required = true) @Valid @RequestParam(value = "number", required = true) BigDecimal number,
|
||||
@Parameter(name = "double", description = "None", required = true) @Valid @RequestParam(value = "double", required = true) Double _double,
|
||||
@Parameter(name = "pattern_without_delimiter", description = "None", required = true) @Valid @RequestParam(value = "pattern_without_delimiter", required = true) String patternWithoutDelimiter,
|
||||
@Parameter(name = "byte", description = "None", required = true) @Valid @RequestParam(value = "byte", required = true) byte[] _byte,
|
||||
@Parameter(name = "integer", description = "None") @Valid @RequestParam(value = "integer", required = false) Integer integer,
|
||||
@Parameter(name = "int32", description = "None") @Valid @RequestParam(value = "int32", required = false) Integer int32,
|
||||
@Parameter(name = "int64", description = "None") @Valid @RequestParam(value = "int64", required = false) Long int64,
|
||||
@Parameter(name = "float", description = "None") @Valid @RequestParam(value = "float", required = false) Float _float,
|
||||
@Parameter(name = "string", description = "None") @Valid @RequestParam(value = "string", required = false) String string,
|
||||
@Parameter(name = "binary", description = "None") @RequestPart(value = "binary", required = false) MultipartFile binary,
|
||||
@Parameter(name = "date", description = "None") @Valid @RequestParam(value = "date", required = false) @DateTimeFormat(iso = DateTimeFormat.ISO.DATE) LocalDate date,
|
||||
@Parameter(name = "dateTime", description = "None") @Valid @RequestParam(value = "dateTime", required = false) @DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME) OffsetDateTime dateTime,
|
||||
@Parameter(name = "password", description = "None") @Valid @RequestParam(value = "password", required = false) String password,
|
||||
@Parameter(name = "callback", description = "None") @Valid @RequestParam(value = "callback", required = false) String paramCallback
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -386,30 +383,29 @@ public interface FakeApi {
|
||||
* or Not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testEnumParameters",
|
||||
summary = "To test enum parameters",
|
||||
tags = { "fake" },
|
||||
value = "To test enum parameters",
|
||||
nickname = "testEnumParameters",
|
||||
notes = "To test enum parameters"
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Invalid request"),
|
||||
@ApiResponse(responseCode = "404", description = "Not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Invalid request"),
|
||||
@ApiResponse(code = 404, message = "Not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/fake",
|
||||
consumes = { "application/x-www-form-urlencoded" }
|
||||
)
|
||||
default ResponseEntity<Void> testEnumParameters(
|
||||
@ApiParam(value = "Header parameter enum test (string array)", allowableValues = ">, $") @RequestHeader(value = "enum_header_string_array", required = false) List<String> enumHeaderStringArray,
|
||||
@ApiParam(value = "Header parameter enum test (string)", allowableValues = "_abc, -efg, (xyz)", defaultValue = "-efg") @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString,
|
||||
@ApiParam(value = "Query parameter enum test (string array)", allowableValues = ">, $") @Valid @RequestParam(value = "enum_query_string_array", required = false) List<String> enumQueryStringArray,
|
||||
@ApiParam(value = "Query parameter enum test (string)", allowableValues = "_abc, -efg, (xyz)", defaultValue = "-efg") @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString,
|
||||
@ApiParam(value = "Query parameter enum test (double)", allowableValues = "1, -2") @Valid @RequestParam(value = "enum_query_integer", required = false) Integer enumQueryInteger,
|
||||
@ApiParam(value = "Query parameter enum test (double)", allowableValues = "1.1, -1.2") @Valid @RequestParam(value = "enum_query_double", required = false) Double enumQueryDouble,
|
||||
@ApiParam(value = "Form parameter enum test (string array)", allowableValues = ">, $", defaultValue = "$") @Valid @RequestParam(value = "enum_form_string_array", required = false) List<String> enumFormStringArray,
|
||||
@ApiParam(value = "Form parameter enum test (string)", allowableValues = "_abc, -efg, (xyz)", defaultValue = "-efg") @Valid @RequestParam(value = "enum_form_string", required = false) String enumFormString
|
||||
@Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)") @RequestHeader(value = "enum_header_string_array", required = false) List<String> enumHeaderStringArray,
|
||||
@Parameter(name = "enum_header_string", description = "Header parameter enum test (string)") @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString,
|
||||
@Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)") @Valid @RequestParam(value = "enum_query_string_array", required = false) List<String> enumQueryStringArray,
|
||||
@Parameter(name = "enum_query_string", description = "Query parameter enum test (string)") @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString,
|
||||
@Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)") @Valid @RequestParam(value = "enum_query_integer", required = false) Integer enumQueryInteger,
|
||||
@Parameter(name = "enum_query_double", description = "Query parameter enum test (double)") @Valid @RequestParam(value = "enum_query_double", required = false) Double enumQueryDouble,
|
||||
@Parameter(name = "enum_form_string_array", description = "Form parameter enum test (string array)") @Valid @RequestParam(value = "enum_form_string_array", required = false) List<String> enumFormStringArray,
|
||||
@Parameter(name = "enum_form_string", description = "Form parameter enum test (string)") @Valid @RequestParam(value = "enum_form_string", required = false) String enumFormString
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -429,26 +425,25 @@ public interface FakeApi {
|
||||
* @return Someting wrong (status code 400)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testGroupParameters",
|
||||
summary = "Fake endpoint to test group parameters (optional)",
|
||||
tags = { "fake" },
|
||||
value = "Fake endpoint to test group parameters (optional)",
|
||||
nickname = "testGroupParameters",
|
||||
notes = "Fake endpoint to test group parameters (optional)"
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Someting wrong")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Someting wrong")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.DELETE,
|
||||
value = "/fake"
|
||||
)
|
||||
default ResponseEntity<Void> testGroupParameters(
|
||||
@NotNull @ApiParam(value = "Required String in group parameters", required = true) @Valid @RequestParam(value = "required_string_group", required = true) Integer requiredStringGroup,
|
||||
@ApiParam(value = "Required Boolean in group parameters", required = true) @RequestHeader(value = "required_boolean_group", required = true) Boolean requiredBooleanGroup,
|
||||
@NotNull @ApiParam(value = "Required Integer in group parameters", required = true) @Valid @RequestParam(value = "required_int64_group", required = true) Long requiredInt64Group,
|
||||
@ApiParam(value = "String in group parameters") @Valid @RequestParam(value = "string_group", required = false) Integer stringGroup,
|
||||
@ApiParam(value = "Boolean in group parameters") @RequestHeader(value = "boolean_group", required = false) Boolean booleanGroup,
|
||||
@ApiParam(value = "Integer in group parameters") @Valid @RequestParam(value = "int64_group", required = false) Long int64Group
|
||||
@NotNull @Parameter(name = "required_string_group", description = "Required String in group parameters", required = true) @Valid @RequestParam(value = "required_string_group", required = true) Integer requiredStringGroup,
|
||||
@Parameter(name = "required_boolean_group", description = "Required Boolean in group parameters", required = true) @RequestHeader(value = "required_boolean_group", required = true) Boolean requiredBooleanGroup,
|
||||
@NotNull @Parameter(name = "required_int64_group", description = "Required Integer in group parameters", required = true) @Valid @RequestParam(value = "required_int64_group", required = true) Long requiredInt64Group,
|
||||
@Parameter(name = "string_group", description = "String in group parameters") @Valid @RequestParam(value = "string_group", required = false) Integer stringGroup,
|
||||
@Parameter(name = "boolean_group", description = "Boolean in group parameters") @RequestHeader(value = "boolean_group", required = false) Boolean booleanGroup,
|
||||
@Parameter(name = "int64_group", description = "Integer in group parameters") @Valid @RequestParam(value = "int64_group", required = false) Long int64Group
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -462,22 +457,21 @@ public interface FakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testInlineAdditionalProperties",
|
||||
summary = "test inline additionalProperties",
|
||||
tags = { "fake" },
|
||||
value = "test inline additionalProperties",
|
||||
nickname = "testInlineAdditionalProperties",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/inline-additionalProperties",
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Void> testInlineAdditionalProperties(
|
||||
@ApiParam(value = "request body", required = true) @Valid @RequestBody Map<String, String> param
|
||||
@Parameter(name = "param", description = "request body", required = true) @Valid @RequestBody Map<String, String> param
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -492,23 +486,22 @@ public interface FakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testJsonFormData",
|
||||
summary = "test json serialization of form data",
|
||||
tags = { "fake" },
|
||||
value = "test json serialization of form data",
|
||||
nickname = "testJsonFormData",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/fake/jsonFormData",
|
||||
consumes = { "application/x-www-form-urlencoded" }
|
||||
)
|
||||
default ResponseEntity<Void> testJsonFormData(
|
||||
@ApiParam(value = "field1", required = true) @Valid @RequestParam(value = "param", required = true) String param,
|
||||
@ApiParam(value = "field2", required = true) @Valid @RequestParam(value = "param2", required = true) String param2
|
||||
@Parameter(name = "param", description = "field1", required = true) @Valid @RequestParam(value = "param", required = true) String param,
|
||||
@Parameter(name = "param2", description = "field2", required = true) @Valid @RequestParam(value = "param2", required = true) String param2
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -527,25 +520,23 @@ public interface FakeApi {
|
||||
* @return Success (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testQueryParameterCollectionFormat",
|
||||
tags = { "fake" },
|
||||
value = "",
|
||||
nickname = "testQueryParameterCollectionFormat",
|
||||
notes = "To test the collection format in query parameters"
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "Success")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "Success")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PUT,
|
||||
value = "/fake/test-query-parameters"
|
||||
)
|
||||
default ResponseEntity<Void> testQueryParameterCollectionFormat(
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "pipe", required = true) List<String> pipe,
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "ioutil", required = true) List<String> ioutil,
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "http", required = true) List<String> http,
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "url", required = true) List<String> url,
|
||||
@NotNull @ApiParam(value = "", required = true) @Valid @RequestParam(value = "context", required = true) List<String> context
|
||||
@NotNull @Parameter(name = "pipe", description = "", required = true) @Valid @RequestParam(value = "pipe", required = true) List<String> pipe,
|
||||
@NotNull @Parameter(name = "ioutil", description = "", required = true) @Valid @RequestParam(value = "ioutil", required = true) List<String> ioutil,
|
||||
@NotNull @Parameter(name = "http", description = "", required = true) @Valid @RequestParam(value = "http", required = true) List<String> http,
|
||||
@NotNull @Parameter(name = "url", description = "", required = true) @Valid @RequestParam(value = "url", required = true) List<String> url,
|
||||
@NotNull @Parameter(name = "context", description = "", required = true) @Valid @RequestParam(value = "context", required = true) List<String> context
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -561,22 +552,19 @@ public interface FakeApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "uploadFileWithRequiredFile",
|
||||
summary = "uploads an image (required)",
|
||||
tags = { "pet" },
|
||||
value = "uploads an image (required)",
|
||||
nickname = "uploadFileWithRequiredFile",
|
||||
notes = "",
|
||||
response = ModelApiResponse.class,
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = ModelApiResponse.class))
|
||||
})
|
||||
}
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/fake/{petId}/uploadImageWithRequiredFile",
|
||||
@@ -584,9 +572,9 @@ public interface FakeApi {
|
||||
consumes = { "multipart/form-data" }
|
||||
)
|
||||
default ResponseEntity<ModelApiResponse> uploadFileWithRequiredFile(
|
||||
@ApiParam(value = "ID of pet to update", required = true) @PathVariable("petId") Long petId,
|
||||
@ApiParam(value = "file to upload", required = true) @RequestPart(value = "requiredFile", required = true) MultipartFile requiredFile,
|
||||
@ApiParam(value = "Additional data to pass to server") @Valid @RequestParam(value = "additionalMetadata", required = false) String additionalMetadata
|
||||
@Parameter(name = "petId", description = "ID of pet to update", required = true) @PathVariable("petId") Long petId,
|
||||
@Parameter(name = "requiredFile", description = "file to upload", required = true) @RequestPart(value = "requiredFile", required = true) MultipartFile requiredFile,
|
||||
@Parameter(name = "additionalMetadata", description = "Additional data to pass to server") @Valid @RequestParam(value = "additionalMetadata", required = false) String additionalMetadata
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -6,7 +6,14 @@
|
||||
package org.openapitools.virtualan.api;
|
||||
|
||||
import org.openapitools.virtualan.model.Client;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -26,7 +33,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "fake_classname_test", description = "the fake_classname_test API")
|
||||
@Tag(name = "fake_classname_test", description = "the fake_classname_test API")
|
||||
@VirtualService
|
||||
public interface FakeClassnameTestApi {
|
||||
|
||||
@@ -42,19 +49,19 @@ public interface FakeClassnameTestApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "testClassname",
|
||||
summary = "To test class name in snake case",
|
||||
tags = { "fake_classname_tags 123#$%^" },
|
||||
value = "To test class name in snake case",
|
||||
nickname = "testClassname",
|
||||
notes = "To test class name in snake case",
|
||||
response = Client.class,
|
||||
authorizations = {
|
||||
@Authorization(value = "api_key_query")
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Client.class))
|
||||
})
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "api_key_query")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Client.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PATCH,
|
||||
value = "/fake_classname_test",
|
||||
@@ -62,7 +69,7 @@ public interface FakeClassnameTestApi {
|
||||
consumes = { "application/json" }
|
||||
)
|
||||
default ResponseEntity<Client> testClassname(
|
||||
@ApiParam(value = "client model", required = true) @Valid @RequestBody Client body
|
||||
@Parameter(name = "body", description = "client model", required = true) @Valid @RequestBody Client body
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -8,7 +8,14 @@ package org.openapitools.virtualan.api;
|
||||
import org.openapitools.virtualan.model.ModelApiResponse;
|
||||
import org.openapitools.virtualan.model.Pet;
|
||||
import java.util.Set;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -28,7 +35,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "pet", description = "Everything about your Pets")
|
||||
@Tag(name = "pet", description = "Everything about your Pets")
|
||||
@VirtualService
|
||||
public interface PetApi {
|
||||
|
||||
@@ -44,29 +51,25 @@ public interface PetApi {
|
||||
* or Invalid input (status code 405)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "addPet",
|
||||
summary = "Add a new pet to the store",
|
||||
tags = { "pet" },
|
||||
value = "Add a new pet to the store",
|
||||
nickname = "addPet",
|
||||
notes = "",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation"),
|
||||
@ApiResponse(responseCode = "405", description = "Invalid input")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation"),
|
||||
@ApiResponse(code = 405, message = "Invalid input")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/pet",
|
||||
consumes = { "application/json", "application/xml" }
|
||||
)
|
||||
default ResponseEntity<Void> addPet(
|
||||
@ApiParam(value = "Pet object that needs to be added to the store", required = true) @Valid @RequestBody Pet body
|
||||
@Parameter(name = "body", description = "Pet object that needs to be added to the store", required = true) @Valid @RequestBody Pet body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -82,29 +85,25 @@ public interface PetApi {
|
||||
* or Invalid pet value (status code 400)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "deletePet",
|
||||
summary = "Deletes a pet",
|
||||
tags = { "pet" },
|
||||
value = "Deletes a pet",
|
||||
nickname = "deletePet",
|
||||
notes = "",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation"),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid pet value")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation"),
|
||||
@ApiResponse(code = 400, message = "Invalid pet value")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.DELETE,
|
||||
value = "/pet/{petId}"
|
||||
)
|
||||
default ResponseEntity<Void> deletePet(
|
||||
@ApiParam(value = "Pet id to delete", required = true) @PathVariable("petId") Long petId,
|
||||
@ApiParam(value = "") @RequestHeader(value = "api_key", required = false) String apiKey
|
||||
@Parameter(name = "petId", description = "Pet id to delete", required = true) @PathVariable("petId") Long petId,
|
||||
@Parameter(name = "api_key", description = "") @RequestHeader(value = "api_key", required = false) String apiKey
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -120,31 +119,28 @@ public interface PetApi {
|
||||
* or Invalid status value (status code 400)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "findPetsByStatus",
|
||||
summary = "Finds Pets by status",
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by status",
|
||||
nickname = "findPetsByStatus",
|
||||
notes = "Multiple status values can be provided with comma separated strings",
|
||||
response = Pet.class,
|
||||
responseContainer = "List",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = Pet.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Pet.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid status value")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Pet.class, responseContainer = "List"),
|
||||
@ApiResponse(code = 400, message = "Invalid status value")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/pet/findByStatus",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<List<Pet>> findPetsByStatus(
|
||||
@NotNull @ApiParam(value = "Status values that need to be considered for filter", required = true, allowableValues = "available, pending, sold") @Valid @RequestParam(value = "status", required = true) List<String> status
|
||||
@NotNull @Parameter(name = "status", description = "Status values that need to be considered for filter", required = true) @Valid @RequestParam(value = "status", required = true) List<String> status
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -175,31 +171,28 @@ public interface PetApi {
|
||||
* @deprecated
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "findPetsByTags",
|
||||
summary = "Finds Pets by tags",
|
||||
tags = { "pet" },
|
||||
value = "Finds Pets by tags",
|
||||
nickname = "findPetsByTags",
|
||||
notes = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.",
|
||||
response = Pet.class,
|
||||
responseContainer = "Set",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = Pet.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Pet.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid tag value")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Pet.class, responseContainer = "Set"),
|
||||
@ApiResponse(code = 400, message = "Invalid tag value")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/pet/findByTags",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<Set<Pet>> findPetsByTags(
|
||||
@NotNull @ApiParam(value = "Tags to filter by", required = true) @Valid @RequestParam(value = "tags", required = true) Set<String> tags
|
||||
@NotNull @Parameter(name = "tags", description = "Tags to filter by", required = true) @Valid @RequestParam(value = "tags", required = true) Set<String> tags
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -230,28 +223,29 @@ public interface PetApi {
|
||||
* or Pet not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "getPetById",
|
||||
summary = "Find pet by ID",
|
||||
tags = { "pet" },
|
||||
value = "Find pet by ID",
|
||||
nickname = "getPetById",
|
||||
notes = "Returns a single pet",
|
||||
response = Pet.class,
|
||||
authorizations = {
|
||||
@Authorization(value = "api_key")
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = Pet.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Pet.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid ID supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "Pet not found")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "api_key")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Pet.class),
|
||||
@ApiResponse(code = 400, message = "Invalid ID supplied"),
|
||||
@ApiResponse(code = 404, message = "Pet not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/pet/{petId}",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<Pet> getPetById(
|
||||
@ApiParam(value = "ID of pet to return", required = true) @PathVariable("petId") Long petId
|
||||
@Parameter(name = "petId", description = "ID of pet to return", required = true) @PathVariable("petId") Long petId
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -282,31 +276,27 @@ public interface PetApi {
|
||||
* or Validation exception (status code 405)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "updatePet",
|
||||
summary = "Update an existing pet",
|
||||
tags = { "pet" },
|
||||
value = "Update an existing pet",
|
||||
nickname = "updatePet",
|
||||
notes = "",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation"),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid ID supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "Pet not found"),
|
||||
@ApiResponse(responseCode = "405", description = "Validation exception")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation"),
|
||||
@ApiResponse(code = 400, message = "Invalid ID supplied"),
|
||||
@ApiResponse(code = 404, message = "Pet not found"),
|
||||
@ApiResponse(code = 405, message = "Validation exception")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PUT,
|
||||
value = "/pet",
|
||||
consumes = { "application/json", "application/xml" }
|
||||
)
|
||||
default ResponseEntity<Void> updatePet(
|
||||
@ApiParam(value = "Pet object that needs to be added to the store", required = true) @Valid @RequestBody Pet body
|
||||
@Parameter(name = "body", description = "Pet object that needs to be added to the store", required = true) @Valid @RequestBody Pet body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -322,30 +312,26 @@ public interface PetApi {
|
||||
* @return Invalid input (status code 405)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "updatePetWithForm",
|
||||
summary = "Updates a pet in the store with form data",
|
||||
tags = { "pet" },
|
||||
value = "Updates a pet in the store with form data",
|
||||
nickname = "updatePetWithForm",
|
||||
notes = "",
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "405", description = "Invalid input")
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 405, message = "Invalid input")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/pet/{petId}",
|
||||
consumes = { "application/x-www-form-urlencoded" }
|
||||
)
|
||||
default ResponseEntity<Void> updatePetWithForm(
|
||||
@ApiParam(value = "ID of pet that needs to be updated", required = true) @PathVariable("petId") Long petId,
|
||||
@ApiParam(value = "Updated name of the pet") @Valid @RequestParam(value = "name", required = false) String name,
|
||||
@ApiParam(value = "Updated status of the pet") @Valid @RequestParam(value = "status", required = false) String status
|
||||
@Parameter(name = "petId", description = "ID of pet that needs to be updated", required = true) @PathVariable("petId") Long petId,
|
||||
@Parameter(name = "name", description = "Updated name of the pet") @Valid @RequestParam(value = "name", required = false) String name,
|
||||
@Parameter(name = "status", description = "Updated status of the pet") @Valid @RequestParam(value = "status", required = false) String status
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -361,22 +347,19 @@ public interface PetApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "uploadFile",
|
||||
summary = "uploads an image",
|
||||
tags = { "pet" },
|
||||
value = "uploads an image",
|
||||
nickname = "uploadFile",
|
||||
notes = "",
|
||||
response = ModelApiResponse.class,
|
||||
authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = ModelApiResponse.class))
|
||||
})
|
||||
}
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "petstore_auth", scopes={ "write:pets", "read:pets" })
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/pet/{petId}/uploadImage",
|
||||
@@ -384,9 +367,9 @@ public interface PetApi {
|
||||
consumes = { "multipart/form-data" }
|
||||
)
|
||||
default ResponseEntity<ModelApiResponse> uploadFile(
|
||||
@ApiParam(value = "ID of pet to update", required = true) @PathVariable("petId") Long petId,
|
||||
@ApiParam(value = "Additional data to pass to server") @Valid @RequestParam(value = "additionalMetadata", required = false) String additionalMetadata,
|
||||
@ApiParam(value = "file to upload") @RequestPart(value = "file", required = false) MultipartFile file
|
||||
@Parameter(name = "petId", description = "ID of pet to update", required = true) @PathVariable("petId") Long petId,
|
||||
@Parameter(name = "additionalMetadata", description = "Additional data to pass to server") @Valid @RequestParam(value = "additionalMetadata", required = false) String additionalMetadata,
|
||||
@Parameter(name = "file", description = "file to upload") @RequestPart(value = "file", required = false) MultipartFile file
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -7,7 +7,14 @@ package org.openapitools.virtualan.api;
|
||||
|
||||
import java.util.Map;
|
||||
import org.openapitools.virtualan.model.Order;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -27,7 +34,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "store", description = "Access to Petstore orders")
|
||||
@Tag(name = "store", description = "Access to Petstore orders")
|
||||
@VirtualService
|
||||
public interface StoreApi {
|
||||
|
||||
@@ -44,22 +51,21 @@ public interface StoreApi {
|
||||
* or Order not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "deleteOrder",
|
||||
summary = "Delete purchase order by ID",
|
||||
tags = { "store" },
|
||||
value = "Delete purchase order by ID",
|
||||
nickname = "deleteOrder",
|
||||
notes = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors"
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Invalid ID supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "Order not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Invalid ID supplied"),
|
||||
@ApiResponse(code = 404, message = "Order not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.DELETE,
|
||||
value = "/store/order/{order_id}"
|
||||
)
|
||||
default ResponseEntity<Void> deleteOrder(
|
||||
@ApiParam(value = "ID of the order that needs to be deleted", required = true) @PathVariable("order_id") String orderId
|
||||
@Parameter(name = "order_id", description = "ID of the order that needs to be deleted", required = true) @PathVariable("order_id") String orderId
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -73,20 +79,19 @@ public interface StoreApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "getInventory",
|
||||
summary = "Returns pet inventories by status",
|
||||
tags = { "store" },
|
||||
value = "Returns pet inventories by status",
|
||||
nickname = "getInventory",
|
||||
notes = "Returns a map of status codes to quantities",
|
||||
response = Integer.class,
|
||||
responseContainer = "Map",
|
||||
authorizations = {
|
||||
@Authorization(value = "api_key")
|
||||
}
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Map.class))
|
||||
})
|
||||
},
|
||||
security = {
|
||||
@SecurityRequirement(name = "api_key")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Map.class, responseContainer = "Map")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/store/inventory",
|
||||
@@ -110,25 +115,26 @@ public interface StoreApi {
|
||||
* or Order not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "getOrderById",
|
||||
summary = "Find purchase order by ID",
|
||||
tags = { "store" },
|
||||
value = "Find purchase order by ID",
|
||||
nickname = "getOrderById",
|
||||
notes = "For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions",
|
||||
response = Order.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = Order.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Order.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid ID supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "Order not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Order.class),
|
||||
@ApiResponse(code = 400, message = "Invalid ID supplied"),
|
||||
@ApiResponse(code = 404, message = "Order not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/store/order/{order_id}",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<Order> getOrderById(
|
||||
@Min(1L) @Max(5L) @ApiParam(value = "ID of pet that needs to be fetched", required = true) @PathVariable("order_id") Long orderId
|
||||
@Min(1L) @Max(5L) @Parameter(name = "order_id", description = "ID of pet that needs to be fetched", required = true) @PathVariable("order_id") Long orderId
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -157,24 +163,25 @@ public interface StoreApi {
|
||||
* or Invalid Order (status code 400)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "placeOrder",
|
||||
summary = "Place an order for a pet",
|
||||
tags = { "store" },
|
||||
value = "Place an order for a pet",
|
||||
nickname = "placeOrder",
|
||||
notes = "",
|
||||
response = Order.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = Order.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = Order.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid Order")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Order.class),
|
||||
@ApiResponse(code = 400, message = "Invalid Order")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/store/order",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<Order> placeOrder(
|
||||
@ApiParam(value = "order placed for purchasing the pet", required = true) @Valid @RequestBody Order body
|
||||
@Parameter(name = "body", description = "order placed for purchasing the pet", required = true) @Valid @RequestBody Order body
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
|
||||
@@ -8,7 +8,14 @@ package org.openapitools.virtualan.api;
|
||||
import java.util.List;
|
||||
import java.time.OffsetDateTime;
|
||||
import org.openapitools.virtualan.model.User;
|
||||
import io.swagger.annotations.*;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.Parameter;
|
||||
import io.swagger.v3.oas.annotations.Parameters;
|
||||
import io.swagger.v3.oas.annotations.media.Content;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import io.virtualan.annotation.ApiVirtual;
|
||||
import io.virtualan.annotation.VirtualService;
|
||||
import org.springframework.http.HttpStatus;
|
||||
@@ -28,7 +35,7 @@ import javax.annotation.Generated;
|
||||
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
@Validated
|
||||
@Api(value = "user", description = "Operations about user")
|
||||
@Tag(name = "user", description = "Operations about user")
|
||||
@VirtualService
|
||||
public interface UserApi {
|
||||
|
||||
@@ -44,21 +51,20 @@ public interface UserApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "createUser",
|
||||
summary = "Create user",
|
||||
tags = { "user" },
|
||||
value = "Create user",
|
||||
nickname = "createUser",
|
||||
notes = "This can only be done by the logged in user."
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/user"
|
||||
)
|
||||
default ResponseEntity<Void> createUser(
|
||||
@ApiParam(value = "Created user object", required = true) @Valid @RequestBody User body
|
||||
@Parameter(name = "body", description = "Created user object", required = true) @Valid @RequestBody User body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -72,21 +78,20 @@ public interface UserApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "createUsersWithArrayInput",
|
||||
summary = "Creates list of users with given input array",
|
||||
tags = { "user" },
|
||||
value = "Creates list of users with given input array",
|
||||
nickname = "createUsersWithArrayInput",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/user/createWithArray"
|
||||
)
|
||||
default ResponseEntity<Void> createUsersWithArrayInput(
|
||||
@ApiParam(value = "List of user object", required = true) @Valid @RequestBody List<User> body
|
||||
@Parameter(name = "body", description = "List of user object", required = true) @Valid @RequestBody List<User> body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -100,21 +105,20 @@ public interface UserApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "createUsersWithListInput",
|
||||
summary = "Creates list of users with given input array",
|
||||
tags = { "user" },
|
||||
value = "Creates list of users with given input array",
|
||||
nickname = "createUsersWithListInput",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.POST,
|
||||
value = "/user/createWithList"
|
||||
)
|
||||
default ResponseEntity<Void> createUsersWithListInput(
|
||||
@ApiParam(value = "List of user object", required = true) @Valid @RequestBody List<User> body
|
||||
@Parameter(name = "body", description = "List of user object", required = true) @Valid @RequestBody List<User> body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -130,22 +134,21 @@ public interface UserApi {
|
||||
* or User not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "deleteUser",
|
||||
summary = "Delete user",
|
||||
tags = { "user" },
|
||||
value = "Delete user",
|
||||
nickname = "deleteUser",
|
||||
notes = "This can only be done by the logged in user."
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Invalid username supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "User not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Invalid username supplied"),
|
||||
@ApiResponse(code = 404, message = "User not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.DELETE,
|
||||
value = "/user/{username}"
|
||||
)
|
||||
default ResponseEntity<Void> deleteUser(
|
||||
@ApiParam(value = "The name that needs to be deleted", required = true) @PathVariable("username") String username
|
||||
@Parameter(name = "username", description = "The name that needs to be deleted", required = true) @PathVariable("username") String username
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -161,25 +164,26 @@ public interface UserApi {
|
||||
* or User not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "getUserByName",
|
||||
summary = "Get user by user name",
|
||||
tags = { "user" },
|
||||
value = "Get user by user name",
|
||||
nickname = "getUserByName",
|
||||
notes = "",
|
||||
response = User.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = User.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = User.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid username supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "User not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = User.class),
|
||||
@ApiResponse(code = 400, message = "Invalid username supplied"),
|
||||
@ApiResponse(code = 404, message = "User not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/user/{username}",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<User> getUserByName(
|
||||
@ApiParam(value = "The name that needs to be fetched. Use user1 for testing.", required = true) @PathVariable("username") String username
|
||||
@Parameter(name = "username", description = "The name that needs to be fetched. Use user1 for testing.", required = true) @PathVariable("username") String username
|
||||
) {
|
||||
getRequest().ifPresent(request -> {
|
||||
for (MediaType mediaType: MediaType.parseMediaTypes(request.getHeader("Accept"))) {
|
||||
@@ -209,25 +213,26 @@ public interface UserApi {
|
||||
* or Invalid username/password supplied (status code 400)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "loginUser",
|
||||
summary = "Logs user into the system",
|
||||
tags = { "user" },
|
||||
value = "Logs user into the system",
|
||||
nickname = "loginUser",
|
||||
notes = "",
|
||||
response = String.class
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation", content = {
|
||||
@Content(mediaType = "application/xml", schema = @Schema(implementation = String.class)),
|
||||
@Content(mediaType = "application/json", schema = @Schema(implementation = String.class))
|
||||
}),
|
||||
@ApiResponse(responseCode = "400", description = "Invalid username/password supplied")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation", response = String.class),
|
||||
@ApiResponse(code = 400, message = "Invalid username/password supplied")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/user/login",
|
||||
produces = { "application/xml", "application/json" }
|
||||
)
|
||||
default ResponseEntity<String> loginUser(
|
||||
@NotNull @ApiParam(value = "The user name for login", required = true) @Valid @RequestParam(value = "username", required = true) String username,
|
||||
@NotNull @ApiParam(value = "The password for login in clear text", required = true) @Valid @RequestParam(value = "password", required = true) String password
|
||||
@NotNull @Parameter(name = "username", description = "The user name for login", required = true) @Valid @RequestParam(value = "username", required = true) String username,
|
||||
@NotNull @Parameter(name = "password", description = "The password for login in clear text", required = true) @Valid @RequestParam(value = "password", required = true) String password
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
@@ -240,15 +245,14 @@ public interface UserApi {
|
||||
* @return successful operation (status code 200)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "logoutUser",
|
||||
summary = "Logs out current logged in user session",
|
||||
tags = { "user" },
|
||||
value = "Logs out current logged in user session",
|
||||
nickname = "logoutUser",
|
||||
notes = ""
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "200", description = "successful operation")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 200, message = "successful operation")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.GET,
|
||||
value = "/user/logout"
|
||||
@@ -271,23 +275,22 @@ public interface UserApi {
|
||||
* or User not found (status code 404)
|
||||
*/
|
||||
@ApiVirtual
|
||||
@ApiOperation(
|
||||
@Operation(
|
||||
operationId = "updateUser",
|
||||
summary = "Updated user",
|
||||
tags = { "user" },
|
||||
value = "Updated user",
|
||||
nickname = "updateUser",
|
||||
notes = "This can only be done by the logged in user."
|
||||
responses = {
|
||||
@ApiResponse(responseCode = "400", description = "Invalid user supplied"),
|
||||
@ApiResponse(responseCode = "404", description = "User not found")
|
||||
}
|
||||
)
|
||||
@ApiResponses({
|
||||
@ApiResponse(code = 400, message = "Invalid user supplied"),
|
||||
@ApiResponse(code = 404, message = "User not found")
|
||||
})
|
||||
@RequestMapping(
|
||||
method = RequestMethod.PUT,
|
||||
value = "/user/{username}"
|
||||
)
|
||||
default ResponseEntity<Void> updateUser(
|
||||
@ApiParam(value = "name that need to be deleted", required = true) @PathVariable("username") String username,
|
||||
@ApiParam(value = "Updated user object", required = true) @Valid @RequestBody User body
|
||||
@Parameter(name = "username", description = "name that need to be deleted", required = true) @PathVariable("username") String username,
|
||||
@Parameter(name = "body", description = "Updated user object", required = true) @Valid @RequestBody User body
|
||||
) {
|
||||
return new ResponseEntity<>(HttpStatus.NOT_IMPLEMENTED);
|
||||
|
||||
|
||||
@@ -4,14 +4,13 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class AdditionalPropertiesAnyType extends HashMap<String, Object> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -38,7 +37,7 @@ public class AdditionalPropertiesArray extends HashMap<String, List> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,14 +4,13 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class AdditionalPropertiesBoolean extends HashMap<String, Boolean> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
@@ -14,6 +12,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -85,7 +84,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_string", required = false)
|
||||
public Map<String, String> getMapString() {
|
||||
return mapString;
|
||||
}
|
||||
@@ -112,7 +111,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_number", required = false)
|
||||
public Map<String, BigDecimal> getMapNumber() {
|
||||
return mapNumber;
|
||||
}
|
||||
@@ -139,7 +138,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_integer", required = false)
|
||||
public Map<String, Integer> getMapInteger() {
|
||||
return mapInteger;
|
||||
}
|
||||
@@ -166,7 +165,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_boolean", required = false)
|
||||
public Map<String, Boolean> getMapBoolean() {
|
||||
return mapBoolean;
|
||||
}
|
||||
@@ -193,7 +192,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapArrayInteger
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_array_integer", required = false)
|
||||
public Map<String, List<Integer>> getMapArrayInteger() {
|
||||
return mapArrayInteger;
|
||||
}
|
||||
@@ -220,7 +219,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapArrayAnytype
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_array_anytype", required = false)
|
||||
public Map<String, List<Object>> getMapArrayAnytype() {
|
||||
return mapArrayAnytype;
|
||||
}
|
||||
@@ -247,7 +246,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapMapString
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_map_string", required = false)
|
||||
public Map<String, Map<String, String>> getMapMapString() {
|
||||
return mapMapString;
|
||||
}
|
||||
@@ -274,7 +273,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return mapMapAnytype
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_map_anytype", required = false)
|
||||
public Map<String, Map<String, Object>> getMapMapAnytype() {
|
||||
return mapMapAnytype;
|
||||
}
|
||||
@@ -293,7 +292,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return anytype1
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "anytype_1", required = false)
|
||||
public Object getAnytype1() {
|
||||
return anytype1;
|
||||
}
|
||||
@@ -312,7 +311,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return anytype2
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "anytype_2", required = false)
|
||||
public Object getAnytype2() {
|
||||
return anytype2;
|
||||
}
|
||||
@@ -331,7 +330,7 @@ public class AdditionalPropertiesClass {
|
||||
* @return anytype3
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "anytype_3", required = false)
|
||||
public Object getAnytype3() {
|
||||
return anytype3;
|
||||
}
|
||||
|
||||
@@ -4,14 +4,13 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class AdditionalPropertiesInteger extends HashMap<String, Integer> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -38,7 +37,7 @@ public class AdditionalPropertiesNumber extends HashMap<String, BigDecimal> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,14 +4,13 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class AdditionalPropertiesObject extends HashMap<String, Map> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,14 +4,13 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class AdditionalPropertiesString extends HashMap<String, String> {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -7,8 +7,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonSubTypes;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeInfo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.virtualan.model.BigCat;
|
||||
import org.openapitools.virtualan.model.Cat;
|
||||
import org.openapitools.virtualan.model.Dog;
|
||||
@@ -16,6 +14,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -55,7 +54,7 @@ public class Animal {
|
||||
* @return className
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "className", required = true)
|
||||
public String getClassName() {
|
||||
return className;
|
||||
}
|
||||
@@ -74,7 +73,7 @@ public class Animal {
|
||||
* @return color
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "color", required = false)
|
||||
public String getColor() {
|
||||
return color;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -47,7 +46,7 @@ public class ArrayOfArrayOfNumberOnly {
|
||||
* @return arrayArrayNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "ArrayArrayNumber", required = false)
|
||||
public List<List<BigDecimal>> getArrayArrayNumber() {
|
||||
return arrayArrayNumber;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -47,7 +46,7 @@ public class ArrayOfNumberOnly {
|
||||
* @return arrayNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "ArrayNumber", required = false)
|
||||
public List<BigDecimal> getArrayNumber() {
|
||||
return arrayNumber;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import org.openapitools.virtualan.model.ReadOnlyFirst;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -55,7 +54,7 @@ public class ArrayTest {
|
||||
* @return arrayOfString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "array_of_string", required = false)
|
||||
public List<String> getArrayOfString() {
|
||||
return arrayOfString;
|
||||
}
|
||||
@@ -82,7 +81,7 @@ public class ArrayTest {
|
||||
* @return arrayArrayOfInteger
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "array_array_of_integer", required = false)
|
||||
public List<List<Long>> getArrayArrayOfInteger() {
|
||||
return arrayArrayOfInteger;
|
||||
}
|
||||
@@ -109,7 +108,7 @@ public class ArrayTest {
|
||||
* @return arrayArrayOfModel
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "array_array_of_model", required = false)
|
||||
public List<List<ReadOnlyFirst>> getArrayArrayOfModel() {
|
||||
return arrayArrayOfModel;
|
||||
}
|
||||
|
||||
@@ -8,14 +8,13 @@ import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonSubTypes;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeInfo;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.virtualan.model.BigCatAllOf;
|
||||
import org.openapitools.virtualan.model.Cat;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -81,7 +80,7 @@ public class BigCat extends Cat {
|
||||
* @return kind
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "kind", required = false)
|
||||
public KindEnum getKind() {
|
||||
return kind;
|
||||
}
|
||||
|
||||
@@ -6,12 +6,11 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -77,7 +76,7 @@ public class BigCatAllOf {
|
||||
* @return kind
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "kind", required = false)
|
||||
public KindEnum getKind() {
|
||||
return kind;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -50,7 +49,7 @@ public class Capitalization {
|
||||
* @return smallCamel
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "smallCamel", required = false)
|
||||
public String getSmallCamel() {
|
||||
return smallCamel;
|
||||
}
|
||||
@@ -69,7 +68,7 @@ public class Capitalization {
|
||||
* @return capitalCamel
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "CapitalCamel", required = false)
|
||||
public String getCapitalCamel() {
|
||||
return capitalCamel;
|
||||
}
|
||||
@@ -88,7 +87,7 @@ public class Capitalization {
|
||||
* @return smallSnake
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "small_Snake", required = false)
|
||||
public String getSmallSnake() {
|
||||
return smallSnake;
|
||||
}
|
||||
@@ -107,7 +106,7 @@ public class Capitalization {
|
||||
* @return capitalSnake
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "Capital_Snake", required = false)
|
||||
public String getCapitalSnake() {
|
||||
return capitalSnake;
|
||||
}
|
||||
@@ -126,7 +125,7 @@ public class Capitalization {
|
||||
* @return scAETHFlowPoints
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "SCA_ETH_Flow_Points", required = false)
|
||||
public String getScAETHFlowPoints() {
|
||||
return scAETHFlowPoints;
|
||||
}
|
||||
@@ -145,7 +144,7 @@ public class Capitalization {
|
||||
* @return ATT_NAME
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "Name of the pet ")
|
||||
@Schema(name = "ATT_NAME", description = "Name of the pet ", required = false)
|
||||
public String getATTNAME() {
|
||||
return ATT_NAME;
|
||||
}
|
||||
|
||||
@@ -7,8 +7,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonSubTypes;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeInfo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.virtualan.model.Animal;
|
||||
import org.openapitools.virtualan.model.BigCat;
|
||||
import org.openapitools.virtualan.model.CatAllOf;
|
||||
@@ -16,6 +14,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -50,7 +49,7 @@ public class Cat extends Animal {
|
||||
* @return declawed
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "declawed", required = false)
|
||||
public Boolean getDeclawed() {
|
||||
return declawed;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class CatAllOf {
|
||||
* @return declawed
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "declawed", required = false)
|
||||
public Boolean getDeclawed() {
|
||||
return declawed;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -38,7 +37,7 @@ public class Category {
|
||||
* @return id
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "id", required = false)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
@@ -57,7 +56,7 @@ public class Category {
|
||||
* @return name
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "name", required = true)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -19,7 +18,7 @@ import javax.annotation.Generated;
|
||||
* Model for testing model with \"_class\" property
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Model for testing model with \"_class\" property")
|
||||
@Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property")
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class ClassModel {
|
||||
|
||||
@@ -36,7 +35,7 @@ public class ClassModel {
|
||||
* @return propertyClass
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "_class", required = false)
|
||||
public String getPropertyClass() {
|
||||
return propertyClass;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -35,7 +34,7 @@ public class Client {
|
||||
* @return client
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "client", required = false)
|
||||
public String getClient() {
|
||||
return client;
|
||||
}
|
||||
|
||||
@@ -7,14 +7,13 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonSubTypes;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeInfo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.virtualan.model.Animal;
|
||||
import org.openapitools.virtualan.model.DogAllOf;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -41,7 +40,7 @@ public class Dog extends Animal {
|
||||
* @return breed
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "breed", required = false)
|
||||
public String getBreed() {
|
||||
return breed;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class DogAllOf {
|
||||
* @return breed
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "breed", required = false)
|
||||
public String getBreed() {
|
||||
return breed;
|
||||
}
|
||||
|
||||
@@ -5,14 +5,13 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -112,7 +111,7 @@ public class EnumArrays {
|
||||
* @return justSymbol
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "just_symbol", required = false)
|
||||
public JustSymbolEnum getJustSymbol() {
|
||||
return justSymbol;
|
||||
}
|
||||
@@ -139,7 +138,7 @@ public class EnumArrays {
|
||||
* @return arrayEnum
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "array_enum", required = false)
|
||||
public List<ArrayEnumEnum> getArrayEnum() {
|
||||
return arrayEnum;
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@@ -6,13 +6,12 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.virtualan.model.OuterEnum;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -195,7 +194,7 @@ public class EnumTest {
|
||||
* @return enumString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "enum_string", required = false)
|
||||
public EnumStringEnum getEnumString() {
|
||||
return enumString;
|
||||
}
|
||||
@@ -214,7 +213,7 @@ public class EnumTest {
|
||||
* @return enumStringRequired
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "enum_string_required", required = true)
|
||||
public EnumStringRequiredEnum getEnumStringRequired() {
|
||||
return enumStringRequired;
|
||||
}
|
||||
@@ -233,7 +232,7 @@ public class EnumTest {
|
||||
* @return enumInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "enum_integer", required = false)
|
||||
public EnumIntegerEnum getEnumInteger() {
|
||||
return enumInteger;
|
||||
}
|
||||
@@ -252,7 +251,7 @@ public class EnumTest {
|
||||
* @return enumNumber
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "enum_number", required = false)
|
||||
public EnumNumberEnum getEnumNumber() {
|
||||
return enumNumber;
|
||||
}
|
||||
@@ -271,7 +270,7 @@ public class EnumTest {
|
||||
* @return outerEnum
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "outerEnum", required = false)
|
||||
public OuterEnum getOuterEnum() {
|
||||
return outerEnum;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -19,7 +18,7 @@ import javax.annotation.Generated;
|
||||
* Must be named `File` for test.
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Must be named `File` for test.")
|
||||
@Schema(name = "File", description = "Must be named `File` for test.")
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class File {
|
||||
|
||||
@@ -36,7 +35,7 @@ public class File {
|
||||
* @return sourceURI
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "Test capitalization")
|
||||
@Schema(name = "sourceURI", description = "Test capitalization", required = false)
|
||||
public String getSourceURI() {
|
||||
return sourceURI;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -42,7 +41,7 @@ public class FileSchemaTestClass {
|
||||
* @return file
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "file", required = false)
|
||||
public File getFile() {
|
||||
return file;
|
||||
}
|
||||
@@ -69,7 +68,7 @@ public class FileSchemaTestClass {
|
||||
* @return files
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "files", required = false)
|
||||
public List<File> getFiles() {
|
||||
return files;
|
||||
}
|
||||
|
||||
@@ -5,8 +5,6 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDate;
|
||||
import java.time.OffsetDateTime;
|
||||
@@ -17,6 +15,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -86,7 +85,7 @@ public class FormatTest {
|
||||
* @return integer
|
||||
*/
|
||||
@Min(10) @Max(100)
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "integer", required = false)
|
||||
public Integer getInteger() {
|
||||
return integer;
|
||||
}
|
||||
@@ -107,7 +106,7 @@ public class FormatTest {
|
||||
* @return int32
|
||||
*/
|
||||
@Min(20) @Max(200)
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "int32", required = false)
|
||||
public Integer getInt32() {
|
||||
return int32;
|
||||
}
|
||||
@@ -126,7 +125,7 @@ public class FormatTest {
|
||||
* @return int64
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "int64", required = false)
|
||||
public Long getInt64() {
|
||||
return int64;
|
||||
}
|
||||
@@ -147,7 +146,7 @@ public class FormatTest {
|
||||
* @return number
|
||||
*/
|
||||
@NotNull @Valid @DecimalMin("32.1") @DecimalMax("543.2")
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "number", required = true)
|
||||
public BigDecimal getNumber() {
|
||||
return number;
|
||||
}
|
||||
@@ -168,7 +167,7 @@ public class FormatTest {
|
||||
* @return _float
|
||||
*/
|
||||
@DecimalMin("54.3") @DecimalMax("987.6")
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "float", required = false)
|
||||
public Float getFloat() {
|
||||
return _float;
|
||||
}
|
||||
@@ -189,7 +188,7 @@ public class FormatTest {
|
||||
* @return _double
|
||||
*/
|
||||
@DecimalMin("67.8") @DecimalMax("123.4")
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "double", required = false)
|
||||
public Double getDouble() {
|
||||
return _double;
|
||||
}
|
||||
@@ -208,7 +207,7 @@ public class FormatTest {
|
||||
* @return string
|
||||
*/
|
||||
@Pattern(regexp = "/[a-z]/i")
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "string", required = false)
|
||||
public String getString() {
|
||||
return string;
|
||||
}
|
||||
@@ -227,7 +226,7 @@ public class FormatTest {
|
||||
* @return _byte
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "byte", required = true)
|
||||
public byte[] getByte() {
|
||||
return _byte;
|
||||
}
|
||||
@@ -246,7 +245,7 @@ public class FormatTest {
|
||||
* @return binary
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "binary", required = false)
|
||||
public org.springframework.core.io.Resource getBinary() {
|
||||
return binary;
|
||||
}
|
||||
@@ -265,7 +264,7 @@ public class FormatTest {
|
||||
* @return date
|
||||
*/
|
||||
@NotNull @Valid
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "date", required = true)
|
||||
public LocalDate getDate() {
|
||||
return date;
|
||||
}
|
||||
@@ -284,7 +283,7 @@ public class FormatTest {
|
||||
* @return dateTime
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "dateTime", required = false)
|
||||
public OffsetDateTime getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
@@ -303,7 +302,7 @@ public class FormatTest {
|
||||
* @return uuid
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "72f98069-206d-4f12-9f12-3d1e525a8e84", value = "")
|
||||
@Schema(name = "uuid", example = "72f98069-206d-4f12-9f12-3d1e525a8e84", required = false)
|
||||
public UUID getUuid() {
|
||||
return uuid;
|
||||
}
|
||||
@@ -322,7 +321,7 @@ public class FormatTest {
|
||||
* @return password
|
||||
*/
|
||||
@NotNull @Size(min = 10, max = 64)
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "password", required = true)
|
||||
public String getPassword() {
|
||||
return password;
|
||||
}
|
||||
@@ -341,7 +340,7 @@ public class FormatTest {
|
||||
* @return bigDecimal
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "BigDecimal", required = false)
|
||||
public BigDecimal getBigDecimal() {
|
||||
return bigDecimal;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -40,7 +39,7 @@ public class HasOnlyReadOnly {
|
||||
* @return bar
|
||||
*/
|
||||
|
||||
@ApiModelProperty(readOnly = true, value = "")
|
||||
@Schema(name = "bar", accessMode = Schema.AccessMode.READ_ONLY, required = false)
|
||||
public String getBar() {
|
||||
return bar;
|
||||
}
|
||||
@@ -59,7 +58,7 @@ public class HasOnlyReadOnly {
|
||||
* @return foo
|
||||
*/
|
||||
|
||||
@ApiModelProperty(readOnly = true, value = "")
|
||||
@Schema(name = "foo", accessMode = Schema.AccessMode.READ_ONLY, required = false)
|
||||
public String getFoo() {
|
||||
return foo;
|
||||
}
|
||||
|
||||
@@ -5,8 +5,6 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@@ -14,6 +12,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -95,7 +94,7 @@ public class MapTest {
|
||||
* @return mapMapOfString
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_map_of_string", required = false)
|
||||
public Map<String, Map<String, String>> getMapMapOfString() {
|
||||
return mapMapOfString;
|
||||
}
|
||||
@@ -122,7 +121,7 @@ public class MapTest {
|
||||
* @return mapOfEnumString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map_of_enum_string", required = false)
|
||||
public Map<String, InnerEnum> getMapOfEnumString() {
|
||||
return mapOfEnumString;
|
||||
}
|
||||
@@ -149,7 +148,7 @@ public class MapTest {
|
||||
* @return directMap
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "direct_map", required = false)
|
||||
public Map<String, Boolean> getDirectMap() {
|
||||
return directMap;
|
||||
}
|
||||
@@ -176,7 +175,7 @@ public class MapTest {
|
||||
* @return indirectMap
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "indirect_map", required = false)
|
||||
public Map<String, Boolean> getIndirectMap() {
|
||||
return indirectMap;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
@@ -17,6 +15,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -50,7 +49,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
|
||||
* @return uuid
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "uuid", required = false)
|
||||
public UUID getUuid() {
|
||||
return uuid;
|
||||
}
|
||||
@@ -69,7 +68,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
|
||||
* @return dateTime
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "dateTime", required = false)
|
||||
public OffsetDateTime getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
@@ -96,7 +95,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
|
||||
* @return map
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "map", required = false)
|
||||
public Map<String, Animal> getMap() {
|
||||
return map;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -20,7 +19,7 @@ import javax.annotation.Generated;
|
||||
* Model for testing model name starting with number
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Model for testing model name starting with number")
|
||||
@Schema(name = "200_response", description = "Model for testing model name starting with number")
|
||||
@JsonTypeName("200_response")
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class Model200Response {
|
||||
@@ -41,7 +40,7 @@ public class Model200Response {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public Integer getName() {
|
||||
return name;
|
||||
}
|
||||
@@ -60,7 +59,7 @@ public class Model200Response {
|
||||
* @return propertyClass
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "class", required = false)
|
||||
public String getPropertyClass() {
|
||||
return propertyClass;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -43,7 +42,7 @@ public class ModelApiResponse {
|
||||
* @return code
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "code", required = false)
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
@@ -62,7 +61,7 @@ public class ModelApiResponse {
|
||||
* @return type
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "type", required = false)
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
@@ -81,7 +80,7 @@ public class ModelApiResponse {
|
||||
* @return message
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "message", required = false)
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
@@ -1,85 +0,0 @@
|
||||
package org.openapitools.virtualan.model;
|
||||
|
||||
import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* Must be named `File` for test.
|
||||
*/
|
||||
@ApiModel(description = "Must be named `File` for test.")
|
||||
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class ModelFile {
|
||||
@JsonProperty("sourceURI")
|
||||
private String sourceURI;
|
||||
|
||||
public ModelFile sourceURI(String sourceURI) {
|
||||
this.sourceURI = sourceURI;
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test capitalization
|
||||
* @return sourceURI
|
||||
*/
|
||||
@ApiModelProperty(value = "Test capitalization")
|
||||
|
||||
|
||||
public String getSourceURI() {
|
||||
return sourceURI;
|
||||
}
|
||||
|
||||
public void setSourceURI(String sourceURI) {
|
||||
this.sourceURI = sourceURI;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) {
|
||||
return true;
|
||||
}
|
||||
if (o == null || getClass() != o.getClass()) {
|
||||
return false;
|
||||
}
|
||||
ModelFile _file = (ModelFile) o;
|
||||
return Objects.equals(this.sourceURI, _file.sourceURI);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(sourceURI);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append("class ModelFile {\n");
|
||||
|
||||
sb.append(" sourceURI: ").append(toIndentedString(sourceURI)).append("\n");
|
||||
sb.append("}");
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert the given object to string with each line indented by 4 spaces
|
||||
* (except the first line).
|
||||
*/
|
||||
private String toIndentedString(Object o) {
|
||||
if (o == null) {
|
||||
return "null";
|
||||
}
|
||||
return o.toString().replace("\n", "\n ");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class ModelList {
|
||||
* @return _123list
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "123-list", required = false)
|
||||
public String get123list() {
|
||||
return _123list;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -20,7 +19,7 @@ import javax.annotation.Generated;
|
||||
* Model for testing reserved words
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Model for testing reserved words")
|
||||
@Schema(name = "Return", description = "Model for testing reserved words")
|
||||
@JsonTypeName("Return")
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class ModelReturn {
|
||||
@@ -38,7 +37,7 @@ public class ModelReturn {
|
||||
* @return _return
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "return", required = false)
|
||||
public Integer getReturn() {
|
||||
return _return;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -19,7 +18,7 @@ import javax.annotation.Generated;
|
||||
* Model for testing model name same as property name
|
||||
*/
|
||||
|
||||
@ApiModel(description = "Model for testing model name same as property name")
|
||||
@Schema(name = "Name", description = "Model for testing model name same as property name")
|
||||
@Generated(value = "org.openapitools.codegen.languages.SpringCodegen")
|
||||
public class Name {
|
||||
|
||||
@@ -45,7 +44,7 @@ public class Name {
|
||||
* @return name
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "name", required = true)
|
||||
public Integer getName() {
|
||||
return name;
|
||||
}
|
||||
@@ -64,7 +63,7 @@ public class Name {
|
||||
* @return snakeCase
|
||||
*/
|
||||
|
||||
@ApiModelProperty(readOnly = true, value = "")
|
||||
@Schema(name = "snake_case", accessMode = Schema.AccessMode.READ_ONLY, required = false)
|
||||
public Integer getSnakeCase() {
|
||||
return snakeCase;
|
||||
}
|
||||
@@ -83,7 +82,7 @@ public class Name {
|
||||
* @return property
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "property", required = false)
|
||||
public String getProperty() {
|
||||
return property;
|
||||
}
|
||||
@@ -102,7 +101,7 @@ public class Name {
|
||||
* @return _123number
|
||||
*/
|
||||
|
||||
@ApiModelProperty(readOnly = true, value = "")
|
||||
@Schema(name = "123Number", accessMode = Schema.AccessMode.READ_ONLY, required = false)
|
||||
public Integer get123number() {
|
||||
return _123number;
|
||||
}
|
||||
|
||||
@@ -4,13 +4,12 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -36,7 +35,7 @@ public class NumberOnly {
|
||||
* @return justNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "JustNumber", required = false)
|
||||
public BigDecimal getJustNumber() {
|
||||
return justNumber;
|
||||
}
|
||||
|
||||
@@ -5,14 +5,13 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.time.OffsetDateTime;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -91,7 +90,7 @@ public class Order {
|
||||
* @return id
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "id", required = false)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
@@ -110,7 +109,7 @@ public class Order {
|
||||
* @return petId
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "petId", required = false)
|
||||
public Long getPetId() {
|
||||
return petId;
|
||||
}
|
||||
@@ -129,7 +128,7 @@ public class Order {
|
||||
* @return quantity
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "quantity", required = false)
|
||||
public Integer getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
@@ -148,7 +147,7 @@ public class Order {
|
||||
* @return shipDate
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "shipDate", required = false)
|
||||
public OffsetDateTime getShipDate() {
|
||||
return shipDate;
|
||||
}
|
||||
@@ -167,7 +166,7 @@ public class Order {
|
||||
* @return status
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "Order Status")
|
||||
@Schema(name = "status", description = "Order Status", required = false)
|
||||
public StatusEnum getStatus() {
|
||||
return status;
|
||||
}
|
||||
@@ -186,7 +185,7 @@ public class Order {
|
||||
* @return complete
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "complete", required = false)
|
||||
public Boolean getComplete() {
|
||||
return complete;
|
||||
}
|
||||
|
||||
@@ -4,13 +4,12 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -42,7 +41,7 @@ public class OuterComposite {
|
||||
* @return myNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "my_number", required = false)
|
||||
public BigDecimal getMyNumber() {
|
||||
return myNumber;
|
||||
}
|
||||
@@ -61,7 +60,7 @@ public class OuterComposite {
|
||||
* @return myString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "my_string", required = false)
|
||||
public String getMyString() {
|
||||
return myString;
|
||||
}
|
||||
@@ -80,7 +79,7 @@ public class OuterComposite {
|
||||
* @return myBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "my_boolean", required = false)
|
||||
public Boolean getMyBoolean() {
|
||||
return myBoolean;
|
||||
}
|
||||
|
||||
@@ -7,6 +7,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
|
||||
@@ -6,8 +6,6 @@ import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonValue;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.ArrayList;
|
||||
import java.util.LinkedHashSet;
|
||||
import java.util.List;
|
||||
@@ -18,6 +16,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -97,7 +96,7 @@ public class Pet {
|
||||
* @return id
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "id", required = false)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
@@ -116,7 +115,7 @@ public class Pet {
|
||||
* @return category
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "category", required = false)
|
||||
public Category getCategory() {
|
||||
return category;
|
||||
}
|
||||
@@ -135,7 +134,7 @@ public class Pet {
|
||||
* @return name
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "doggie", required = true, value = "")
|
||||
@Schema(name = "name", example = "doggie", required = true)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
@@ -159,7 +158,7 @@ public class Pet {
|
||||
* @return photoUrls
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "photoUrls", required = true)
|
||||
public Set<String> getPhotoUrls() {
|
||||
return photoUrls;
|
||||
}
|
||||
@@ -187,7 +186,7 @@ public class Pet {
|
||||
* @return tags
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "tags", required = false)
|
||||
public List<Tag> getTags() {
|
||||
return tags;
|
||||
}
|
||||
@@ -206,7 +205,7 @@ public class Pet {
|
||||
* @return status
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "pet status in the store")
|
||||
@Schema(name = "status", description = "pet status in the store", required = false)
|
||||
public StatusEnum getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -38,7 +37,7 @@ public class ReadOnlyFirst {
|
||||
* @return bar
|
||||
*/
|
||||
|
||||
@ApiModelProperty(readOnly = true, value = "")
|
||||
@Schema(name = "bar", accessMode = Schema.AccessMode.READ_ONLY, required = false)
|
||||
public String getBar() {
|
||||
return bar;
|
||||
}
|
||||
@@ -57,7 +56,7 @@ public class ReadOnlyFirst {
|
||||
* @return baz
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "baz", required = false)
|
||||
public String getBaz() {
|
||||
return baz;
|
||||
}
|
||||
|
||||
@@ -5,12 +5,11 @@ import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import com.fasterxml.jackson.annotation.JsonTypeName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -37,7 +36,7 @@ public class SpecialModelName {
|
||||
* @return $specialPropertyName
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "$special[property.name]", required = false)
|
||||
public Long get$SpecialPropertyName() {
|
||||
return $specialPropertyName;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -38,7 +37,7 @@ public class Tag {
|
||||
* @return id
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "id", required = false)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
@@ -57,7 +56,7 @@ public class Tag {
|
||||
* @return name
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name", required = false)
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -51,7 +50,7 @@ public class TypeHolderDefault {
|
||||
* @return stringItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "string_item", required = true)
|
||||
public String getStringItem() {
|
||||
return stringItem;
|
||||
}
|
||||
@@ -70,7 +69,7 @@ public class TypeHolderDefault {
|
||||
* @return numberItem
|
||||
*/
|
||||
@NotNull @Valid
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "number_item", required = true)
|
||||
public BigDecimal getNumberItem() {
|
||||
return numberItem;
|
||||
}
|
||||
@@ -89,7 +88,7 @@ public class TypeHolderDefault {
|
||||
* @return integerItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "integer_item", required = true)
|
||||
public Integer getIntegerItem() {
|
||||
return integerItem;
|
||||
}
|
||||
@@ -108,7 +107,7 @@ public class TypeHolderDefault {
|
||||
* @return boolItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "bool_item", required = true)
|
||||
public Boolean getBoolItem() {
|
||||
return boolItem;
|
||||
}
|
||||
@@ -132,7 +131,7 @@ public class TypeHolderDefault {
|
||||
* @return arrayItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(required = true, value = "")
|
||||
@Schema(name = "array_item", required = true)
|
||||
public List<Integer> getArrayItem() {
|
||||
return arrayItem;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -54,7 +53,7 @@ public class TypeHolderExample {
|
||||
* @return stringItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "what", required = true, value = "")
|
||||
@Schema(name = "string_item", example = "what", required = true)
|
||||
public String getStringItem() {
|
||||
return stringItem;
|
||||
}
|
||||
@@ -73,7 +72,7 @@ public class TypeHolderExample {
|
||||
* @return numberItem
|
||||
*/
|
||||
@NotNull @Valid
|
||||
@ApiModelProperty(example = "1.234", required = true, value = "")
|
||||
@Schema(name = "number_item", example = "1.234", required = true)
|
||||
public BigDecimal getNumberItem() {
|
||||
return numberItem;
|
||||
}
|
||||
@@ -92,7 +91,7 @@ public class TypeHolderExample {
|
||||
* @return floatItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "1.234", required = true, value = "")
|
||||
@Schema(name = "float_item", example = "1.234", required = true)
|
||||
public Float getFloatItem() {
|
||||
return floatItem;
|
||||
}
|
||||
@@ -111,7 +110,7 @@ public class TypeHolderExample {
|
||||
* @return integerItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "-2", required = true, value = "")
|
||||
@Schema(name = "integer_item", example = "-2", required = true)
|
||||
public Integer getIntegerItem() {
|
||||
return integerItem;
|
||||
}
|
||||
@@ -130,7 +129,7 @@ public class TypeHolderExample {
|
||||
* @return boolItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "true", required = true, value = "")
|
||||
@Schema(name = "bool_item", example = "true", required = true)
|
||||
public Boolean getBoolItem() {
|
||||
return boolItem;
|
||||
}
|
||||
@@ -154,7 +153,7 @@ public class TypeHolderExample {
|
||||
* @return arrayItem
|
||||
*/
|
||||
@NotNull
|
||||
@ApiModelProperty(example = "[0, 1, 2, 3]", required = true, value = "")
|
||||
@Schema(name = "array_item", example = "[0, 1, 2, 3]", required = true)
|
||||
public List<Integer> getArrayItem() {
|
||||
return arrayItem;
|
||||
}
|
||||
|
||||
@@ -4,12 +4,11 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -56,7 +55,7 @@ public class User {
|
||||
* @return id
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "id", required = false)
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
@@ -75,7 +74,7 @@ public class User {
|
||||
* @return username
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "username", required = false)
|
||||
public String getUsername() {
|
||||
return username;
|
||||
}
|
||||
@@ -94,7 +93,7 @@ public class User {
|
||||
* @return firstName
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "firstName", required = false)
|
||||
public String getFirstName() {
|
||||
return firstName;
|
||||
}
|
||||
@@ -113,7 +112,7 @@ public class User {
|
||||
* @return lastName
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "lastName", required = false)
|
||||
public String getLastName() {
|
||||
return lastName;
|
||||
}
|
||||
@@ -132,7 +131,7 @@ public class User {
|
||||
* @return email
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "email", required = false)
|
||||
public String getEmail() {
|
||||
return email;
|
||||
}
|
||||
@@ -151,7 +150,7 @@ public class User {
|
||||
* @return password
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "password", required = false)
|
||||
public String getPassword() {
|
||||
return password;
|
||||
}
|
||||
@@ -170,7 +169,7 @@ public class User {
|
||||
* @return phone
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "phone", required = false)
|
||||
public String getPhone() {
|
||||
return phone;
|
||||
}
|
||||
@@ -189,7 +188,7 @@ public class User {
|
||||
* @return userStatus
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "User Status")
|
||||
@Schema(name = "userStatus", description = "User Status", required = false)
|
||||
public Integer getUserStatus() {
|
||||
return userStatus;
|
||||
}
|
||||
|
||||
@@ -4,8 +4,6 @@ import java.net.URI;
|
||||
import java.util.Objects;
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonCreator;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -13,6 +11,7 @@ import org.openapitools.jackson.nullable.JsonNullable;
|
||||
import java.time.OffsetDateTime;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.*;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
|
||||
|
||||
import java.util.*;
|
||||
@@ -131,7 +130,7 @@ public class XmlItem {
|
||||
* @return attributeString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "string", value = "")
|
||||
@Schema(name = "attribute_string", example = "string", required = false)
|
||||
public String getAttributeString() {
|
||||
return attributeString;
|
||||
}
|
||||
@@ -150,7 +149,7 @@ public class XmlItem {
|
||||
* @return attributeNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "1.234", value = "")
|
||||
@Schema(name = "attribute_number", example = "1.234", required = false)
|
||||
public BigDecimal getAttributeNumber() {
|
||||
return attributeNumber;
|
||||
}
|
||||
@@ -169,7 +168,7 @@ public class XmlItem {
|
||||
* @return attributeInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "-2", value = "")
|
||||
@Schema(name = "attribute_integer", example = "-2", required = false)
|
||||
public Integer getAttributeInteger() {
|
||||
return attributeInteger;
|
||||
}
|
||||
@@ -188,7 +187,7 @@ public class XmlItem {
|
||||
* @return attributeBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "true", value = "")
|
||||
@Schema(name = "attribute_boolean", example = "true", required = false)
|
||||
public Boolean getAttributeBoolean() {
|
||||
return attributeBoolean;
|
||||
}
|
||||
@@ -215,7 +214,7 @@ public class XmlItem {
|
||||
* @return wrappedArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "wrapped_array", required = false)
|
||||
public List<Integer> getWrappedArray() {
|
||||
return wrappedArray;
|
||||
}
|
||||
@@ -234,7 +233,7 @@ public class XmlItem {
|
||||
* @return nameString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "string", value = "")
|
||||
@Schema(name = "name_string", example = "string", required = false)
|
||||
public String getNameString() {
|
||||
return nameString;
|
||||
}
|
||||
@@ -253,7 +252,7 @@ public class XmlItem {
|
||||
* @return nameNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "1.234", value = "")
|
||||
@Schema(name = "name_number", example = "1.234", required = false)
|
||||
public BigDecimal getNameNumber() {
|
||||
return nameNumber;
|
||||
}
|
||||
@@ -272,7 +271,7 @@ public class XmlItem {
|
||||
* @return nameInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "-2", value = "")
|
||||
@Schema(name = "name_integer", example = "-2", required = false)
|
||||
public Integer getNameInteger() {
|
||||
return nameInteger;
|
||||
}
|
||||
@@ -291,7 +290,7 @@ public class XmlItem {
|
||||
* @return nameBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "true", value = "")
|
||||
@Schema(name = "name_boolean", example = "true", required = false)
|
||||
public Boolean getNameBoolean() {
|
||||
return nameBoolean;
|
||||
}
|
||||
@@ -318,7 +317,7 @@ public class XmlItem {
|
||||
* @return nameArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name_array", required = false)
|
||||
public List<Integer> getNameArray() {
|
||||
return nameArray;
|
||||
}
|
||||
@@ -345,7 +344,7 @@ public class XmlItem {
|
||||
* @return nameWrappedArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "name_wrapped_array", required = false)
|
||||
public List<Integer> getNameWrappedArray() {
|
||||
return nameWrappedArray;
|
||||
}
|
||||
@@ -364,7 +363,7 @@ public class XmlItem {
|
||||
* @return prefixString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "string", value = "")
|
||||
@Schema(name = "prefix_string", example = "string", required = false)
|
||||
public String getPrefixString() {
|
||||
return prefixString;
|
||||
}
|
||||
@@ -383,7 +382,7 @@ public class XmlItem {
|
||||
* @return prefixNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "1.234", value = "")
|
||||
@Schema(name = "prefix_number", example = "1.234", required = false)
|
||||
public BigDecimal getPrefixNumber() {
|
||||
return prefixNumber;
|
||||
}
|
||||
@@ -402,7 +401,7 @@ public class XmlItem {
|
||||
* @return prefixInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "-2", value = "")
|
||||
@Schema(name = "prefix_integer", example = "-2", required = false)
|
||||
public Integer getPrefixInteger() {
|
||||
return prefixInteger;
|
||||
}
|
||||
@@ -421,7 +420,7 @@ public class XmlItem {
|
||||
* @return prefixBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "true", value = "")
|
||||
@Schema(name = "prefix_boolean", example = "true", required = false)
|
||||
public Boolean getPrefixBoolean() {
|
||||
return prefixBoolean;
|
||||
}
|
||||
@@ -448,7 +447,7 @@ public class XmlItem {
|
||||
* @return prefixArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "prefix_array", required = false)
|
||||
public List<Integer> getPrefixArray() {
|
||||
return prefixArray;
|
||||
}
|
||||
@@ -475,7 +474,7 @@ public class XmlItem {
|
||||
* @return prefixWrappedArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "prefix_wrapped_array", required = false)
|
||||
public List<Integer> getPrefixWrappedArray() {
|
||||
return prefixWrappedArray;
|
||||
}
|
||||
@@ -494,7 +493,7 @@ public class XmlItem {
|
||||
* @return namespaceString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "string", value = "")
|
||||
@Schema(name = "namespace_string", example = "string", required = false)
|
||||
public String getNamespaceString() {
|
||||
return namespaceString;
|
||||
}
|
||||
@@ -513,7 +512,7 @@ public class XmlItem {
|
||||
* @return namespaceNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "1.234", value = "")
|
||||
@Schema(name = "namespace_number", example = "1.234", required = false)
|
||||
public BigDecimal getNamespaceNumber() {
|
||||
return namespaceNumber;
|
||||
}
|
||||
@@ -532,7 +531,7 @@ public class XmlItem {
|
||||
* @return namespaceInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "-2", value = "")
|
||||
@Schema(name = "namespace_integer", example = "-2", required = false)
|
||||
public Integer getNamespaceInteger() {
|
||||
return namespaceInteger;
|
||||
}
|
||||
@@ -551,7 +550,7 @@ public class XmlItem {
|
||||
* @return namespaceBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "true", value = "")
|
||||
@Schema(name = "namespace_boolean", example = "true", required = false)
|
||||
public Boolean getNamespaceBoolean() {
|
||||
return namespaceBoolean;
|
||||
}
|
||||
@@ -578,7 +577,7 @@ public class XmlItem {
|
||||
* @return namespaceArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "namespace_array", required = false)
|
||||
public List<Integer> getNamespaceArray() {
|
||||
return namespaceArray;
|
||||
}
|
||||
@@ -605,7 +604,7 @@ public class XmlItem {
|
||||
* @return namespaceWrappedArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "namespace_wrapped_array", required = false)
|
||||
public List<Integer> getNamespaceWrappedArray() {
|
||||
return namespaceWrappedArray;
|
||||
}
|
||||
@@ -624,7 +623,7 @@ public class XmlItem {
|
||||
* @return prefixNsString
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "string", value = "")
|
||||
@Schema(name = "prefix_ns_string", example = "string", required = false)
|
||||
public String getPrefixNsString() {
|
||||
return prefixNsString;
|
||||
}
|
||||
@@ -643,7 +642,7 @@ public class XmlItem {
|
||||
* @return prefixNsNumber
|
||||
*/
|
||||
@Valid
|
||||
@ApiModelProperty(example = "1.234", value = "")
|
||||
@Schema(name = "prefix_ns_number", example = "1.234", required = false)
|
||||
public BigDecimal getPrefixNsNumber() {
|
||||
return prefixNsNumber;
|
||||
}
|
||||
@@ -662,7 +661,7 @@ public class XmlItem {
|
||||
* @return prefixNsInteger
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "-2", value = "")
|
||||
@Schema(name = "prefix_ns_integer", example = "-2", required = false)
|
||||
public Integer getPrefixNsInteger() {
|
||||
return prefixNsInteger;
|
||||
}
|
||||
@@ -681,7 +680,7 @@ public class XmlItem {
|
||||
* @return prefixNsBoolean
|
||||
*/
|
||||
|
||||
@ApiModelProperty(example = "true", value = "")
|
||||
@Schema(name = "prefix_ns_boolean", example = "true", required = false)
|
||||
public Boolean getPrefixNsBoolean() {
|
||||
return prefixNsBoolean;
|
||||
}
|
||||
@@ -708,7 +707,7 @@ public class XmlItem {
|
||||
* @return prefixNsArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "prefix_ns_array", required = false)
|
||||
public List<Integer> getPrefixNsArray() {
|
||||
return prefixNsArray;
|
||||
}
|
||||
@@ -735,7 +734,7 @@ public class XmlItem {
|
||||
* @return prefixNsWrappedArray
|
||||
*/
|
||||
|
||||
@ApiModelProperty(value = "")
|
||||
@Schema(name = "prefix_ns_wrapped_array", required = false)
|
||||
public List<Integer> getPrefixNsWrappedArray() {
|
||||
return prefixNsWrappedArray;
|
||||
}
|
||||
|
||||
@@ -1,60 +0,0 @@
|
||||
<!-- HTML for static distribution bundle build -->
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Swagger UI</title>
|
||||
<link rel="stylesheet" type="text/css" href="webjars/swagger-ui/swagger-ui.css" />
|
||||
<link rel="icon" type="image/png" href="webjars/swagger-ui/favicon-32x32.png" sizes="32x32" />
|
||||
<link rel="icon" type="image/png" href="webjars/swagger-ui/favicon-16x16.png" sizes="16x16" />
|
||||
<style>
|
||||
html
|
||||
{
|
||||
box-sizing: border-box;
|
||||
overflow: -moz-scrollbars-vertical;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
*,
|
||||
*:before,
|
||||
*:after
|
||||
{
|
||||
box-sizing: inherit;
|
||||
}
|
||||
|
||||
body
|
||||
{
|
||||
margin:0;
|
||||
background: #fafafa;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="swagger-ui"></div>
|
||||
|
||||
<script src="webjars/swagger-ui/swagger-ui-bundle.js" charset="UTF-8"> </script>
|
||||
<script src="webjars/swagger-ui/swagger-ui-standalone-preset.js" charset="UTF-8"> </script>
|
||||
<script>
|
||||
window.onload = function() {
|
||||
// Begin Swagger UI call region
|
||||
const ui = SwaggerUIBundle({
|
||||
configUrl: 'swagger-config.yaml',
|
||||
dom_id: '#swagger-ui',
|
||||
deepLinking: true,
|
||||
presets: [
|
||||
SwaggerUIBundle.presets.apis,
|
||||
SwaggerUIStandalonePreset
|
||||
],
|
||||
plugins: [
|
||||
SwaggerUIBundle.plugins.DownloadUrl
|
||||
],
|
||||
layout: "StandaloneLayout"
|
||||
});
|
||||
// End Swagger UI call region
|
||||
|
||||
window.ui = ui;
|
||||
};
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user