.NET 术语表.NET Glossary

此术语表的主要目的是阐明所选术语和缩写词的含义,这些词频繁出现在 .NET 文档中但没有定义。The primary goal of this glossary is to clarify meanings of selected terms and acronyms that appear frequently in the .NET documentation without definitions.


预编译器。Ahead-of-time compiler.

JIT 类似,此编译器还可将 IL 转换为机器代码。Similar to JIT, this compiler also translates IL to machine code. 与 JIT 编译相比,AOT 编译在应用程序执行前进行并且通常在不同计算机上执行。In contrast to JIT compilation, AOT compilation happens before the application is executed and is usually performed on a different machine. AOT 工具不会在运行时进行编译,因此它们不需要最大程度地减少编译所花费的时间。Because AOT tool chains don't compile at runtime, they don't have to minimize time spent compiling. 这意味着它们可花更多的时间进行优化。That means they can spend more time optimizing. 由于 AOT 的上下文是整个应用程序,因此 AOT 编译器还会执行跨模块链接和全程序分析,这意味着之后会进行所有引用并会生成单个可执行文件。Since the context of AOT is the entire application, the AOT compiler also performs cross-module linking and whole-program analysis, which means that all references are followed and a single executable is produced.

请参阅 CoreRT.NET NativeSee CoreRT and .NET Native.


随 .NET Framework 一起提供的原始 ASP.NET 实现。The original ASP.NET implementation that ships with the .NET Framework.

有时 ASP.NET 是一个涵盖性术语,指包含 ASP.NET Core 在内的两个 ASP.NET 实现。Sometimes ASP.NET is an umbrella term that refers to both ASP.NET implementations including ASP.NET Core. 该术语在任何给定实例中的含义取决于上下文。The meaning that the term carries in any given instance is determined by context. 若要指明不要使用 ASP.NET 表示这两种实现,请参考 ASP.NET 4.x。Refer to ASP.NET 4.x when you want to make it clear that you’re not using ASP.NET to mean both implementations.

请参阅 ASP.NET 文档See ASP.NET documentation.


.NET Core 上生成的跨平台、高性能、 开放源 ASP.NET 实现。A cross-platform, high-performance, open source implementation of ASP.NET built on .NET Core.

请参阅 ASP.NET Core 文档See ASP.NET Core documentation.


.dll/.exe 文件,其中包含一组可由应用程序或其他程序集调用的 API。A .dll/.exe file that can contain a collection of APIs that can be called by applications or other assemblies.

程序集可以包括接口、类、结构、枚举和委托等类型。An assembly may include types such as interfaces, classes, structures, enumerations, and delegates. 有时,项目的 bin 文件夹中的程序集被称为二进制文件。Assemblies in a project's bin folder are sometimes referred to as binaries. 另请参阅See also library.


公共语言运行时。Common Language Runtime.

确切含义取决于上下文,但它通常指 .NET Framework 的运行时。The exact meaning depends on the context, but this usually refers to the runtime of the .NET Framework. CLR 处理内存分配和管理。The CLR handles memory allocation and management. CLR 也是一个虚拟机,不仅可执行应用,还可使用 JIT 编译器快速生成和编译代码。The CLR is also a virtual machine that not only executes apps but also generates and compiles code on-the-fly using a JIT compiler. 当前的 Microsoft CLR 实现仅限 Windows。The current Microsoft CLR implementation is Windows only.


.NET Core 公共语言运行时。.NET Core Common Language Runtime.

此 CLR 是采用与 CLR 相同的基本代码生成的。This CLR is built from the same code base as the CLR. 最初,CoreCLR 是 Silverlight 的运行时,专为在多个平台(特别是 Windows 和 OS X)上运行而开发。CoreCLR 现属于 .NET Core 并表示 CLR 的简化版本。Originally, CoreCLR was the runtime of Silverlight and was designed to run on multiple platforms, specifically Windows and OS X. CoreCLR is now part of .NET Core and represents a simplified version of the CLR. 它仍是跨平台运行时,现包括针对许多 Linux 分发的支持。It's still a cross-platform runtime, now including support for many Linux distributions. CoreCLR 也是具有 JIT 和代码执行功能的虚拟机。CoreCLR is also a virtual machine with JIT and code execution capabilities.


