Επεξεργασία

Κοινή χρήση μέσω


BufferModeSettings Constructor

Definition

Initializes a new instance of the BufferModeSettings class using specified settings.

public:
 BufferModeSettings(System::String ^ name, int maxBufferSize, int maxFlushSize, int urgentFlushThreshold, TimeSpan regularFlushInterval, TimeSpan urgentFlushInterval, int maxBufferThreads);
public BufferModeSettings (string name, int maxBufferSize, int maxFlushSize, int urgentFlushThreshold, TimeSpan regularFlushInterval, TimeSpan urgentFlushInterval, int maxBufferThreads);
new System.Web.Configuration.BufferModeSettings : string * int * int * int * TimeSpan * TimeSpan * int -> System.Web.Configuration.BufferModeSettings
Public Sub New (name As String, maxBufferSize As Integer, maxFlushSize As Integer, urgentFlushThreshold As Integer, regularFlushInterval As TimeSpan, urgentFlushInterval As TimeSpan, maxBufferThreads As Integer)

Parameters

name
String

The name of the BufferModeSettings object being created.

maxBufferSize
Int32

The maximum number of events buffered at one time. The value must be greater than zero.

maxFlushSize
Int32

The maximum number of events per buffer flush. Must be greater than zero.

urgentFlushThreshold
Int32

The number of events buffered before a buffer flush is triggered. The value must be greater than zero and less than or equal to maxBufferSize.

regularFlushInterval
TimeSpan

The standard amount of time between buffer flushes. The value can be made infinite by setting it to Int32.MaxValue ticks.

urgentFlushInterval
TimeSpan

The minimum length of time that can pass between buffer flushes. The value must be less than or equal to regularFlushInterval.

maxBufferThreads
Int32

The maximum number of buffer-flushing threads that can be active at one time.

Examples

The following code example shows how to use the BufferModeSettings constructor. This code example is part of a larger example provided for the HealthMonitoringSection class.

// Add a BufferModeSettings object to the BufferModes collection property.
healthMonitoringSection.BufferModes.Add(new BufferModeSettings("Error Log", 
    1024, 256, 512, new TimeSpan(0, 30, 0), new TimeSpan(0, 5, 0), 2));
' Add a BufferModeSettings object to the BufferModes collection property.
healthMonitoringSection.BufferModes.Add(new BufferModeSettings("Error Log", _
    1024, 256, 512, new TimeSpan(0, 30, 0), new TimeSpan(0, 5, 0), 2))

Applies to

See also