Class Diagnostic

Namespace
Pixie.Markup
Assembly
Pixie.dll

Describes a compiler-style diagnostic with an inline header, an optional inline message, and optional block details.

public sealed class Diagnostic : Block
Inheritance
Diagnostic
Inherited Members

Constructors

Diagnostic(Inline, string, Color, Inline, Inline, Block)

Creates a compiler-style diagnostic.

public Diagnostic(Inline origin, string kind, Color themeColor, Inline title, Inline message, Block details)

Parameters

origin Inline

The diagnostic origin, such as a source location.

kind string

The diagnostic kind label.

themeColor Color

The diagnostic theme color.

title Inline

The diagnostic title.

message Inline

The diagnostic message.

details Block

Additional block details for the diagnostic.

Properties

Details

Gets additional block details for the diagnostic.

public Block Details { get; }

Property Value

Block

Kind

Gets the diagnostic kind label.

public string Kind { get; }

Property Value

string

Message

Gets the diagnostic message.

public Inline Message { get; }

Property Value

Inline

Origin

Gets the diagnostic origin, such as a source location.

public Inline Origin { get; }

Property Value

Inline

ThemeColor

Gets the diagnostic theme color.

public Color ThemeColor { get; }

Property Value

Color

Title

Gets the diagnostic title.

public Inline Title { get; }

Property Value

Inline

Methods

FromSeverity(Severity, Inline, Inline, Inline, Block)

Creates a diagnostic from a severity level.

public static Diagnostic FromSeverity(Severity severity, Inline origin, Inline title, Inline message, Block details)

Parameters

severity Severity

The diagnostic severity.

origin Inline

The diagnostic origin, such as a source location.

title Inline

The diagnostic title.

message Inline

The diagnostic message.

details Block

Additional block details for the diagnostic.

Returns

Diagnostic

A diagnostic configured for the given severity.