.NET Core 基类库 (BCL).NET Core Base Class Library (BCL)

一组构成 System.*(在一定的程度上构成 Microsoft.*)命名空间的库。A set of libraries that comprise the System.* (and to a limited extent Microsoft.*) namespaces. BCL 是用于生成 ASP.NET Core 等较高级应用程序框架的较低级通用框架。The BCL is a general purpose, lower-level framework that higher-level application frameworks, such as ASP.NET Core, build on. .NET Core BCL 的源代码包含在 CoreFX 存储库中。The source code of the .NET Core BCL is contained in the CoreFX repository. 但大部分 .NET Core API 也可在 .NET Framework 中使用,因此可将 CoreFX 视为 .NET Framework BCL 的一个分支。However, the majority of the .NET Core APIs are also available in the .NET Framework, so you can think of CoreFX as a fork of the .NET Framework BCL.


.NET Core 运行时。.NET Core runtime.

与 CLR/CoreCLR 相比,CoreRT 不是虚拟机,这意味着它不包含用于快速生成并运行代码的功能,因为它不包括 JITIn contrast to the CLR/CoreCLR, CoreRT is not a virtual machine, which means it doesn't include the facilities to generate and run code on-the-fly because it doesn't include a JIT. 但它包含 GC 以及运行时类型标识 (RTTI) 和反射功能。It does, however, include the GC and the ability for runtime type identification (RTTI) and reflection. 只是由于设计有类型系统,因此并不需要元数据反射功能。However, its type system is designed so that metadata for reflection isn't required. 包含这些功能使它具有 AOT 工具链,该工具链可去除多余的元数据,更重要的是可识别应用不使用的代码。This enables having an AOT tool chain that can link away superfluous metadata and (more importantly) identify code that the app doesn't use. CoreRT 正在开发中。CoreRT is in development.

请参阅 .NET Native 和 CoreRT 简介See Intro to .NET Native and CoreRT


能够开发并执行可在多个不同操作系统(如 Linux、Windows 和 iOS)上使用的应用程序,而无需专门针对每个操作系统进行重新编写。The ability to develop and execute an application that can be used on multiple different operating systems, such as Linux, Windows and iOS, without having to re-write specifically for each one. 这样,可以在不同平台上的应用程序之间重复使用代码并保持一致性。This enables code re-use and consistency between applications on different platforms.


所有针对给定技术生成和运行应用程序的运行时软件、开发工具和社区资源。All of the runtime software, development tools, and community resources that are used to build and run applications for a given technology.

在所包含的第三方应用和库方面,术语“.NET 生态系统”不同于类似的“.NET 堆栈”等术语。The term ".NET ecosystem" differs from similar terms such as ".NET stack" in its inclusion of third-party apps and libraries. 请看以下这一句示例:Here's an example in a sentence:

  • “推出 .NET Standard 的背后动机是要提高 .NET 生态系统中的一致性。”"The motivation behind the .NET Standard is to establish greater uniformity in the .NET ecosystem."


一般指一个综合 API 集合,便于开发和部署基于特定技术的应用程序。In general, a comprehensive collection of APIs that facilitates development and deployment of applications that are based on a particular technology. 从此常规意义上来说,ASP.NET Core 和 Windows 窗体都是示例应用程序框架。In this general sense, ASP.NET Core and Windows Forms are examples of application frameworks. 另请参阅See also library.

“框架”一词在以下术语中有更具体的技术含义:The word "framework" has a more specific technical meaning in the following terms:

在现有的文档中,“框架”有时指 .NET 的实现In the existing documentation, "framework" sometimes refers to an implementation of .NET. 例如,某文章可能会将 .NET Core 称为框架。For example, an article may call .NET Core a framework. 我们计划从文档中去掉这种令人困惑的用法。We plan to eliminate this confusing usage from the documentation.


