是什么HostingEnvironment阶级和阶级的httpRuntime之间的区别? [英] What is the difference between HostingEnvironment class and HttpRuntime class?

查看:326
本文介绍了是什么HostingEnvironment阶级和阶级的httpRuntime之间的区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

正如你可以在这里看到 ASP.NET应用程序生命周期,有两张图片。在首先出现的是创建HostingEnvironment类AppDomain中,在第二创建它的httpRuntime类。从他们的定义,我不明白它们之间的区别。当创建一个,创建过程中的应用程序生命周期中的第二个是什么时候?在apllication生命周期的背景下HostingEnvironment阶级和阶级的httpRuntime之间的区别是什么?

As you can see here ASP.NET Application Life Cycle, there are two pictures. On the first there is created HostingEnvironment class in AppDomain, on the second is created HttpRuntime class in it. From their definitions i dont understand the difference between them. When is created one and when is created the second during application life cycle? What is the difference between HostingEnvironment class and HttpRuntime class in context of apllication life cycle?

推荐答案

您不能继承HostingEnvironment类和它的应用领域中托管的应用程序提供了应用程序管理功能和应用程序服务,其中为的httpRuntime类提供了一组的ASP当前应用程序的.NET运行时服务。

You cannot inherit a HostingEnvironment class and it provides application-management functions and application services to a managed application within its application domain where as HttpRuntime class provides a set of ASP.NET run-time services for the current application.

MSDN

这篇关于是什么HostingEnvironment阶级和阶级的httpRuntime之间的区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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