ProfileSettings 类
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
配置 ASP.NET 事件配置文件。 此类不能被继承。
public ref class ProfileSettings sealed : System::Configuration::ConfigurationElement
public sealed class ProfileSettings : System.Configuration.ConfigurationElement
type ProfileSettings = class
inherit ConfigurationElement
Public NotInheritable Class ProfileSettings
Inherits ConfigurationElement
- 继承
示例
此示例演示如何以声明方式为节的 profiles 多个属性指定值,该属性也可以作为类的成员 ProfileSettings 进行访问。
以下配置文件摘录显示了如何以声明方式指定节的 profiles 多个属性的值。
<healthMonitoring>
<profiles>
<add name="Default"
minInstances="1"
maxLimit="Infinite"
minInterval="00:10:00"
/>
<add name="Critical"
minInstances="1"
maxLimit="1024"
minInterval="00:00:00"
/>
</profiles>
</healthMonitoring>
注解
该 ProfileSettings 类提供了一种以编程方式访问和修改 profiles 配置文件节元素 healthMonitoring 的方法。
事件配置文件确定如何通过 ASP.NET 收集事件并将其引发到提供程序。
构造函数
| 名称 | 说明 |
|---|---|
| ProfileSettings(String, Int32, Int32, TimeSpan, String) |
使用类的新实例 BufferModeSettings 的指定设置初始化类的新实例。 |
| ProfileSettings(String, Int32, Int32, TimeSpan) |
使用类的新实例 ProfileSettings 的指定设置初始化类的新实例。 |
| ProfileSettings(String) |
初始化 ProfileSettings 类的新实例。 使用类的新实例的指定名称。 |