垃圾回收器。Garbage collector.

垃圾回收器是自动内存管理的实现。The garbage collector is an implementation of automatic memory management. GC 可释放对象占用的不再使用的内存。The GC frees memory occupied by objects that are no longer in use.

请参阅垃圾回收See Garbage Collection.


中间语言。Intermediate language.

C# 等较高级的 .NET 语言编译为称为中间语言 (IL) 的硬件无关性指令集。Higher-level .NET languages, such as C#, compile down to a hardware-agnostic instruction set, which is called Intermediate Language (IL). IL 有时被称为 MSIL (Microsoft IL) 或 CIL(通用 IL)。IL is sometimes referred to as MSIL (Microsoft IL) or CIL (Common IL).


实时编译器。Just-in-time compiler.

AOT 类似,此编译器将 IL 转换为处理器可理解的计算机代码。Similar to AOT, this compiler translates IL to machine code that the processor understands. 与 AOT 不同,JIT 编译在需要运行代码的同一台计算机上按需执行。Unlike AOT, JIT compilation happens on demand and is performed on the same machine that the code needs to run on. 由于 JIT 编译在应用程序的执行过程中发生,因此编译时是运行时的一部分。Since JIT compilation occurs during execution of the application, compile time is part of the run time. 因此,JIT 编译器需要平衡优化代码所花费的时间与生成代码时可节约的时间。Thus, JIT compilers have to balance time spent optimizing code against the savings that the resulting code can produce. 但 JIT 知道实际硬件,这样开发人员就无需提供不同的实现。But a JIT knows the actual hardware and can free developers from having to ship different implementations.

.NET 实现implementation of .NET

.NET 的实现包括以下项:An implementation of .NET includes the following:

  • 一个或多个运行时。One or more runtimes. 示例:CLR、CoreCLR、CoreRT。Examples: CLR, CoreCLR, CoreRT.
  • 实现 .NET Standard 的某版本并且可能包含其他 API 的类库。A class library that implements a version of the .NET Standard and may include additional APIs. 示例:.NET Framework 基类库、.NET Core 基类库。Examples: .NET Framework Base Class Library, .NET Core Base Class Library.
  • 可选择包含一个或多个应用程序框架。Optionally, one or more application frameworks. 示例:ASP.NET、Windows 窗体和 WPF 包含在 .NET Framework 中。Examples: ASP.NET, Windows Forms, and WPF are included in the .NET Framework.
  • 可包含开发工具。Optionally, development tools. 某些开发工具在多个实现之间共享。Some development tools are shared among multiple implementations.

.NET 实现的示例:Examples of .NET implementations:


可由应用或其他库调用的 API 集合。A collection of APIs that can be called by apps or other libraries. .NET 库由一个或多个程序集组成。A .NET library is composed of one or more assemblies.

词库和框架通常作同义词使用。The words library and framework are often used synonymously.


一个 NuGet 包,没有自己的库,而只是一个依赖项列表。A NuGet package that has no library of its own but is only a list of dependencies. 所含包可选择建立目标框架的 API。The included packages can optionally establish the API for a target framework.

请参阅包、元包和框架See Packages, Metapackages and Frameworks


Mono 是主要在需要小型运行时使用的开放源、跨平台 .NET 实现。Mono is an open source, cross-platform .NET implementation that is mainly used when a small runtime is required. 它是运行时,在 Android、Mac、iOS、tvOS 和 watchOS 上为 Xamarin 应用程序提供技术支持,主要针对内存占用少的应用程序。It is the runtime that powers Xamarin applications on Android, Mac, iOS, tvOS and watchOS and is focused primarily on apps that require a small footprint.

它支持所有当前已发布的 .NET Standard 版本。It supports all of the currently published .NET Standard versions.

