public static final class OpenAPISupport.Builder extends Object implements io.helidon.common.Builder<OpenAPISupport>
OpenAPISupport.
The builder mostly delegates to an instance of OpenAPIConfigImpl.Builder
which in turn prepares a smallrye OpenApiConfig which is what the
smallrye implementation uses to control its behavior.
If the app invokes both the config(io.helidon.config.Config) method and other methods for
setting individual attributes, the latest builder method invoked "wins" in
case of conflicts.
| Modifier and Type | Method and Description |
|---|---|
OpenAPISupport.Builder |
addOperationServer(String operationID,
String operationServer)
Adds an operation server for a given operation ID.
|
OpenAPISupport.Builder |
addPathServer(String path,
String pathServer)
Adds a path server for a given path.
|
OpenAPISupport |
build() |
OpenAPISupport.Builder |
config(Config config)
Set various builder attributes from the specified
Config object. |
OpenAPISupport.Builder |
enableAnnotationProcessing(boolean isEnabled)
Sets whether annotation processing for OpenAPI annotations should
be enabled.
|
OpenAPISupport.Builder |
filter(String className)
Set the app-provided OpenAPI model filter class.
|
OpenAPISupport.Builder |
modelReader(String className)
Sets the app-provided model reader class.
|
OpenAPISupport.Builder |
servers(String serverList)
Sets the servers which offer the endpoints in the OpenAPI document.
|
OpenAPISupport.Builder |
staticFile(String path)
Sets the location of the static OpenAPI document file.
|
OpenAPISupport.Builder |
webContext(String path)
Path under which to register OpenAPI endpoint on the web server.
|
public OpenAPISupport build()
build in interface io.helidon.common.Builder<OpenAPISupport>public OpenAPISupport.Builder config(Config config)
Config object.
The Config object can specify .web-context
and .static-file in addition to settings
supported by OpenAPIConfigImpl.Builder.
config - the Config object possibly containing settingspublic OpenAPISupport.Builder webContext(String path)
path - webContext to use, defaults to public OpenAPISupport.Builder staticFile(String path)
path - location of the static OpenAPI document filepublic OpenAPISupport.Builder modelReader(String className)
className - name of the model reader classpublic OpenAPISupport.Builder filter(String className)
className - name of the filter classpublic OpenAPISupport.Builder servers(String serverList)
serverList - comma-separated list of serverspublic OpenAPISupport.Builder addOperationServer(String operationID, String operationServer)
operationID - operation ID to which the server correspondsoperationServer - name of the server to add for this operationpublic OpenAPISupport.Builder addPathServer(String path, String pathServer)
path - path to which the server correspondspathServer - name of the server to add for this pathpublic OpenAPISupport.Builder enableAnnotationProcessing(boolean isEnabled)
isEnabled - whether annotation processing should be turned onCopyright © 2018–2019 Oracle Corporation. All rights reserved.