System.Diagnostics.CodeAnalysis Namespace
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.
Contains classes for interaction with code analysis tools. These tools are used to analyze code for conformance to coding conventions such as naming or security rules.
Classes
| Name | Description |
|---|---|
| AllowNullAttribute |
Specifies that |
| DisallowNullAttribute |
Specifies that |
| DoesNotReturnAttribute |
Specifies that a method will never return under any circumstance. |
| DoesNotReturnIfAttribute |
Specifies that the method will not return if the associated Boolean parameter is passed the specified value. |
| ExcludeFromCodeCoverageAttribute |
Specifies that the attributed code should be excluded from code coverage information. |
| MaybeNullAttribute |
Specifies that an output may be |
| MaybeNullWhenAttribute |
Specifies that when a method returns ReturnValue, the parameter may be |
| NotNullAttribute |
Specifies that an output is not |
| NotNullIfNotNullAttribute |
Specifies that the output will be non-null if the named parameter is non-null. |
| NotNullWhenAttribute |
Specifies that when a method returns ReturnValue, the parameter will not be |
| SuppressMessageAttribute |
Suppresses reporting of a specific code analysis rule violation, allowing multiple suppressions on a single code artifact. Does not apply to compiler diagnostics. |