# AsyncController.hpp
This File On Github
Ask A Question
API: latest
module: oatpp-swagger
#include "oatpp-swagger/AsyncController.hpp"
# AsyncController
Asynchronous Controller for Swagger-UI. Extends oatpp::web::server::api::ApiController.
Should be used with oatpp Async API and non-blocking I/O.
For more information about integrating swagger-ui in oatpp application see oatpp-swagger module.
Exposed endpoints:
- ENDPOINT_ASYNC("GET", "/api-docs/oas-3.0.0.json", Api) - Server Open API Specification.
- ENDPOINT_ASYNC("GET", "/swagger/ui", GetUIRoot) - Server Swagger-UI. (index.html).
- ENDPOINT_ASYNC("GET", "/swagger/{filename}", GetUIResource) - Serve Swagger-UI resources.
namespace oatpp { namespace swagger {
class AsyncController : public oatpp::web::server::api::ApiController {}
}}
# Methods
Return Type | Name | Summary |
---|---|---|
std::shared_ptr<AsyncController> | createShared | Create shared AsyncController. |
# AsyncController::createShared
Create shared AsyncController.
- @param endpointsList - oatpp::web::server::api::Endpoints
- @param documentInfo - oatpp::swagger::DocumentInfo.
- @param resources - oatpp::swagger::Resources.
- @return - AsyncController.
static std::shared_ptr<AsyncController> createShared(const web::server::api::Endpoints& endpointsList,
OATPP_COMPONENT(std::shared_ptr<oatpp::swagger::DocumentInfo>, documentInfo),
OATPP_COMPONENT(std::shared_ptr<oatpp::swagger::Resources>, resources))