public static IMiddlewareBuilder <CFTFileContext> UseTransformXSLT( this IMiddlewareBuilder <CFTFileContext> app, Action <XSLTransformContentOptions> configOption) { var options = new XSLTransformContentOptions(); configOption(options); app.UseMiddleware <XSLTransformContentMiddleWare, CFTFileContext>(options); return(app); }
public static IMiddlewareBuilder <CFTFileContext> UseRemove( this IMiddlewareBuilder <CFTFileContext> app, Action <RemoveFileOptions> configOption) { var options = new RemoveFileOptions(); configOption(options); app.UseMiddleware <RemoveFileMiddleWare, CFTFileContext>(options); return(app); }
/// <summary> /// Шаг проверки файла по XSD схеме. /// </summary> /// <param name="app">Сборщик мидлвар.</param> /// <param name="configOption">настройки для мидлвары</param> /// <returns>Сборщик мидлвар с добавленным шагом проверки по схеме.</returns> public static IMiddlewareBuilder <CFTFileContext> UseValidationXSD( this IMiddlewareBuilder <CFTFileContext> app, Action <ValidateByXSDOptions> configOption) { var options = new ValidateByXSDOptions(); configOption(options); app.UseMiddleware <ValidateByXSDMiddleWare, CFTFileContext>(options); return(app); }
public static IMiddlewareBuilder <CFTFileContext> UseTransformFileName( this IMiddlewareBuilder <CFTFileContext> app, Action <FileNameTransformOptions> configOption) { var options = new FileNameTransformOptions(); configOption(options); app.UseMiddleware <FileNameTransformMiddleWare, CFTFileContext>(options); return(app); }
public static IMiddlewareBuilder <TContext> UseMiddleware <TMiddleware, TContext>(this IMiddlewareBuilder <TContext> builder, params object[] args) where TContext : ContextBase { return(builder.UseMiddleware <TContext>(typeof(TMiddleware), args)); }