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.

52 lines
1.5 KiB

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