HAKOM.Persistence.Http.Net Assembly
Provides HTTP-layer integration for the HAKOM persistence module, including model binding, OpenAPI documentation, and response handling for ordering, paging, and reference types.
Remarks
Section titled “Remarks”This assembly bridges the gap between the persistence core types (such as Order<TResult>, Range<TResult>, and IReference) and ASP.NET Core HTTP endpoints. It provides custom model binders that allow these types to be used directly as controller action parameters, Swagger/OpenAPI operation and schema filters for proper API documentation, and extension methods for setting range-related response headers.
Register persistence HTTP services via the extension methods in ContainerExtensions:
using HAKOM.Persistence.Http.Net.Api.Extensions;
container .UseOrderModelBinder(orderMappings) .UseRangeModelBinder<ITimeSeries>() .UseHttpContextDefaultStorageInformationProvider<ITimeSeriesReference>();Configure Swagger documentation via SwaggerGenOptionsExtensions:
services.AddSwaggerGen(options =>{ options.AddOrderFilter<ITimeSeries>(); options.AddRangeFilter<ITimeSeries>(); options.AddReferenceSchemaFilter();});| Namespaces | |
|---|---|
| HAKOM.Persistence.Http.Net.Api.Extensions | Extension methods for registering persistence HTTP services and configuring HTTP responses with persistence-related data. |
| HAKOM.Persistence.Http.Net.Api.Ordering | Interfaces for binding Order<TResult> items from HTTP query parameters. |
| HAKOM.Persistence.Http.Net.Api.Paging.Exceptions | Exception types related to HTTP range request processing for paged results. |
| HAKOM.Persistence.Http.Net.Api.References.Exceptions | Exception types related to resolving default storage information for references in the context of HTTP requests. |
| HAKOM.Persistence.Http.Net.Api.Serialization |
Was this page helpful?Thanks for your feedback!