Package net.officefloor.web.openapi
Class OpenApiWoofExtensionService
java.lang.Object
net.officefloor.web.openapi.OpenApiWoofExtensionService
- All Implemented Interfaces:
ServiceFactory<WoofExtensionService>,WoofExtensionService,WoofExtensionServiceFactory
public class OpenApiWoofExtensionService
extends Object
implements WoofExtensionService, WoofExtensionServiceFactory
WoofExtensionService to configure OpenAPI specification.- Author:
- Daniel Sagenschneider
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringDefault JSON path.static final StringDefault swagger path.static final StringDefault YAML path.static final StringPropertyname to disable OpenAPI.static final StringPropertyname to disable Swagger UI.static final StringPropertyname for the OpenAPI JSON path.static final StringPropertyname for the Swagger UI path.static final StringPropertyname for the OpenAPI YAML path. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateService(ServiceContext context) Creates the service.voidextend(WoofContext context) Extends theWebArchitect.
-
Field Details
-
PROPERTY_DISABLE_OPEN_API
Propertyname to disable OpenAPI. This is useful for different environments to be configured differently.- See Also:
-
PROPERTY_JSON_PATH
Propertyname for the OpenAPI JSON path.- See Also:
-
DEFAULT_JSON_PATH
Default JSON path.- See Also:
-
PROPERTY_YAML_PATH
Propertyname for the OpenAPI YAML path.- See Also:
-
DEFAULT_YAML_PATH
Default YAML path.- See Also:
-
PROPERTY_DISABLE_SWAGGER
Propertyname to disable Swagger UI. This is useful to only expose the OpenAPI specifications, as Swagger UI likely hosted elsewhere.- See Also:
-
PROPERTY_SWAGGER_PATH
Propertyname for the Swagger UI path.- See Also:
-
DEFAULT_SWAGGER_PATH
Default swagger path.- See Also:
-
-
Constructor Details
-
OpenApiWoofExtensionService
public OpenApiWoofExtensionService()
-
-
Method Details
-
createService
Description copied from interface:ServiceFactoryCreates the service.- Specified by:
createServicein interfaceServiceFactory<WoofExtensionService>- Parameters:
context-ServiceContext.- Returns:
- Service.
- Throws:
Throwable- If fails to create the service.
-
extend
Description copied from interface:WoofExtensionServiceExtends theWebArchitect.- Specified by:
extendin interfaceWoofExtensionService- Parameters:
context-WoofContext.- Throws:
Exception- If fails to extend.
-