Struct BuilderDiagnostic
- Namespace
- Farkle.Diagnostics.Builder
- Assembly
- Farkle.dll
Contains information about actions performed by Farkle's builder.
public readonly struct BuilderDiagnostic : IFormattable
- Implements
- Inherited Members
Constructors
BuilderDiagnostic(DiagnosticSeverity, object, string?)
Creates a BuilderDiagnostic.
public BuilderDiagnostic(DiagnosticSeverity severity, object message, string? code = null)
Parameters
severityDiagnosticSeverityThe value of Severity.
messageobjectThe value of Message.
codestringThe value of Code. Optional.
Exceptions
- ArgumentNullException
messageis null.
Properties
Code
The code of the diagnostic.
public string? Code { get; }
Property Value
Message
An object that describes the message.
public object Message { get; }
Property Value
Severity
The severity of the diagnostic.
public DiagnosticSeverity Severity { get; }
Property Value
Methods
ToString()
Returns the fully qualified type name of this instance.
public override string ToString()
Returns
- string
The fully qualified type name.
ToString(string?, IFormatProvider?)
Formats the value of the current instance using the specified format.
public string ToString(string? format, IFormatProvider? formatProvider)
Parameters
formatstringThe format to use.
-or-
A null reference (
Nothingin Visual Basic) to use the default format defined for the type of the IFormattable implementation.formatProviderIFormatProviderThe provider to use to format the value.
-or-
A null reference (
Nothingin Visual Basic) to obtain the numeric format information from the current locale setting of the operating system.
Returns
- string
The value of the current instance in the specified format.