@RestController public class OpenApiResource extends AbstractOpenApiResource
| Constructor and Description |
|---|
OpenApiResource(OpenAPIBuilder openAPIBuilder,
AbstractRequestBuilder requestBuilder,
AbstractResponseBuilder responseBuilder,
OperationBuilder operationParser,
org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping requestMappingHandlerMapping,
Optional<ActuatorProvider> servletContextProvider,
Optional<List<OpenApiCustomiser>> openApiCustomisers) |
OpenApiResource(OpenAPIBuilder openAPIBuilder,
AbstractRequestBuilder requestBuilder,
AbstractResponseBuilder responseBuilder,
OperationBuilder operationParser,
org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping requestMappingHandlerMapping,
Optional<ActuatorProvider> servletContextProvider,
Optional<List<OpenApiCustomiser>> openApiCustomisers,
List<String> pathsToMatch,
List<String> packagesToScan) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
getPaths(Map<String,Object> restControllers) |
String |
openapiJson(javax.servlet.http.HttpServletRequest request,
String apiDocsUrl) |
String |
openapiYaml(javax.servlet.http.HttpServletRequest request,
String apiDocsUrl) |
calculatePath, getOpenApi, isPackageToScan, isPathToMatchpublic OpenApiResource(OpenAPIBuilder openAPIBuilder, AbstractRequestBuilder requestBuilder, AbstractResponseBuilder responseBuilder, OperationBuilder operationParser, org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping requestMappingHandlerMapping, Optional<ActuatorProvider> servletContextProvider, Optional<List<OpenApiCustomiser>> openApiCustomisers)
public OpenApiResource(OpenAPIBuilder openAPIBuilder, AbstractRequestBuilder requestBuilder, AbstractResponseBuilder responseBuilder, OperationBuilder operationParser, org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping requestMappingHandlerMapping, Optional<ActuatorProvider> servletContextProvider, Optional<List<OpenApiCustomiser>> openApiCustomisers, List<String> pathsToMatch, List<String> packagesToScan)
@GetMapping(value="${springdoc.api-docs.path:#{T(org.springdoc.core.Constants).DEFAULT_API_DOCS_URL}}",
produces="application/json")
public String openapiJson(javax.servlet.http.HttpServletRequest request,
@Value(value="${springdoc.api-docs.path:#{T(org.springdoc.core.Constants).DEFAULT_API_DOCS_URL}}")
String apiDocsUrl)
throws com.fasterxml.jackson.core.JsonProcessingException
com.fasterxml.jackson.core.JsonProcessingException@GetMapping(value="${springdoc.api-docs.path:#{T(org.springdoc.core.Constants).DEFAULT_API_DOCS_URL}}.yaml",
produces="application/vnd.oai.openapi")
public String openapiYaml(javax.servlet.http.HttpServletRequest request,
@Value(value="${springdoc.api-docs.path:#{T(org.springdoc.core.Constants).DEFAULT_API_DOCS_URL}}.yaml")
String apiDocsUrl)
throws com.fasterxml.jackson.core.JsonProcessingException
com.fasterxml.jackson.core.JsonProcessingExceptionprotected void getPaths(Map<String,Object> restControllers)
getPaths in class AbstractOpenApiResourceCopyright © 2020. All rights reserved.