共用方式為


ProcessModelSection.MinWorkerThreads 屬性

定義

取得或設定 CLR 執行緒集區中每個 CPU 之背景工作執行緒的最小數目。

public:
 property int MinWorkerThreads { int get(); void set(int value); };
[System.Configuration.ConfigurationProperty("minWorkerThreads", DefaultValue=1)]
[System.Configuration.IntegerValidator(MaxValue=2147483646, MinValue=1)]
public int MinWorkerThreads { get; set; }
[<System.Configuration.ConfigurationProperty("minWorkerThreads", DefaultValue=1)>]
[<System.Configuration.IntegerValidator(MaxValue=2147483646, MinValue=1)>]
member this.MinWorkerThreads : int with get, set
Public Property MinWorkerThreads As Integer

屬性值

Int32

CLR 執行緒集區中每個 CPU 的背景工作執行緒數目下限。

屬性

範例

下列程式碼範例示範如何存取 MinWorkerThreads 屬性。


  // Get the current MinWorkerThreads property value.
int minWorkerThreads = 
    processModelSection.MinWorkerThreads;

  // Set the MinWorkerThreads property to 2.
  processModelSection.MinWorkerThreads = 2;
' Get the current MinWorkerThreads property value.
   Dim minWorkerThreads As Integer = _
   processModelSection.MinWorkerThreads

' Set the MinWorkerThreads property to 2.
processModelSection.MinWorkerThreads = 2

適用於