什么是CLR托管? [英] What is CLR hosting?

查看:360
本文介绍了什么是CLR托管?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

什么是CLR托管?是用例是什么?

What is CLR hosting? What is the use case for that?

推荐答案

请参阅此处这是相关的CLR V2有关CLR的托管信息(.NET 2.0,3.0和3.5)。有关在.NET 4.0中的新的CLR托管API的信息,看到这里

See here for information about CLR hosting that was relevant for CLR v2 (.NET 2.0, 3.0 and 3.5). For information about the newer CLR Hosting API in .NET 4.0, see here.

基本上,在CLR作为可加载和托管由进程库。您可以开发加载和承载CLR,如果你想一个应用程序;这将让您的应用程序包含一个整体CLR虚拟机,装载组件和运行.NET托管code中的这一切。

Basically, the CLR acts as a library that can be loaded and "hosted" by a process. You can develop an app that loads and hosts the CLR if you wish; that would allow your app to contain a whole CLR virtual machine, load assemblies and run .NET managed code all within it.

的SQL Server 2008,例如,可以做到这一点。您可以编写存储在SQL Server数据库和SQL Server数据库引擎中运行.NET code。 SQL Server托管的CLR实现了。

SQL Server 2008, for example, can do this. You can write .NET code that is stored in a SQL Server database and run from within the SQL Server database engine. SQL Server is hosting the CLR to achieve that.

一个CLR主机而不是Windows外壳程序(通常的用户界面)等可以为您的code运行提供特定的背景。这对于特殊的应用或非常特殊的情况下很有用。 MSDN(以上链接),对这些问题的一些准则。

A CLR host other than the Windows shell (the usual user interface) can provide a specific context for your code to run. This can be useful for specialised applications or very particular scenarios. MSDN (link above) has some guidelines on these matters.

这篇关于什么是CLR托管?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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