Class OpenApiDocument
java.lang.Object
io.helidon.openapi.OpenApiDocument
Version-neutral OpenAPI document model.
The model is based on the latest supported OpenAPI shape. Version implementations render this model to their target OpenAPI version, omitting or translating some fields that do not exist in that target version. They do not provide complete conversion between OpenAPI versions. Callers must select a target version compatible with the features used in the document.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classOpenAPI document builder.static final classOpenAPI Callback Object.static final classOpenAPI callback builder.static final classOpenAPI Components Object.static final classOpenAPI components builder.static final classOpenAPI Contact Object.static final classOpenAPI contact builder.static final classOpenAPI Encoding Object.static final classOpenAPI encoding builder.static final classOpenAPI Example Object.static final classOpenAPI example builder.static final classOpenAPI External Documentation Object.static final classOpenAPI external documentation builder.static final classOpenAPI Header Object.static final classOpenAPI header builder.static final classOpenAPI Info Object.static final classOpenAPI info builder.static final classOpenAPI License Object.static final classOpenAPI license builder.static final classOpenAPI Link Object.static final classOpenAPI link builder.static final classOpenAPI Media Type Object.static final classOpenAPI media type builder.static final classOpenAPI Operation Object.static final classOpenAPI operation builder.static final classOpenAPI Parameter Object.static final classOpenAPI parameter builder.static final classOpenAPI Path Item Object.static final classOpenAPI path item builder.static final classOpenAPI Request Body Object.static final classOpenAPI request body builder.static final classOpenAPI Response Object.static final classOpenAPI response builder.static final classScheme requirement within an OpenAPI Security Requirement Object.static final classOpenAPI Security Requirement Object.static final classOpenAPI security requirement builder.static final classOpenAPI Security Scheme Object.static final classOpenAPI security scheme builder.static final classOpenAPI Server Object.static final classOpenAPI server builder.static final classOpenAPI Server Variable Object.static final classOpenAPI server variable builder.static final classOpenAPI Tag Object.static final classOpenAPI tag builder. -
Method Summary
Modifier and TypeMethodDescriptionstatic OpenApiDocument.Builderbuilder()Create a new builder.Components object.External documentation.info()Info object.booleanisEmpty()Whether this document has no model content.JSON Schema dialect URI.openapi()OpenAPI specification version declared by this document.paths()Path items keyed by OpenAPI path template.Security requirements.self()Document identity URI.servers()Servers.tags()Document tags.Convert this document model to a structured JSON object.webhooks()Webhooks keyed by name.
-
Method Details
-
builder
-
openapi
-
self
Document identity URI.A relative identity is resolved against the configured OpenAPI web context. When the identity is relative, Helidon cannot determine whether an absolute reference identifies this document because composition does not have the request scheme or authority. That combination is not supported; use an absolute document identity or relative references instead.
- Returns:
- document identity URI
-
jsonSchemaDialect
-
info
-
servers
-
paths
Path items keyed by OpenAPI path template.- Returns:
- path items
-
webhooks
-
components
Components object.- Returns:
- components object
-
securityRequirements
Security requirements.- Returns:
- security requirements
-
tags
-
externalDocs
External documentation.- Returns:
- external documentation
-
isEmpty
public boolean isEmpty()Whether this document has no model content.- Returns:
- whether this document is empty
-
toJsonObject
Convert this document model to a structured JSON object.- Returns:
- JSON object representation of this document
-