Interface OpenApiFeatureConfig
- All Superinterfaces:
Prototype.Api, Prototype.Factory<OpenApiFeature>
- All Known Implementing Classes:
OpenApiFeatureConfig.BuilderBase.OpenApiFeatureConfigImpl
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classFluent API builder forOpenApiFeature.static classOpenApiFeatureConfig.BuilderBase<BUILDER extends OpenApiFeatureConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends OpenApiFeatureConfig>Fluent API builder base forOpenApiFeatureConfig. -
Method Summary
Modifier and TypeMethodDescriptionstatic OpenApiFeatureConfig.Builderbuilder()Create a new fluent API builder to customize configuration.static OpenApiFeatureConfig.Builderbuilder(OpenApiFeatureConfig instance) Create a new fluent API builder from an existing instance.static OpenApiFeatureConfigcreate()Create a new instance with default values.static OpenApiFeatureConfigCreate a new instance from configuration.Named generated document metadata sources to use, in the order configured.Generated document source handling mode.Operation ids to use for generated Java methods.booleanWhether generated document sources resolve annotation string values as Helidon config expressions at runtime.booleanSets whether the feature should be enabled.manager()OpenAPI manager.name()Name of this instance.OpenAPI version implementation for rendered generated or merged documents.booleanWhether to allow anybody to access the endpoint.roles()Hints for role names the user is expected to be in.Runtime service registry supplied to the builder.services()OpenAPI services.sockets()List of sockets to register this feature on.Runtime source configuration supplied to the builder.Path of the static OpenAPI document file.Web context path for the OpenAPI endpoint.doubleweight()Weight of the OpenAPI feature.Methods inherited from interface Prototype.Factory
buildModifier and TypeMethodDescriptionbuild()Create a new instance of the runtime type from this config object.
-
Method Details
-
builder
Create a new fluent API builder to customize configuration.- Returns:
- a new builder
-
builder
Create a new fluent API builder from an existing instance.- Parameters:
instance- an existing instance used as a base for the builder- Returns:
- a builder based on an instance
-
create
Create a new instance from configuration.- Parameters:
config- used to configure the new instance- Returns:
- a new instance configured from configuration
-
create
Create a new instance with default values.- Returns:
- a new instance
-
weight
double weight()Weight of the OpenAPI feature. This is quite low, to be registered after routing. 90.0.- Returns:
- weight of the feature
-
isEnabled
boolean isEnabled()Sets whether the feature should be enabled.- Returns:
trueif enabled,falseotherwise
-
webContext
-
staticFile
-
generatedMode
OpenApiGeneratedMode generatedMode()Generated document source handling mode.- Returns:
- generated document source handling mode
-
generatedResolveConfigExpressions
boolean generatedResolveConfigExpressions()Whether generated document sources resolve annotation string values as Helidon config expressions at runtime.When disabled, generated document sources use annotation string values literally. This is disabled by default because annotation text can be user-visible OpenAPI content.
- Returns:
- whether to resolve generated OpenAPI annotation string values as config expressions
-
generatedDocumentSources
Named generated document metadata sources to use, in the order configured.Sources generated from
@OpenApi.Documentuse the annotated type's dotted canonical type name. CustomOpenApiDocumentSourceservices must be qualified with@Service.Namedto be selected by name. Unqualified sources always participate when they support the document context and cannot be filtered with this option.- Returns:
- generated document metadata source names
-
generatedOperationIds
Operation ids to use for generated Java methods.Each key is a Java method signature consisting of the fully qualified class name,
#, the method name, and fully qualified parameter types separated by,. The value is the operation id to use for that method.- Returns:
- generated operation ids keyed by fully qualified Java method signature
-
openApiVersion
Optional<OpenApiVersion> openApiVersion()OpenAPI version implementation for rendered generated or merged documents.If not configured, service discovery selects the highest-weighted available OpenAPI version provider. This means that adding OpenAPI 3.1 or 3.2 support modules can change generated output to the highest available OpenAPI document version. Configure this option to pin the OpenAPI document version for generated output.
Static documents served directly by
OpenApiGeneratedMode.STATIC_ONLYor by a static hit inOpenApiGeneratedMode.STATIC_FIRSTare not re-rendered through this provider.- Returns:
- version implementation for generated or merged OpenAPI documents
-
services
-
manager
-
permitAll
boolean permitAll()Whether to allow anybody to access the endpoint.- Returns:
- whether to permit access to metrics endpoint to anybody, defaults to
true - See Also:
-
roles
-
name
String name()Name of this instance.- Returns:
- instance name, used when discovered from configuration
-
sockets
-
runtimeServiceRegistry
Optional<ServiceRegistry> runtimeServiceRegistry()Runtime service registry supplied to the builder.- Returns:
- runtime service registry
-
sourceRoot
-