Example #1
0
 public static ISnakeWebhostBuilder <TSettings> WithAutofac <TSettings>(
     this ISnakeWebhostBuilder <TSettings> snakeWebhostBuilder,
     IEnumerable <Module> modules,
     Action <IContainer, IApplicationBuilder, IHostingEnvironment, IEnumerable <ServiceDescriptor> > afterBuild) where TSettings : BaseSettings, new()
 {
     return(snakeWebhostBuilder.With((_) => new AutofacPart(modules, afterBuild)));
 }
Example #2
0
 public static ISnakeWebhostBuilder <TSettings> WithMvc <TSettings>(this ISnakeWebhostBuilder <TSettings> builder) where TSettings : BaseSettings, new()
 {
     return(builder.With((_) => new MvcPart()));
 }
Example #3
0
 public static ISnakeWebhostBuilder <TSettings> WithSerilog <TSettings>(this ISnakeWebhostBuilder <TSettings> snakeWebhostBuilder, LoggerConfiguration loggerConfiguration)
     where TSettings : BaseSettings, new()
 {
     return(snakeWebhostBuilder.With((_) => new SerilogPart(loggerConfiguration)));
 }
Example #4
0
 public static ISnakeWebhostBuilder <TSettings> WithSwagger <TSettings>(this ISnakeWebhostBuilder <TSettings> builder, string appName)
     where TSettings : BaseSettings, new()
 {
     return(builder.With((_) => new SwaggerPart(appName)));
 }