以前,Mono 实现更大的 .NET Framework API 并模拟一些 Unix 上最常用的功能。Historically, Mono implemented the larger API of the .NET Framework and emulated some of the most popular capabilities on Unix. 有时使用它运行依赖 Unix 上的这些功能的 .NET 应用程序。It is sometimes used to run .NET applications that rely on those capabilities on Unix.

Mono 通常与实时编译器一起使用,但它也提供在 iOS 之类的平台使用的完整静态编译器(预先编译)。Mono is typically used with a just-in-time compiler, but it also features a full static compiler (ahead-of-time compilation) that is used on platforms like iOS.

若要了解有关 Mono 的详细信息,请参阅 Mono 文档To learn more about Mono, see the Mono documentation.


.NET Standard 和所有 .NET 实现及工作负荷的涵盖性术语。The umbrella term for .NET Standard and all .NET implementations and workloads. 始终采用大写形式,请勿使用“.Net”。Always capitalized, never ".Net".

请参阅 .NET 指南See the .NET Guide

.NET Core.NET Core

一种跨平台、高性能的开放源 .NET 实现。A cross-platform, high-performance, open source implementation of .NET. 包括 Core 公共语言运行时 (CoreCLR)、Core AOT 运行时(正在开发的 CoreRT)、Core 基类库和 Core SDK。Includes the Core Common Language Runtime (CoreCLR), the Core AOT Runtime (CoreRT, in development), the Core Base Class Library, and the Core SDK.

请参阅 .NET CoreSee .NET Core.


用于开发 .NET Core 应用程序的跨平台工具链。A cross-platform toolchain for developing .NET Core applications.

请参阅 .NET Core 命令行接口 (CLI) 工具See .NET Core command-line interface (CLI) tools.


一组库和工具,开发人员可用其创建 .NET Core 应用程序和库。A set of libraries and tools that allow developers to create .NET Core applications and libraries. 包括用于生成应用的 .NET Core CLI、用于生成和运行应用的 .NET Core 库以及运行 CLI 命令和运行应用程序的 dotnet 可执行文件 (dotnet.exe)。Includes the .NET Core CLI for building apps, .NET Core libraries and runtime for building and running apps, and the dotnet executable (dotnet.exe) that runs CLI commands and runs applications.

请参阅 .NET Core SDK 概述See .NET Core SDK Overview.

.NET Framework.NET Framework

仅在 Windows 上运行的 .NET 实现。An implementation of .NET that runs only on Windows. 包括公共语言运行时 (CLR)、基类库和 ASP.NET、Windows 窗体和 WPF 之类的应用程序框架库。Includes the Common Language Runtime (CLR), the Base Class Library, and application framework libraries such as ASP.NET, Windows Forms, and WPF.

请查阅 .NET Framework 指南See .NET Framework Guide.

.NET Native.NET Native

编译器工具链,可预先 (AOT) 生成,而非实时 (JIT) 生成本机代码。A compiler tool chain that produces native code ahead-of-time (AOT), as opposed to just-in-time (JIT).

编译采用与 C++ 编译器和链接器类似的工作方式在开发人员计算机上进行。Compilation happens on the developer's machine similar to the way a C++ compiler and linker works. 它删除了未使用的代码,留出更多时间进行优化。It removes unused code and spends more time optimizing it. 它从库中提取代码,将它们合并到可执行文件中。It extracts code from libraries and merges them into the executable. 结果是表示整个应用的单个模块。The result is a single module that represents the entire app.

UWP 是 .NET Native 支持的首个应用程序框架。UWP was the first application framework supported by .NET Native. 现在,我们支持为 Windows、macOS 和 Linux 生成本机控制台应用。Now, we support building native console apps for Windows, macOS, and Linux.

请参阅 .NET Native 和 CoreRT 简介See Intro to .NET Native and CoreRT

.NET Standard.NET Standard

在每个 .NET 实现中都可用的 .NET API 正式规范。A formal specification of .NET APIs that are available in each .NET implementation.

