Class Error
Represents an error.
Implements
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Sartorius.SAF.Validation
Assembly: Sartorius.SAF.dll
Syntax
[Serializable]
public class Error : IError
Constructors
View SourceError(Guid)
Creates a new instance of the Error class with the specified error id.
Declaration
protected Error(Guid id)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | id | The error id. |
Remarks
Use this constructor when overriding ErrorText.
Error(Guid, Object, String)
Creates a new instance of the Error class.
Declaration
public Error(Guid id, object source, string errorText)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | id | The error id. |
System.Object | source | The error source. |
System.String | errorText | The error text. |
Error(Guid, String)
Creates a new instance of the Error class with the specified error id and error message.
Declaration
public Error(Guid id, string errorText)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | id | The error id. |
System.String | errorText | The error text. |
Properties
View SourceErrorText
The error text.
Declaration
public virtual string ErrorText { get; }
Property Value
Type | Description |
---|---|
System.String |
Id
The unique identifier of the error.
Declaration
public Guid Id { get; }
Property Value
Type | Description |
---|---|
System.Guid |
Methods
View SourceEquals(IError)
Determines whether the specified IError is equal to this instance.
Declaration
protected bool Equals(IError other)
Parameters
Type | Name | Description |
---|---|---|
IError | other | The oth er IError to compare to this object. |
Returns
Type | Description |
---|---|
System.Boolean |
|
Equals(Object)
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
System.Object.Equals(System.Object)
View Source
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 |
Overrides
System.Object.GetHashCode()
View Source
GetSourceId()
Gets a unique identifier of the error source as a hash code.
Declaration
public int? GetSourceId()
Returns
Type | Description |
---|---|
System.Nullable<System.Int32> | The unique identifier as hash code. |