Trait Issue

Source
pub trait Issue:
    Send
    + Sync
    + NonLocalValue
    + ValueDebug {
    // Required methods
    fn file_path(self: Vc<Self>) -> Vc<FileSystemPath>
       where Self: Sized;
    fn stage(self: Vc<Self>) -> Vc<IssueStage>
       where Self: Sized;
    fn title(self: Vc<Self>) -> Vc<StyledString>
       where Self: Sized;

    // Provided methods
    fn severity(self: Vc<Self>) -> Vc<IssueSeverity>
       where Self: Sized { ... }
    fn description(self: Vc<Self>) -> Vc<OptionStyledString>
       where Self: Sized { ... }
    fn detail(self: Vc<Self>) -> Vc<OptionStyledString>
       where Self: Sized { ... }
    fn documentation_link(self: Vc<Self>) -> Vc<RcStr>
       where Self: Sized { ... }
    fn source(self: Vc<Self>) -> Vc<OptionIssueSource>
       where Self: Sized { ... }
    fn sub_issues(self: Vc<Self>) -> Vc<Issues>
       where Self: Sized { ... }
    fn into_plain(
        self: Vc<Self>,
        processing_path: Vc<OptionIssueProcessingPathItems>,
    ) -> Vc<PlainIssue>
       where Self: Sized { ... }
}

Required Methods§

Source

fn file_path(self: Vc<Self>) -> Vc<FileSystemPath>
where Self: Sized,

The file path that generated the issue, displayed to the user as message header.

Source

fn stage(self: Vc<Self>) -> Vc<IssueStage>
where Self: Sized,

The stage of the compilation process at which the issue occurred. This is used to sort issues.

Source

fn title(self: Vc<Self>) -> Vc<StyledString>
where Self: Sized,

The issue title should be descriptive of the issue, but should be a single line. This is displayed to the user directly under the issue header.

Provided Methods§

Source

fn severity(self: Vc<Self>) -> Vc<IssueSeverity>
where Self: Sized,

Severity allows the user to filter out unimportant issues, with Bug being the highest priority and Info being the lowest.

Source

fn description(self: Vc<Self>) -> Vc<OptionStyledString>
where Self: Sized,

A more verbose message of the issue, appropriate for providing multiline information of the issue.

Source

fn detail(self: Vc<Self>) -> Vc<OptionStyledString>
where Self: Sized,

Full details of the issue, appropriate for providing debug level information. Only displayed if the user explicitly asks for detailed messages (not to be confused with severity).

A link to relevant documentation of the issue. Only displayed in console if the user explicitly asks for detailed messages.

Source

fn source(self: Vc<Self>) -> Vc<OptionIssueSource>
where Self: Sized,

The source location that caused the issue. Eg, for a parsing error it should point at the offending character. Displayed to the user alongside the title/description.

Source

fn sub_issues(self: Vc<Self>) -> Vc<Issues>
where Self: Sized,

Source

fn into_plain( self: Vc<Self>, processing_path: Vc<OptionIssueProcessingPathItems>, ) -> Vc<PlainIssue>
where Self: Sized,

Trait Implementations§

Implementors§