.NET Core 与 ASP.NET Core [英] .NET Core vs ASP.NET Core

查看:38
本文介绍了.NET Core 与 ASP.NET Core的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

.NET Core 和 ASP.NET Core 到底有什么区别?

What exactly is the difference between .NET Core and ASP.NET Core?

它们是互斥的吗?我听说 ASP.NET Core 是建立在 .NET Core 之上的,但它也可以建立在完整的 .NET 框架之上.

Are they mutually exclusive? I heard ASP.NET Core is built on .NET Core, but it can also be built on the full .NET framework.

那么 ASP.NET Core 到底是什么?

So what exactly is ASP.NET Core?

推荐答案

Update 2020:请注意 ASP.NET Core 3 及更高版本现在依赖于 .NET Core,不能再用于.NET 框架.以下描述适用于 ASP.NET Core 1.x-2.x;ASP.NET Core 3.0 的层分离仍然适用,但 ASP.NET Core 层不能再用于 3.0+ 中的 .NET Framework 之上.

Update 2020: Do note that ASP.NET Core 3 and higher now depend on .NET Core and can no longer be used on .NET Framework. The below description is for ASP.NET Core 1.x-2.x; the layer separation still holds true for ASP.NET Core 3.0 but the ASP.NET Core layer can no longer be used on top of .NET Framework in 3.0+.

.NET Core 是一个运行时.它可以执行为其构建的应用程序.

.NET Core is a runtime. It can execute applications that are built for it.

ASP.NET Core 是一组库,它们构成了用于构建 Web 应用程序的框架.ASP.NET Core 库可用于 .NET Core 和完整的 .NET 框架"(Windows 已随附多年).

ASP.NET Core is a collection of libraries that form a Framework for building web applications. ASP.NET Core libraries can be used on both .NET Core and the "Full .NET Framework" (which has shipped with windows for many years).

令人困惑的部分是使用 ASP.NET Core 的库和工具的应用程序通常被称为ASP.NET Core 应用程序",理论上并没有说它是为 .NET Core 还是 .NET Core 构建的.NET 框架.因此,ASP.NET Core 应用程序"也是.NET Core 应用程序"或.NET Framework 应用程序".

The confusing part is that an application using the libraries and tools of ASP.NET Core is usually referred to as "ASP.NET Core Application", which in theory doesn't say if it is built for .NET Core or .NET Framework. So an "ASP.NET Core Application" is also a ".NET Core Application" or a ".NET Framework Application".

此图显示了所涉及技术的关系(取自

This image shows the relation of the involved technologies (taken from this blog post)

在这里您可以看到 ASP.NET Core 是构建在 .NET Framework 和 .NET Core 的之上",而ASP.NET"(现在通常称为经典 ASP.NET")是 .NET仅框架.

Here you can see that ASP.NET Core is built "on top of" both .NET Framework and .NET Core, while "ASP.NET" (now often referred to as "classic ASP.NET") is .NET Framework only.

这篇关于.NET Core 与 ASP.NET Core的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