Initializes a new instance of MaxInstancesAttribute
with the type name of the instances that should be checked and the maximum
number of instances allowed.
Namespace:
SciTech.NetMemProfilerAssembly: MemProfiler2 (in MemProfiler2.dll)
Syntax
| C# |
|---|
public MaxInstancesAttribute( string typeName, int instanceCount ) |
| Visual Basic |
|---|
Public Sub New ( _ typeName As String, _ instanceCount As Integer _ ) |
| Visual C++ |
|---|
public: MaxInstancesAttribute( String^ typeName, int instanceCount ) |
Parameters
- typeName
- Type: System..::..String
Type name of the instances that should be checked.
- instanceCount
- Type: System..::..Int32
Defines the maximum number of instances that should exist after the target method has been executed.
Remarks
For more information see
AssertionsDefinition.MaxInstances(String, Boolean, Int32) and
AssertionAttribute.