//editor-web/com.aardarch.aardink.web/WebDiagnostic
WebDiagnostic
@Serializabledata class WebDiagnostic(val line: Int, val startColumn: Int, val endColumn: Int, val message: String, val severity: String = “error”, val endLineNumber: Int? = null, val source: String? = null, val code: String? = null, val codeHref: String? = null, val tags: List<Int>? = null, val relatedInformation: List<WebRelatedInformation>? = null)
A diagnostic as a web host describes it — the shape of a Monaco marker, so hosts moving off Monaco can pass theirs through unchanged, and the shape AardinkWeb.onDiagnosticsChange reports the language’s own in. Lines and columns are 1-based, and endColumn is exclusive. It runs from line to endLineNumber (line when absent); a position past the end of its line is the line’s end.
Constructors
| Name | Summary |
|---|---|
| WebDiagnostic | constructor(line: Int, startColumn: Int, endColumn: Int, message: String, severity: String = “error”, endLineNumber: Int? = null, source: String? = null, code: String? = null, codeHref: String? = null, tags: List<Int>? = null, relatedInformation: List<WebRelatedInformation>? = null) |
Properties
| Name | Summary |
|---|---|
| code | val code: String? The producer’s identifier for this kind of problem, shown after source. |
| codeHref | val codeHref: String? Where code is explained (Monaco’s code.target). |
| endColumn | val endColumn: Int |
| endLineNumber | val endLineNumber: Int? |
| line | val line: Int |
| message | val message: String |
| relatedInformation | val relatedInformation: List<WebRelatedInformation>? |
| severity | val severity: String"error", "warning", "info" or "hint"; anything else is treated as "info". |
| source | val source: String? |
| startColumn | val startColumn: Int |
| tags | val tags: List<Int>? Monaco’s MarkerTags: 1 unnecessary (drawn faded), 2 deprecated (struck through). |