HandleCollector Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
HandleCollector(String, Int32) |
Initializes a new instance of the HandleCollector class using a name and a threshold at which to begin handle collection. |
HandleCollector(String, Int32, Int32) |
Initializes a new instance of the HandleCollector class using a name, a threshold at which to begin handle collection, and a threshold at which handle collection must occur. |
HandleCollector(String, Int32)
- Source:
- HandleCollector.cs
- Source:
- HandleCollector.cs
- Source:
- HandleCollector.cs
Initializes a new instance of the HandleCollector class using a name and a threshold at which to begin handle collection.
public:
HandleCollector(System::String ^ name, int initialThreshold);
public HandleCollector (string name, int initialThreshold);
public HandleCollector (string? name, int initialThreshold);
new System.Runtime.InteropServices.HandleCollector : string * int -> System.Runtime.InteropServices.HandleCollector
Public Sub New (name As String, initialThreshold As Integer)
Parameters
- name
- String
A name for the collector. This parameter allows you to name collectors that track handle types separately.
- initialThreshold
- Int32
A value that specifies the point at which collections should begin.
Exceptions
The initialThreshold
parameter is less than 0.
Applies to
HandleCollector(String, Int32, Int32)
- Source:
- HandleCollector.cs
- Source:
- HandleCollector.cs
- Source:
- HandleCollector.cs
Initializes a new instance of the HandleCollector class using a name, a threshold at which to begin handle collection, and a threshold at which handle collection must occur.
public:
HandleCollector(System::String ^ name, int initialThreshold, int maximumThreshold);
public HandleCollector (string name, int initialThreshold, int maximumThreshold);
public HandleCollector (string? name, int initialThreshold, int maximumThreshold);
new System.Runtime.InteropServices.HandleCollector : string * int * int -> System.Runtime.InteropServices.HandleCollector
Public Sub New (name As String, initialThreshold As Integer, maximumThreshold As Integer)
Parameters
- name
- String
A name for the collector. This parameter allows you to name collectors that track handle types separately.
- initialThreshold
- Int32
A value that specifies the point at which collections should begin.
- maximumThreshold
- Int32
A value that specifies the point at which collections must occur. This should be set to the maximum number of available handles.
Exceptions
The initialThreshold
parameter is less than 0.
-or-
The maximumThreshold
parameter is less than 0.
The maximumThreshold
parameter is less than the initialThreshold
parameter.