public static IRouteBuilder MapRequestHandler <THandler>(this IRouteBuilder builder, string template) where THandler : IWebServiceHandler { return(builder.MapPost(template, async context => { using (var handler = context.RequestServices.GetRequiredService <THandler>()) await XRoadLibMiddleware.Invoke(context, handler); })); }
private static async Task ExecuteWebServiceRequestDelegate(HttpContext context, IServiceManager serviceManager) { using (var handler = new WebServiceRequestHandler(context.RequestServices, serviceManager)) await XRoadLibMiddleware.Invoke(context, handler); }
private static async Task ExecuteWsdlRequestDelegate(HttpContext context, IServiceManager serviceManager) { using (var handler = new WebServiceDescriptionHandler(serviceManager)) await XRoadLibMiddleware.Invoke(context, handler); }