Convenience helper that returns a ready-to-serve [`OpenApiDoc`].
(
sources: &[DescriptorSource<'_>],
info: &DocumentInfo<'_>,
ui: SwaggerUiConfig,
)
| 310 | |
| 311 | /// Convenience helper that returns a ready-to-serve [`OpenApiDoc`]. |
| 312 | pub fn build_openapi_doc( |
| 313 | sources: &[DescriptorSource<'_>], |
| 314 | info: &DocumentInfo<'_>, |
| 315 | ui: SwaggerUiConfig, |
| 316 | ) -> Result<OpenApiDoc> { |
| 317 | let spec = generate_document(sources, info)?; |
| 318 | Ok(OpenApiDoc::new(spec, ui)) |
| 319 | } |
| 320 | |
| 321 | fn build_operation( |
| 322 | service: &ServiceInfo, |
nothing calls this directly
no test coverage detected