ProcessModelLogLevel ProcessModelLogLevel ProcessModelLogLevel ProcessModelLogLevel Enum

定义

指定要记录到事件日志的事件类型。Specifies the event types to be logged to the event log.

此 API 支持产品基础结构,不能在代码中直接使用。

public enum class ProcessModelLogLevel
public enum ProcessModelLogLevel
type ProcessModelLogLevel = 
Public Enum ProcessModelLogLevel
继承
ProcessModelLogLevelProcessModelLogLevelProcessModelLogLevelProcessModelLogLevel

字段

All All All All 1

指定记录所有进程事件。Specifies that all process events are logged. 如果要浏览应用程序可能发出的错误且不进行任何筛选,请使用此选项。Use this option when you want to explore the possible errors an application might issue, without any filtering. 此选项在生成和调试阶段非常有用。This option is useful during the building and debugging phase.

Errors Errors Errors Errors 2

指定只记录意外关闭、内存限制关闭和死锁关闭。Specifies that only unexpected shutdowns, memory-limit shutdowns, and deadlock shutdowns are logged. 这是默认值。This is the default value.

None None None None 0

指定不记录任何事件。Specifies that no events are logged. 建议将此选项用于已测试和已部署的应用程序。You might want to use this option for tested and deployed applications.

示例

下面的示例演示如何设置 ProcessModelSection.LogLevel 属性。The following example shows how to set the ProcessModelSection.LogLevel property.


// Get the current LogLevel property value.
ProcessModelLogLevel comLogLevel = 
    processModelSection.LogLevel;

// Set the LogLevel property to ProcessModelLogLevel.All.
processModelSection.LogLevel = ProcessModelLogLevel.All;

' Get the current LogLevel property value.
   Dim comLogLevel As ProcessModelLogLevel = _
   processModelSection.LogLevel

' Set the LogLevel property to ProcessModelLogLevel.All.
processModelSection.LogLevel = ProcessModelLogLevel.All

注解

ProcessModelLogLevel枚举包含的值来设置时使用ProcessModelSection.LogLevel属性。The ProcessModelLogLevel enumeration contains the values to use when you set the ProcessModelSection.LogLevel property.

默认值为 ErrorsThe default value is Errors.

适用于

另请参阅