Ask Learn
Preview
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
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 static classes for representing program contracts such as preconditions, postconditions, and invariants.
Contract |
Contains static methods for representing program contracts such as preconditions, postconditions, and object invariants. |
Contract |
Defines abbreviations that you can use in place of the full contract syntax. |
Contract |
Enables the factoring of legacy |
Contract |
Specifies that a separate type contains the code contracts for this type. |
Contract |
Specifies that a class is a contract for a type. |
Contract |
Provides methods and data for the ContractFailed event. |
Contract |
Marks a method as being the invariant method for a class. |
Contract |
Enables you to set contract and tool options at assembly, type, or method granularity. |
Contract |
Specifies that a field can be used in method contracts when the field has less visibility than the method. |
Contract |
Specifies that an assembly is a reference assembly that contains contracts. |
Contract |
Identifies a member that has no run-time behavior. |
Contract |
Instructs analysis tools to assume the correctness of an assembly, type, or member without performing static verification. |
Pure |
Indicates that a type or method is pure, that is, it does not make any visible state changes. |
Contract |
Specifies the type of contract that failed. |
.NET feedback
.NET is an open source project. Select a link to provide feedback:
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign in