FailureDefinition
Description:
Defines persistent information about a failure.
Defines persistent information about a failure.
Remarks:
Each failure that can be potentially posted in Revit must be based on a FailureDefinition object that contains some persistent information about failure such as identity, severity, basic description text, types of resolution and default resolution. Each FailureMessage, which contains variable part of the information for a specific failure when it occurs, is created with a reference to a registered FailureDefinition. In order to be able to post a failure, one must define and register it via FailureDefinition object during Revit Application startup.
Each failure that can be potentially posted in Revit must be based on a FailureDefinition object that contains some persistent information about failure such as identity, severity, basic description text, types of resolution and default resolution. Each FailureMessage, which contains variable part of the information for a specific failure when it occurs, is created with a reference to a registered FailureDefinition. In order to be able to post a failure, one must define and register it via FailureDefinition object during Revit Application startup.
Inheritance Hierarchy:
System.Object
Autodesk.Revit.DB.FailureDefinition
System.Object
Autodesk.Revit.DB.FailureDefinition
public class FailureDefinition : IDisposable
| Name | Return Type | Description |
|---|---|---|
| AddResolutionType(FailureResolutionType, String, Type) | The FailureDefinition. | Adds a type of possible resolution for the failure. |
| CreateFailureDefinition(FailureDefinitionId, FailureSeverity, String) | FailureDefinition | Creates an instance of a FailureDefinition. |
| Dispose() | None | Releases all resources used by the |
| GetApplicableResolutionTypes() | IList<FailureResolutionType> | Retrieves a list of resolution types applicable to the failure. |
| GetDefaultResolutionType() | FailureResolutionType | Retrieves the default resolution type for the failure. |
| GetDescriptionText() | The description text. | Retrieves the description text of the failure. |
| GetResolutionCaption(FailureResolutionType) | string | Retrieves the caption for a specific resolution type. |
| HasResolutions() | bool | Checks if the FailureDefinition has at least one resolution. |
| IsResolutionApplicable(FailureResolutionType) | bool | Checks if the given resolution type is applicable to the failure. |
| SetDefaultResolutionType(FailureResolutionType) | The FailureDefinition. | Sets the default resolution type for the failure. |
| Name | Return Type | Description |
|---|---|---|
| IsValidObject | bool | Specifies whether the .NET object represents a valid Revit entity. |
| Severity | FailureSeverity | The severity of the failure. |