Mountain/ApplicationState/DTO/
MarkerDataDTO.rs

1//! # MarkerDataDTO
2//!
3//! Defines the Data Transfer Object for a single diagnostic marker (e.g., an
4//! error or warning).
5
6#![allow(non_snake_case, non_camel_case_types)]
7
8use serde::{Deserialize, Serialize};
9use serde_json::Value;
10
11/// Represents a single diagnostic marker, such as a compiler error or a linter
12/// warning. This structure is compatible with VS Code's `IMarkerData`
13/// interface and is used by the Diagnostic service.
14#[derive(Serialize, Deserialize, Debug, Clone, Default)]
15#[serde(rename_all = "PascalCase")]
16pub struct MarkerDataDTO {
17	pub Severity:u32,
18
19	pub Message:String,
20
21	pub StartLineNumber:u32,
22
23	pub StartColumn:u32,
24
25	pub EndLineNumber:u32,
26
27	pub EndColumn:u32,
28
29	#[serde(skip_serializing_if = "Option::is_none")]
30	pub Source:Option<String>,
31
32	#[serde(skip_serializing_if = "Option::is_none")]
33	// Can be string or { value: string, target: URI }
34	pub Code: Option<Value>,
35
36	#[serde(skip_serializing_if = "Option::is_none")]
37	pub ModelVersionIdentifier:Option<u64>,
38
39	#[serde(skip_serializing_if = "Option::is_none")]
40	// Vec<RelatedInformationDTO>
41	pub RelatedInformation: Option<Value>,
42
43	#[serde(skip_serializing_if = "Option::is_none")]
44	// Corresponds to MarkerTag enum
45	pub Tags: Option<Vec<u32>>,
46}