NotableDateValidationDiagnostic Class
Definition
- Namespace
- Bodu.Globalization.Calendar
- Assembly
- Bodu.Globalization.Calendar.dll
- Package
- Bodu.Globalization.Calendar 1.0.1
Represents a single diagnostic produced while loading and validating a notable-date document resource.
public sealed record NotableDateValidationDiagnostic : IEquatable<NotableDateValidationDiagnostic>
- Inheritance
-
NotableDateValidationDiagnostic
- Implements
- Inherited Members
- Extension Methods
Constructors
NotableDateValidationDiagnostic(NotableDateValidationSeverity, string, string)
Represents a single diagnostic produced while loading and validating a notable-date document resource.
public NotableDateValidationDiagnostic(NotableDateValidationSeverity Severity, string Code, string Message)
Parameters
SeverityNotableDateValidationSeverityThe severity of the diagnostic.
CodestringA short, stable code identifying the kind of diagnostic.
MessagestringA human-readable description of the diagnostic.
Properties
Code
A short, stable code identifying the kind of diagnostic.
public string Code { get; init; }
Property Value
Message
A human-readable description of the diagnostic.
public string Message { get; init; }
Property Value
Severity
The severity of the diagnostic.
public NotableDateValidationSeverity Severity { get; init; }
Property Value
Methods
Deconstruct(out NotableDateValidationSeverity, out string, out string)
public void Deconstruct(out NotableDateValidationSeverity Severity, out string Code, out string Message)
Parameters
SeverityNotableDateValidationSeverityCodestringMessagestring
Equals(NotableDateValidationDiagnostic?)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(NotableDateValidationDiagnostic? other)
Parameters
otherNotableDateValidationDiagnosticAn object to compare with this object.
Returns
Equals(object?)
Determines whether the specified object is equal to the current object.
public override bool Equals(object? obj)
Parameters
objobjectThe object to compare with the current object.
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
ToString()
Returns a readable rendering of the diagnostic, combining its severity, code, and message.
public override string ToString()
Returns
- string
The diagnostic formatted as
[Severity] Code: Message.
Operators
operator ==(NotableDateValidationDiagnostic?, NotableDateValidationDiagnostic?)
public static bool operator ==(NotableDateValidationDiagnostic? left, NotableDateValidationDiagnostic? right)
Parameters
Returns
operator !=(NotableDateValidationDiagnostic?, NotableDateValidationDiagnostic?)
public static bool operator !=(NotableDateValidationDiagnostic? left, NotableDateValidationDiagnostic? right)
Parameters
Returns
Applies to
| Product | Versions |
|---|---|
| .NET | 8, 10 |