.NET Standard 规范有时被称为文档中的库。The .NET Standard specification is sometimes called a library in the documentation. 由于库不仅包括规范(接口),还包括 API 实现,所以会误将 .NET Standard 称为“库”。Because a library includes API implementations, not only specifications (interfaces), it's misleading to call .NET Standard a "library." 我们计划从本文档中去除该用法,引用 .NET Standard 元包 (NETStandard.Library) 的名称除外。We plan to eliminate that usage from the documentation, except in reference to the name of the .NET Standard metapackage (NETStandard.Library).

请参阅 .NET StandardSee .NET Standard.


本机(映像)生成。Native (image) generation.

可将此方法视为永久性 JIT 编译器。You can think of this technology as a persistent JIT compiler. 它通常在执行代码的计算机上编译该代码,但通常在安装时进行编译。It usually compiles code on the machine where the code is executed, but compilation typically occurs at install time.


NuGet 包 — 或只是一个包 — 是一个 .zip 文件,其中具有一个或多个名称相同的程序集以及作者姓名等其他元数据。A NuGet package — or just a package — is a .zip file with one or more assemblies of the same name along with additional metadata such as the author name.

.zip 文件的扩展名为 .nupkg,且可以包含在多个目标框架和版本中使用的资产(如 .dll 文件和 .xml 文件)。The .zip file has a .nupkg extension and may contain assets, such as .dll files and .xml files, for use with multiple target frameworks and versions. 在应用或库中安装时,会根据应用或库指定的目标框架选择相应的资产。When installed in an app or library, the appropriate assets are selected based on the target framework specified by the app or library. 定义接口的资产位于 ref 文件夹,而定义实现的资产位于 lib文件夹。The assets that define the interface are in the ref folder, and the assets that define the implementation are in the lib folder.


操作系统以及运行它的硬件,例如 Windows、macOS、Linux、iOS 和 Android。An operating system and the hardware it runs on, such as Windows, macOS, Linux, iOS, and Android.

下面是在句子中使用的示例:Here are examples of usage in sentences:

  • “.NET Core 是一个跨平台 .NET 实现。”".NET Core is a cross-platform implementation of .NET."
  • “PCL 配置文件代表 Microsoft 平台,而 .NET Standard 与平台无关。”"PCL profiles represent Microsoft platforms, while the .NET Standard is agnostic to platform."

.NET 文档经常使用“.NET 平台”表示一个 .NET 实现或包括所有实现的 .NET 堆栈。The .NET documentation frequently uses ".NET platform" to mean either an implementation of .NET or the .NET stack including all implementations. 这两种用法往往会与主(OS/硬件)含义混淆,因此我们计划从文档中去除这些用法。Both of these usages tend to get confused with the primary (OS/hardware) meaning, so we plan to eliminate these usages from the documentation.

Runtime — 运行时runtime

用于托管程序的执行环境。The execution environment for a managed program.

操作系统属于运行时环境,但不属于 .NET 运行时。The OS is part of the runtime environment but is not part of the .NET runtime. 下面是 .NET 运行时的一些示例:Here are some examples of .NET runtimes:

  • 公共语言运行时 (CLR)Common Language Runtime (CLR)
  • Core 公共语言运行时 (CoreCLR)Core Common Language Runtime (CoreCLR)
  • .NET Native(适用于 UWP).NET Native (for UWP)
  • Mono 运行时Mono runtime

.NET 文档有时使用“运行时”表示 .NET 的实现。The .NET documentation sometimes uses "runtime" to mean an implementation of .NET. 例如,在以下句子中应使用“实现”替换“运行时”:For example, in the following sentences "runtime" should be replaced with "implementation":

  • “各种 .NET 运行时实现特定版本的 .NET Standard。”"The various .NET runtimes implement specific versions of .NET Standard."
  • “计划在多个运行时上运行的库应将此框架作为目标。”"Libraries that are intended to run on multiple runtimes should target this framework." (参阅 .NET Standard)(referring to .NET Standard)
  • “各种 .NET 运行时实现特定版本的 .NET Standard。"The various .NET runtimes implement specific versions of .NET Standard. 每个 .NET 运行时版本都将会公布它所支持的最高 .NET Standard 版本...”Each .NET runtime version advertises the highest .NET Standard version it supports …"

