Table of Contents

NotableDateValidationDiagnostic Class

Definition

Namespace
Bodu.Globalization.Calendar
Assembly
Bodu.Globalization.Calendar.dll
Package
Bodu.Globalization.Calendar 1.0.1
Source
NotableDateValidationDiagnostic.cs

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

Severity NotableDateValidationSeverity

The severity of the diagnostic.

Code string

A short, stable code identifying the kind of diagnostic.

Message string

A human-readable description of the diagnostic.

Properties

Code

A short, stable code identifying the kind of diagnostic.

public string Code { get; init; }

Property Value

string

Message

A human-readable description of the diagnostic.

public string Message { get; init; }

Property Value

string

Severity

The severity of the diagnostic.

public NotableDateValidationSeverity Severity { get; init; }

Property Value

NotableDateValidationSeverity

Methods

Deconstruct(out NotableDateValidationSeverity, out string, out string)

public void Deconstruct(out NotableDateValidationSeverity Severity, out string Code, out string Message)

Parameters

Severity NotableDateValidationSeverity
Code string
Message string

Equals(NotableDateValidationDiagnostic?)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(NotableDateValidationDiagnostic? other)

Parameters

other NotableDateValidationDiagnostic

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Determines whether the specified object is equal to the current object.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

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

left NotableDateValidationDiagnostic
right NotableDateValidationDiagnostic

Returns

bool

operator !=(NotableDateValidationDiagnostic?, NotableDateValidationDiagnostic?)

public static bool operator !=(NotableDateValidationDiagnostic? left, NotableDateValidationDiagnostic? right)

Parameters

left NotableDateValidationDiagnostic
right NotableDateValidationDiagnostic

Returns

bool

Applies to

ProductVersions
.NET8, 10