Failure Class |
The Failure type exposes the following members.
Name | Description | |
---|---|---|
Code | Gets the non-null, non-empty code associated with this failure. | |
Message | Gets the non-null message associated with this failure, providing explanatory information about the Code and what went wrong. |
Name | Description | |
---|---|---|
Equals |
A Failure can only be equal to another Failure
with an equal Code and Message.
(Overrides ObjectEquals(Object)) | |
GetHashCode |
Overridden to ensure consistency with Equals.
(Overrides ObjectGetHashCode) | |
ToString |
Returns a non-null, non-empty string representation of this instance for logging and debugging purposes.
(Overrides ObjectToString) |
A failure is primarily defined by its Code. But it also comes with a Message to help explain the meaning of the code.
You are unlikely to need to deal with Failure objects or failure codes directly, as API methods like GetLocationData(LocationDataRequest) and GetBase(DataSpec) will automatically turn any failure codes into appropriate subclasses of FailureException.