java.lang.Object
io.helidon.openapi.OpenAPISupport.Builder<SEOpenAPISupportBuilder>
io.helidon.openapi.SEOpenAPISupportBuilder
- All Implemented Interfaces:
Builder<SEOpenAPISupportBuilder,
,OpenAPISupport> Supplier<OpenAPISupport>
Builds
OpenAPISupport
in a Helidon SE environment.
The builder mostly delegates to an instance of Helidon's
OpenAPIConfigImpl.Builder
which in turn prepares a smallrye
OpenApiConfig
which is what the smallrye implementation uses to
control its behavior.
-
Field Summary
Fields inherited from class io.helidon.openapi.OpenAPISupport.Builder
CONFIG_KEY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddOperationServer
(String operationID, String operationServer) Adds an operation server for a given operation ID.addPathServer
(String path, String pathServer) Adds a path server for a given path.io.helidon.openapi.SEOpenAPISupport
build()
Build the instance from this builder.Assigns various OpenAPI settings from the specified openapiConfig
object.Set the app-provided OpenAPI model filter class.modelReader
(String className) Sets the app-provided model reader class.io.smallrye.openapi.api.OpenApiConfig
Returns the smallrye OpenApiConfig instance describing the set-up that will govern the smallrye OpenAPI behavior.Sets the servers which offer the endpoints in the OpenAPI document.Methods inherited from class io.helidon.openapi.OpenAPISupport.Builder
crossOriginConfig, indexViewsSupplier, staticFile, ui, validate, webContext
-
Constructor Details
-
SEOpenAPISupportBuilder
public SEOpenAPISupportBuilder()
-
-
Method Details
-
config
Assigns various OpenAPI settings from the specified openapiConfig
object.The
Config
object can specify web-context and static-file in addition to settings supported byOpenAPIConfigImpl.Builder
.- Overrides:
config
in classOpenAPISupport.Builder<SEOpenAPISupportBuilder>
- Parameters:
config
- the OpenAPIConfig
object possibly containing settings- Returns:
- updated builder instance
- Throws:
NullPointerException
- if the providedConfig
is null
-
build
public io.helidon.openapi.SEOpenAPISupport build()Description copied from interface:Builder
Build the instance from this builder.- Returns:
- instance of the built type
-
openAPIConfig
public io.smallrye.openapi.api.OpenApiConfig openAPIConfig()Description copied from class:OpenAPISupport.Builder
Returns the smallrye OpenApiConfig instance describing the set-up that will govern the smallrye OpenAPI behavior.- Specified by:
openAPIConfig
in classOpenAPISupport.Builder<SEOpenAPISupportBuilder>
- Returns:
OpenApiConfig
conveying how OpenAPI should behave
-
modelReader
Sets the app-provided model reader class.- Parameters:
className
- name of the model reader class- Returns:
- updated builder instance
-
filter
Set the app-provided OpenAPI model filter class.- Parameters:
className
- name of the filter class- Returns:
- updated builder instance
-
servers
Sets the servers which offer the endpoints in the OpenAPI document.- Parameters:
serverList
- comma-separated list of servers- Returns:
- updated builder instance
-
addOperationServer
Adds an operation server for a given operation ID.- Parameters:
operationID
- operation ID to which the server correspondsoperationServer
- name of the server to add for this operation- Returns:
- updated builder instance
-
addPathServer
Adds a path server for a given path.- Parameters:
path
- path to which the server correspondspathServer
- name of the server to add for this path- Returns:
- updated builder instance
-