- C# and .NET Core Test Driven Development
- Ayobami Adewole
- 89字
- 2021-06-25 22:00:33
Program.cs
Like C# console applications, ASP.NET Core has the Program class, which is an important class that contains the entry point to the application. The file has the Main() method used to run the application and it is used to create an instance of WebHostBuilder for creating a host for the application. The Startup class to be used by the application is specified in the Main method:
public class Program
{
public static void Main(string[] args)
{
BuildWebHost(args).Run();
}
public static IWebHost BuildWebHost(string[] args) =>
WebHost.CreateDefaultBuilder(args)
.UseStartup<Startup>()
.Build();
}
推薦閱讀
- CMDB分步構(gòu)建指南
- ASP.NET Core 5.0開發(fā)入門與實(shí)戰(zhàn)
- Mastering phpMyAdmin 3.4 for Effective MySQL Management
- 數(shù)據(jù)結(jié)構(gòu)與算法JavaScript描述
- Swift 3 New Features
- JavaScript從入門到精通(第3版)
- Banana Pi Cookbook
- SSM輕量級(jí)框架應(yīng)用實(shí)戰(zhàn)
- Learning Data Mining with R
- Learn React with TypeScript 3
- Nginx實(shí)戰(zhàn):基于Lua語(yǔ)言的配置、開發(fā)與架構(gòu)詳解
- Django 5企業(yè)級(jí)Web應(yīng)用開發(fā)實(shí)戰(zhàn)(視頻教學(xué)版)
- IoT Projects with Bluetooth Low Energy
- 貫通Tomcat開發(fā)
- Mastering Apache Camel