Exemple #1
0
 // This method gets called by the runtime. Use this method to add services to the container.
 public void ConfigureServices(IServiceCollection services)
 {
     services.AddMvc().AddFluentValidation(fvc => fvc.RegisterValidatorsFromAssemblyContaining <Startup>());
     // Register the Swagger generator, defining one or more Swagger documents
     services.AddSwaggerGen(c =>
     {
         c.SwaggerDoc("v1", new Info {
             Title = "RPS Calculations API", Version = "V1"
         });
     });
     services.AddOptions();
     services.Configure <ConfigLookupRoot>(Configuration);
     //Configure BL services
     ServicesInstaller.ConfigureServices(services);
 }
Exemple #2
0
        private static void RegisterServices(ContainerBuilder builder)
        {
            var servicesInstaller = new ServicesInstaller();

            servicesInstaller.Register(builder);
        }