我们计划消除此不一致的用法。We plan to eliminate this inconsistent usage.


一组编程方法,一起用于生成并运行应用程序。A set of programming technologies that are used together to build and run applications.

“.NET 堆栈”指 .NET Standard 和所有 .NET 实现。"The .NET stack" refers to the .NET Standard and all .NET implementations. 短语“一个 .NET 堆栈”可能指一种 .NET 实现。The phrase "a .NET stack" may refer to one implementation of .NET.

Target Framework — 目标 Frameworktarget framework

.NET 应用或库依赖的 API 集合。The collection of APIs that a .NET app or library relies on.

应用或库可将某版本的 .NET Standard(例如 .NET Standard 2.0)作为目标,这是所有 .NET 实现中一组标准化 API 的规范。An app or library can target a version of .NET Standard (for example, .NET Standard 2.0), which is specification for a standardized set of APIs across all .NET implementations. 应用或库还能以特定 .NET 的某版本实现为目标,这样便可获得特定于实现的 API 的访问权限。An app or library can also target a version of a specific .NET implementation, in which case it gets access to implementation-specific APIs. 例如,面向 Xamarin.iOS 的应用有权访问 Xamarin 提供的 iOS API 包装器。For example, an app that targets Xamarin.iOS gets access to Xamarin-provided iOS API wrappers.

对于某些目标框架(例如 .NET Framework),可用 API 由 .NET 实现在系统上安装的程序集定义,其中可能包括应用程序框架 API(例如 ASP.NET、WinForms)。For some target frameworks (for example, the .NET Framework) the available APIs are defined by the assemblies that a .NET implementation installs on a system, which may include application framework APIs (for example, ASP.NET, WinForms). 对于基于包的目标框架(例如 .NET Standard 和 .NET Core),框架 API 由安装在应用或库中的包定义。For package-based target frameworks (such as .NET Standard and .NET Core), the framework APIs are defined by the packages installed in the app or library. 在这种情况下,目标框架隐式指定一个元包,该元包引用一起构成框架的所有包。In that case, the target framework implicitly specifies a metapackage that references all the packages that together make up the framework.

请参阅目标框架See Target Frameworks.


目标框架名字对象。Target framework moniker.

一个标准化令牌格式,用于指定 .NET 应用或库的目标框架。A standardized token format for specifying the target framework of a .NET app or library. 目标框架通常由短名称(如 net462)引用。Target frameworks are typically referenced by a short name, such as net462. 存在长格式的 TFM(如 .NETFramework,Version=4.6.2),但通常不用来指定目标框架。Long-form TFMs (such as .NETFramework,Version=4.6.2) exist but are not generally used to specify a target framework.

请参阅目标框架See Target Frameworks.


通用 Windows 平台。Universal Windows Platform.

用于为物联网 (IoT) 生成新式触控 Windows 应用程序和软件的 .NET 实现。An implementation of .NET that is used for building modern, touch-enabled Windows applications and software for the Internet of Things (IoT). 它旨在统一可能想要以其为目标的不同类型的设备,包括电脑、平板电脑、平板手机、电话,甚至 Xbox。It's designed to unify the different types of devices that you may want to target, including PCs, tablets, phablets, phones, and even the Xbox. UWP 提供许多服务,如集中式应用商店、执行环境 (AppContainer) 和一组 Windows API(用于代替 Win32 (WinRT))。UWP provides many services, such as a centralized app store, an execution environment (AppContainer), and a set of Windows APIs to use instead of Win32 (WinRT). 应用可采用 C++、C#、VB.NET 和 JavaScript 编写。Apps can be written in C++, C#, VB.NET, and JavaScript. 使用 C# 和 VB.NET 时,.NET API 由 .NET Core 提供。When using C# and VB.NET, the .NET APIs are provided by .NET Core.

请参阅See also