You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 lines
1.3 KiB

  1. using Microsoft.AspNetCore.Builder;
  2. using Microsoft.AspNetCore.Hosting;
  3. using Microsoft.AspNetCore.Mvc;
  4. using Microsoft.Extensions.Configuration;
  5. using Microsoft.Extensions.DependencyInjection;
  6. using Microsoft.Extensions.Hosting;
  7. using Microsoft.Extensions.Logging;
  8. using System;
  9. using System.Collections.Generic;
  10. using System.Linq;
  11. using System.Threading.Tasks;
  12. namespace SignatureAPI
  13. {
  14. public class Startup
  15. {
  16. public Startup(IConfiguration configuration)
  17. {
  18. Configuration = configuration;
  19. }
  20. public IConfiguration Configuration { get; }
  21. // This method gets called by the runtime. Use this method to add services to the container.
  22. public void ConfigureServices(IServiceCollection services)
  23. {
  24. services.AddControllers();
  25. }
  26. // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
  27. public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
  28. {
  29. if (env.IsDevelopment())
  30. {
  31. app.UseDeveloperExceptionPage();
  32. }
  33. app.UseRouting();
  34. app.UseAuthorization();
  35. app.UseEndpoints(endpoints =>
  36. {
  37. endpoints.MapControllers();
  38. });
  39. }
  40. }
  41. }