Failure Class
Describes a failure.
Inheritance Hierarchy
System.Object
Microsoft.TeamFoundation.VersionControl.Client.Failure
Namespace: Microsoft.TeamFoundation.VersionControl.Client
Assembly: Microsoft.TeamFoundation.VersionControl.Client (in Microsoft.TeamFoundation.VersionControl.Client.dll)
Syntax
'Declaración
Public NotInheritable Class Failure
public sealed class Failure
public ref class Failure sealed
[<Sealed>]
type Failure = class end
public final class Failure
The Failure type exposes the following members.
Properties
Name | Description | |
---|---|---|
Code | Gets the failure code. | |
ComputerName | Gets the name of the computer that is associated with the failure. | |
IdentityName | Gets the identity that is associated with the failure. | |
ItemId | Gets the item ID that is associated with the failure. | |
LocalItem | Gets the local item that is associated with the failure. | |
Message | Gets the failure message. | |
RequestType | Gets the request type that caused this failure. | |
ResourceName | Gets the resource name that is associated with the failure. | |
ServerItem | Gets the server item that is associated with the failure. | |
Severity | Gets the severity of the failure. | |
VersionControlServer | Gets the version control server on which the failure occurred. | |
Warnings | Gets an array of warnings that is associated with the failure. | |
WorkspaceName | Gets the workspace name that is associated with the failure. | |
WorkspaceOwner | Gets the workspace owner that is associated with the failure. |
Top
Methods
Name | Description | |
---|---|---|
Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetFormattedMessage | Gets a user-readable message that describes this failure. | |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
ToString | Creates a user-readable string that describes the properties of a failure. (Overrides Object.ToString().) |
Top
Remarks
The Failure object contains much of the same information as an exception but is not derived from Exception and is not throwable.
Commands that operate on a collection of items, each of which may succeed or fail independently of the others will return an array of Failure objects representing the items that had trouble.
The Failure object also contains fields that describe the context in which the error occurred. A smart client may use these to make decisions about how to handle the error. Irrelevant info remains null and will not be sent as part of the soap reply.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.